tags:

views:

23

answers:

1

I have a GWT app with a bunch of textboxes. In firefox I would expect that when I type a word in a textbox that I have already typed in and submitted, that firefox would offer to autocomplete that text. But for this GWT app it is not happening.

The ids and the name of the html elements are the same everytime. I don't know if it makes a difference, but I am using UiBinders for presentation.

Also in IE it seems that none of my css stuff is loaded. And when I IE developer tools on my GWT page, it can focus in on any of the textboxes it just focuses on the encompassing DIV around all the textboxes.

+1  A: 

The problem with autocompletion is caused by how the DOM tree is created in a dynamic web application, such as the one created using GWT. Basically, all the DOM elements (textboxes, etc) are dynamically created, after the page is loaded. However, AFAIK, the browser only supports autocompletion on "static" elements, ones that are part of the HTML host page. So, for that reason you won't get autocompletion support from your browser in a GWT app. Fot some cases, you can still emulate it via SuggestBox.

You could try including the elements you want autocompletion for in your HTML host page, and then wrapping your GWT Widgets around them - that might work :) But it's not the "prettiest" solution, since you probably want autocompletion for a number of unrelated fields/elements.

Igor Klimer
I almost down-voted this. Not because your answer is wrong or doesn't makes sense. It is because I don't like the way this has turned out using GWT. I think I should have went with Wicket.
arinte
I wouldn't be so quick to dismiss GWT - this limitation is not GWT's fault, it's the browsers (at least, AFAIK). Although, it all depends on the type of application you want to create - IMHO, Wicket and GWT are meant to be used for (slightly) different types of web applications.
Igor Klimer