Posted by rlee0001 on 03/26/06 08:03
Denis,
David's code with work for the H:Hello syntax you posted before.
But be aware that the user can manipulate both strings so you shouldn't
trust anything you pass via POST. The best way is to do a query on the
destination page. It may seem redundant but it is the least error prone
and compared to parsing apart strings it should be easier to manage as
well if you change things later.
Is client-side JS acceptable? If so put the full string in the
'longvalue' attribute of the option tags. Then on form_onsubmit copy
that attribute's value to a seperate hidden form input element. Use
hiddenfield.value =
getElementById('myselect').getAttribute('longvalue') or something like
that (untested).
-Robert
Navigation:
[Reply to this message]
|