Lucky2710 Posted August 10, 2010 Share Posted August 10, 2010 I have leader boards on my site (Currently just overall) But i want o include weekly as well without showing them all at one time. So i want to create a drop down box that is like this... <form id="weekSelect" name="weekSelect" method="post" action=""> <label>Week <select name="weeks" id="weeks"> <option value="Overall">Overall</option> <option value="Week1">1</option> <option value="Week2">2</option> <option value="Week3">3</option> <option value="Week4">4</option> <option value="Week5">5</option> <option value="Week6">6</option> <option value="Week7">7</option> <option value="Week8">8</option> <option value="Week9">9</option> <option value="Week10">10</option> <option value="Week11">11</option> <option value="Week12">12</option> <option value="Week13">13</option> </select> </label> </form> A user will select which week to view and then below this a table populated with the top 20 users will show up. How do i go about making this form show a certain table depending on which week is selected? Thanks Link to comment https://forums.phpfreaks.com/topic/210338-drop-down-box-that-shows-a-specific-table/ Share on other sites More sharing options...
radar Posted August 10, 2010 Share Posted August 10, 2010 would require ajax. onchange("select_week(); return falase") then the ajax commences, there is an ajax tutorial on this site that can show you how to do this. Link to comment https://forums.phpfreaks.com/topic/210338-drop-down-box-that-shows-a-specific-table/#findComment-1097648 Share on other sites More sharing options...
Lucky2710 Posted August 10, 2010 Author Share Posted August 10, 2010 On what site? I can't find it on "This site (phpfreaks.com)" Link to comment https://forums.phpfreaks.com/topic/210338-drop-down-box-that-shows-a-specific-table/#findComment-1097763 Share on other sites More sharing options...
radar Posted August 13, 2010 Share Posted August 13, 2010 http://www.phpfreaks.com/forums/index.php/topic,115581.0.html is the link to the basic working ajax example. Then of course you'll need to modify it to do what it is you want. I personalled learned ajax using prototype, from the Sams Teach Yourself Ajax, Javascript and PHP all in one book. It gives you a basic understanding of ajax, but gives you the knowledge to be able and expand that to do whatever you want to do. Link to comment https://forums.phpfreaks.com/topic/210338-drop-down-box-that-shows-a-specific-table/#findComment-1098863 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.