About Duffbert...

Duffbert's Random Musings is a blog where I talk about whatever happens to be running through my head at any given moment... I'm Thomas Duff, and you can find out more about me here...

Email Me!

Search This Site!

Custom Search

I'm published!

Co-author of the book IBM Lotus Sametime 8 Essentials: A User's Guide
SametimeBookCoverImage.jpg

Purchase on Amazon

Co-author of the book IBM Sametime 8.5.2 Administration Guide
SametimeAdminBookCoverImage.jpg

Purchase on Amazon

MiscLinks

Visitor Count...



View My Stats

« Book Review - The Real Business Of Web Design by John Waters | Main| Yes, I know you've been inundated with Firefox news stories... »

Activating IE's AutoComplete without "submitting" the form?

Category Software Development

I'm having an issue with an application, and perhaps you can help me out since I'm still less than proficient on the web stuff...

I have a form that is used for searching.  There's a field you use to put your search term in, and then you click the submit button (or hit enter).  On the OnSubmit event, there's a call to the doSearch function which ends up returning the results of the search on a customized form.  After the doSearch function, there's a return false.  So in effect, the form never gets fully "submitted".

IE's AutoComplete function will give you a dropdown list of values for a field if the field name matches a field name for which IE has stored values.  After experimenting around with my app, it appears that the value of the field gets stored (and is available the next time the form is used) when the form gets submitted.  Since I'm doing a return false as part of my onSubmit, it never gets stored.  If I don't do the return false, it will store the value, but I get a 500 HTTP error because it tries to submit some long hairy URL when you look at the log.

I may just have to tell the user that the AutoComplete function won't work the way the application is designed.  However, if there's some way I can fake IE into thinking the form is submitted while actually just displaying the returned search results, that would be cool...

Any ideas?

Comments

Gravatar Image1 - Interesting ideas, guys... I'll have to give both of them a try. And you're right, Brian... I should have thought of that. Duh!

Gravatar Image2 - I assume we're talking about a Domino form, nit an HTMl form. If that's the case, have you tried the old trick of including a text field named SaveOptions with "0" as its value?

Gravatar Image3 - I found a cool tool can instead of IE's autocomplete function, more details see: http://www.jjsoft-studio.com

Gravatar Image4 - Hi Tom,

First I take this opportunity to congratulate you for your so intelligent site and articles. I heard about you via Joe Litton, your co-team-TSG.

About your problem: I suggest that the action of the form is the JavaScript code. This way you will both submit the form and perform the action. Something like:

<form method="GET" action="javascript: myFunction();">

What do you think about this?

Kind regards,
Lionel

Gravatar Image5 - Why don't you use the following method?

AutoCompleteSaveForm Method
{ Link }

Gravatar Image6 - This works great..Now values are getting saved, but they are available in autosuggest only after refreshing the page . How to make them available without refresh.

Post A Comment

:-D:-o:-p:-x:-(:-):-\:angry::cool::cry::emb::grin::huh::laugh::lips::rolleyes:;-)

Want to support this blog or just say thanks?

When you shop Amazon, start your shopping experience here.

When you do that, all your purchases during that session earn me an affiliate commission via the Amazon Affiliate program. You don't have to buy the book I linked you to (although I wouldn't complain!). Simply use that as your starting point.

Thanks!

Thomas "Duffbert" Duff

Ads of Relevance...