How can i put some sort of a drop down menu that has options and when i click on each one of them, it will open a video on a different window with the same dimentions as the video?
How can i put some sort of a drop down menu that has options and when i click on each one of them, it will open a video on a different window with the same dimentions as the video?
You can use window.open(), a javascript function.
<select onChange="window.open(this.value,null,'height=240,width=320);">
<option value="page1.htm">video1</option>
<option value="page2.htm">video2</option>
<option value="page3.htm">video3</option>
</select>
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
do i have to put a script on the head? because it doesn't work when i do it...
Hmm... I'm not sure why it isn't working.
This has nothing to do with where the script is placed, but I'm not sure how to fix it anyway.
I think someone else will know.
I likely just have something simple wrong that I'm missing.
I'm no Javascript expert.
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
I think it is supposed to be like this:
Hope this helps.Code:<select onChange="window.open(this.options[this.selectedIndex].value,null,'height=240,width=320);"> <option value="page1.htm">video1</option> <option value="page2.htm">video2</option> <option value="page3.htm">video3</option> </select>
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music." - Kristian Wilson, Nintendo, Inc, 1989
TheUnlimitedHost | The Testing Site | Southern Utah Web Hosting and Design
i put the code but nothing happens when i change the option... does anyone know if i have to put a script in order for this to work?
Are you by chance getting a popup blocker message?
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
it works now but i want to change it a little, instead of opening in a different window i want it to play the video right on top of the switcher, on the same page. how can i do this.
Ah. That's different, then. You said popup window, which is what that is.
Take a look at the 'window widget' or other similar scripts in the dynamic drive library to see if one of those will fit what you need.
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
Bookmarks