Hi Colin,
Really appreciate your input.

Sorry, I should've been more crisper with my requirement. Let me try to do
that:

When the user types in 'a', I still like the display of the drop down list
with contact name and email address one below the other. When I select a
contact from the list, I still need the contact name Ada Noel to be
displayed in the text field to the user. At the same time, I also need the
email address [EMAIL PROTECTED] to be set in a hidden text field inside
the same form.

Hope I got it clear this time around.

Thanks
Sridhar




On Thu, Oct 30, 2008 at 4:52 AM, ColinFine <[EMAIL PROTECTED]> wrote:

>
> [I hate top-posting, but that seems to the the norm here]
>
> Use 'informal' [1]
>
> Make your ajax call return
> <li><span class='informal'>Ada Noel</span><span
> class='hide'>[EMAIL PROTECTED]</span</li>
> etc.
>
> Then have a CSS rule
> span.hide {display:none}
>
> The CSS will ensure that only the name is displayed to the user, but
> the Ajax.Autocomplete takes only the text which is NOT in a span with
> class 'informal', and so will take only the email address.
>
> Colin
>
>
> [1]: http://github.com/madrobby/scriptaculous/wikis/ajax-autocompleter,
> section 'Server return'
>
>
> On Oct 30, 6:41 am, srid <[EMAIL PROTECTED]> wrote:
> > Hello
> >
> > In the To field when you type the letter 'a', the first item in the
> > drop down list is the Ada Noel, how do I capture the e-mail address,
> > basically I want to set a hidden field in the form with the email
> > address selected.
> >
> > thanks in advance
> > Sridhar
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to