Jump to content

php onchange causing page to reload...


rhyno

Recommended Posts

OK here is my issue....

I have a dropdown select box that I need to reload the page with that dogs information... But alas it does not work...

 

<?php ='<form name="goldenmale" onchange="gallery.php?dogid='.$rowmg['dogid'].'">
<select name="MaleGoldens">
	<option></option>';
		while($rowmg=mysql_fetch_assoc($rsMaleGoldens)) {
			echo '<option name="'.$rowmg['callname'].'">'.$rowmg['callname'].'</option>';
		}
echo '</select>
</form>'

 

 

What am I doing wrong and how can I fix it...

Link to comment
https://forums.phpfreaks.com/topic/90949-php-onchange-causing-page-to-reload/
Share on other sites

I've inserted this into my php file and put it on the server and it does not work.

echo '<select name="menu" onChange="location=document.jump.menu.options[document.jump.menu.selectedIndex].value;" value="GO">
								<option>Please Select</option>';
							while($rowmg=mysql_fetch_assoc($rsMaleGoldens)) {
								echo '<option value="gallery.php?dogid='.$rowmg['dogid'].'">'.$rowmg['callname'].'</option>';
							}
						echo '</select>';

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.