adding simple drop-down
-
I have worked on this for hours and I cannot spend any more time on this.
It should be simple – add a drop down and based on the value, open a URL. This will be in a div in header.pbp.
No, I do not want a custom menu, I do not want to store anything in a database, this is just a simple drop-down. Here is the code I have so far which is not even close to working.
<?php $taskOption = isset($_POST["company"]) ? $_POST["company"] : ""; $handle = fopen($taskOption) ?> <form> <select id="company" name="company"> <option <?php if ($company == 1 ) $handle = @fopen("http://www.apple.com/","rb"); ?> value="1">Apple</option> <option <?php if ($company == 2 ) $handle = @fopen("http://www.google.com/","rb"); ?> value="2">Samsung</option> <option <?php if ($company == 3 ) $handle = @fopen("http://www.htc.com/","rb"); ?> value="3">HTC</option> </select> <input type="submit" value="Submit the form"/> </form>Thank you,
Phil Persson
Viewing 13 replies - 1 through 13 (of 13 total)
Viewing 13 replies - 1 through 13 (of 13 total)
The topic ‘adding simple drop-down’ is closed to new replies.