bigmark Posted March 2, 2008 Share Posted March 2, 2008 Can anyone tell me if this is possible. I need a form that has fields-username,password,comp_name and round. then i need the results to show in grid, however if the user has not input results for that round before then the grid shows a drop down list and submit button. What the user does is choose 1 of 2 teams to win from a drop down list of names in the database, there are 8 games per round(16 teams). So when a user inputs their username,password and round number, it displays the grid for that round with the teams picked, but if they havent picked teams for that round then they choose from drop down lists. All the back end mysql is already done but i need some help desperately as the football season is starting in 2 weeks and i cant figure out how to do it. The form needs to go in a tabbed panel and i would like the results php_self or if not possible to open up a new window so when they close the pop up window they session out. I am willing to pay anyone who can help if that is whats required. Quote Link to comment https://forums.phpfreaks.com/topic/93988-php-form-that-displays-data-or-another-form/ Share on other sites More sharing options...
ignace Posted March 2, 2008 Share Posted March 2, 2008 it is possible, also if you are willing to pay people to do it for you, then you should have post it in http://www.phpfreaks.com/forums/index.php/board,8.0.html <form action="" method="post" enctype="application/x-www-form-urlencoded"> <table> <tr> <td><label for="username">Username</label>:</td> <td><input type="text" id="username" name="username" /></td> </tr> <tr> <td><label for="password">Password</label>:</td> <td><input type="text" id="password" name="password" /></td> </tr> <tr> <td><label for="comp_name">Competition name</label>:</td> <td><select id="comp_name" name="comp_name"> <option value="comp_one">First competition</option> <option value="comp_two">Second Competition</option> </select></td> </tr> <tr> <td><label for="round">Round</label>:</td> <td><input type="text" id="round" name="round" /></td> </tr> <tr> <td colspan="2"><input type="submit" id="submit" name="submit" /></td> </tr> </table> </form> <?php if ($_SERVER['REQUEST_METHOD'] == 'POST') { if (!empty($_POST['username']) && !empty($_POST['password'])) { // do something, login or so // get result or something } // if no input results (whatever that may be), then show dropdown and submit button } ?> Quote Link to comment https://forums.phpfreaks.com/topic/93988-php-form-that-displays-data-or-another-form/#findComment-481635 Share on other sites More sharing options...
bigmark Posted March 3, 2008 Author Share Posted March 3, 2008 Thanks thats a start, i was looking at that forum for paid work but it looks like there are 100 postings for 1 reply so i didnt bother. if you are interested in my project let me know, i have half the script made but need a login with editable grid, with the editable regions under a certain condition. Quote Link to comment https://forums.phpfreaks.com/topic/93988-php-form-that-displays-data-or-another-form/#findComment-482326 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.