Jump to content


Getting data uning a form

  • Please log in to reply
1 reply to this topic

#1 nisroc

  • Members
  • PipPipPip
  • Advanced Member
  • 40 posts

Posted 22 August 2006 - 02:38 AM

Im trying to get a field to display on the same page by using a mysql table and a form a drop down menu / submit button. The drop down menu is populated with the names fields within the table. When I hit the submit button I want the dynamic data returned for that specific name. I am not sure how to get the forum to react this way. Any help please im very lost here

<form id="appview" name="appview" method="post" action="get">
  <select name="select">
do {  
    <option value="<?php echo $row_appview['gamename']?>"><?php echo $row_appview['gamename']?></option>
} while ($row_appview = mysql_fetch_assoc($appview));
  $rows = mysql_num_rows($appview);
  if($rows > 0) {
      mysql_data_seek($appview, 0);
	  $row_appview = mysql_fetch_assoc($appview);

  <input type="submit" name="Submit" value="Submit" />

#2 ronverdonk

  • Members
  • PipPipPip
  • Advanced Member
  • 277 posts
  • LocationNetherlands

Posted 22 August 2006 - 09:24 AM

Let me get this correct.

Pass 1. You want a user to click on an item from a select-box that is populated from the database (with $row_appview['gamename').
Pass 2. After submit you want to display some other items (depending on the selected gamename) from the database to the user.

Does that sum up your problem?

RTFM is an almost extinct art form, it should be subsidized.

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users