Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

PHP/jump menu js issue?

Featured Replies

I've had to take a step or two back to look at a jump menu issue and not sure where the problem is. I've created a jump menu list that is populated dynamically using DW. That works fine and when the option is selected it puts the dynamic info into the url for filtering later and that seems to work fine also. The issue is i've had a first attempt at php and it worked locally but get a 500 - Internal server error.There is a problem with the resource you are looking for, and it cannot be displayed. error. I'm sure it's down to my php attempt(s) but might be a js error?

I've recreated the page without my php and it works fine, the only issue I have is when an option is selected, the jump menu redirects back to the page and puts ?orgname=organisationselected but reverts back to --select-- in the menu. I'd like the top opton to display the organisation selected so the registrant can see he selected the correct one. Here's it almost working:

 

My linkhttp://www.pitlanepass.com/pages/register.php

 

Here's my code that didn't work remotely...

 

<form name="form" id="form">

 

<select name="jumpMenu" id="jumpMenu" onchange="MM_jumpMenu('parent',this,1)">

 

<option value="register.php?orgname=<?php echo $row_rsJumporgregister['orgname']; ?>">

 

<?php if ($_GET['orgname']=$_GET['orgname']) {

echo "<option>"$_GET['orgname']"</option>";

} else {

echo "<option>-- select organisation--</option>";

}

?>

 

 

<?php do { ?>

<option value="register.php?orgname=<?php echo $row_rsOrgjumpumpregister['orgname']; ?>"><?php echo $row_rsOrgjumpumpregister['orgname']; ?></option>

<?php } while ($row_rsOrgjumpumpregister = mysql_fetch_assoc($rsOrgjumpumpregister)); ?>

</select>

</form>

 

Is it a simple mistake or am I way off in my methods?

Your a bit off;

 

Give this a try..

 

<form name="form" id="form">

<select name="jumpMenu" id="jumpMenu" onchange="MM_jumpMenu('parent',this,1)">

<option>-- select organisation--</option>

<?php

while ($row_rsOrgjumpumpregister = mysql_fetch_assoc($rsOrgjumpumpregister)) {

echo "<option value=\"register.php?orgname=" . $row_rsOrgjumpumpregister['orgname'] . "\"";

if ($_GET['orgname'] == $row_rsOrgjumpumpregister['orgname']) {

echo " SELECTED";

}

echo ">" . $row_rsOrgjumpumpregister['orgname']; . "</option>";

}

?>

</select>

</form>

 

I've had to take a step or two back to look at a jump menu issue and not sure where the problem is. I've created a jump menu list that is populated dynamically using DW. That works fine and when the option is selected it puts the dynamic info into the url for filtering later and that seems to work fine also. The issue is i've had a first attempt at php and it worked locally but get a 500 - Internal server error.There is a problem with the resource you are looking for, and it cannot be displayed. error. I'm sure it's down to my php attempt(s) but might be a js error?

I've recreated the page without my php and it works fine, the only issue I have is when an option is selected, the jump menu redirects back to the page and puts ?orgname=organisationselected but reverts back to --select-- in the menu. I'd like the top opton to display the organisation selected so the registrant can see he selected the correct one. Here's it almost working:

 

My linkhttp://www.pitlanepass.com/pages/register.php

 

Here's my code that didn't work remotely...

 

<form name="form" id="form">

 

<select name="jumpMenu" id="jumpMenu" onchange="MM_jumpMenu('parent',this,1)">

 

<option value="register.php?orgname=<?php echo $row_rsJumporgregister['orgname']; ?>">

 

<?php if ($_GET['orgname']=$_GET['orgname']) {

echo "<option>"$_GET['orgname']"</option>";

} else {

echo "<option>-- select organisation--</option>";

}

?>

 

 

<?php do { ?>

<option value="register.php?orgname=<?php echo $row_rsOrgjumpumpregister['orgname']; ?>"><?php echo $row_rsOrgjumpumpregister['orgname']; ?></option>

<?php } while ($row_rsOrgjumpumpregister = mysql_fetch_assoc($rsOrgjumpumpregister)); ?>

</select>

</form>

 

Is it a simple mistake or am I way off in my methods?

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.