fizah Posted August 13, 2014 Share Posted August 13, 2014 hello everybody.. i need help.. i want to make a dropdown menu with php coding that will show the result from my database.. can anyone help me to generate the coding? this is an example form: <form action="" method="get"><select name=""> <option value="select">select</option> <option value="1">1 </option> <option value="2">2</option> <option value="3">3</option> </select> <label> <input type="submit" name="button" id="button" value="Submit" /> </label></form> if user select 1, the php code will show a list of name by their identification card, if user select 2 the php code will show a list of name by country. Quote Link to comment https://forums.phpfreaks.com/topic/290434-dropdown-menu-with-php-code/ Share on other sites More sharing options...
trq Posted August 13, 2014 Share Posted August 13, 2014 What you are describing is much better done client side using Javascript. Quote Link to comment https://forums.phpfreaks.com/topic/290434-dropdown-menu-with-php-code/#findComment-1487669 Share on other sites More sharing options...
fizah Posted August 13, 2014 Author Share Posted August 13, 2014 but,i'm newer for programming study..can you give me an example coding? Quote Link to comment https://forums.phpfreaks.com/topic/290434-dropdown-menu-with-php-code/#findComment-1487670 Share on other sites More sharing options...
trq Posted August 13, 2014 Share Posted August 13, 2014 No, were not here to write code for people. Where exactly are you stuck? Quote Link to comment https://forums.phpfreaks.com/topic/290434-dropdown-menu-with-php-code/#findComment-1487671 Share on other sites More sharing options...
cyberRobot Posted August 13, 2014 Share Posted August 13, 2014 but,i'm newer for programming study..can you give me an example coding? If you want to use JavaScript, here's a quick example: http://javascript.about.com/library/bldydrop1.htm Quote Link to comment https://forums.phpfreaks.com/topic/290434-dropdown-menu-with-php-code/#findComment-1487685 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.