mrheff Posted March 9, 2007 Share Posted March 9, 2007 Ello phpfreak one and all, My wee problem is this, ive mad a menu sytem that creates itself out of directories etc... but now we want to use a drop down menu, y'know those jump from page pag type deals so i made the lil form for it i figur its just needs to redirect the page to a given variable..... here comes the problem... i am using frames, can i state a target frame for my redirct?, or could i do it this way... have a link under the menu the users selct from the drop down, then clicks the button which is just a href with a variable in it. anyways here is what i have... <?php echo 'jump<br>'; echo "<form method=\"post\" action=\"$_SERVER[php_SELF]\" >"; echo " <SELECT NAME=directory> " ; $dirname = "gallery"; $dh = opendir($dirname) or die("couldn't open directory"); while (!(($file = readdir($dh)) === false ) ) { if (is_dir("$dirname/$file") && $file!="." && $file !="..") echo " <OPTION VALUE=$file> $file " ;} closedir($dh); echo " </SELECT><br> <input type=\"submit\" name=\"dir\" value=\"GO!\"> " ; ?> this code generates a drop down menu of all directories contained within the gallery folder and i figure above this code i need some type of <?php $directory = $_POST["directory"]; header("Location:/$directory/gallery.php"); ?> type dealbut i cant find anything on redirecting to a Url that is a target does anyone know the syntax for this ??? I Am intending it to redirect the frame called frame_bottom ANy ideas appreciated guys. ta for your time, and patience Link to comment https://forums.phpfreaks.com/topic/42007-drop-down-jump-sounds-like-some-new-dance-craze/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.