I have this form below, as selection to set a locaiton for user. However, when I click on the <li>, it post the form to the correct path, but does not take the value=“name”. what am I missing here, why is not taking the varibale “name”. I’m I going down the right street.
You mean the hidden form field locationName? The value for that form variable comes from $_POST[‘name’]. Are you sure that it exists and has a value? Take a look at the html code in your browser. What value does that field have?
The location you have stored in the title tags of your <a> tags. Those aren’t submitted when you submit the form.
Also, passing the name of the location as a parameter to the submit() function on the form doesn’t do anything either.
Any reason why you’re not using a <select> for the location?
I am using <ul><li> instead of select, for jquery styling I added for cool dropdown.
Just need to send the value with click on the <a href> for each list item.
I am trying to pass it as in this form is setup, But I al using jquery <ul><li> styling that allows me to make dropdown look and work with jQuery. Do not want to look the effect.
Just want the onClick event to pass the variable = name(ex.atlanta, dallas) to the form and that’s it.
I can get the form to submit currently when I click on each List item, but it does not carry of load the vairable name with form as it post.
<input type=“hidden” name=‘locationName’ value=“<?php echo $_POST[“name”];?>” /> Ho do I get the variable to be passed along when form is submitted with correct variable or (city) loading in post as “name”?
Thank you all for your direction ans support, I have been a member here for some years, I must say. Guys, don’t always give you direct assistance.
But when you get help on these forums. I tell you You get the bessssstessssstsssssssssssssssssssss guidance anyone can ask for.
Liek getting advice from small-geek god childs.
Respect to everyone who supports this forum, big up lon gtime. Rah Rah Rah