Link to home
Start Free TrialLog in
Avatar of rolandmy
rolandmyFlag for Malaysia

asked on

passing data from echo drop down list to another page

hi expert,

I am new in php, I would like a question regarding to passing data from echo drop down list to another page.
for example, I am doing echo a drop down list in php and how I able to pass the selected option value to another page. normally , when I am using name of drop down list as a linkage to get the value.<?php <select name='option' id='option' > ? > .
Avatar of Insoftservice inso
Insoftservice inso
Flag of India image

I would suggest to read some documents from w3schools and some blogs for PHP it would be more beneficial for you.
Please check the below code which would help you to pass data from one page to other by using post method
<form action="http://mydomain.com/page.php" method="post"> <br />
    <select> name="website_string" 
        <option value="" selected="selected"></option>
    <option VALUE="abc"> ABC</option>
    <option VALUE="def"> def</option>
        <option VALUE="hij"> hij/option>   
    </select>
    <input type="submit" name="website_string"  >
</form>

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Scott Fell
Scott Fell
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial