PDA

View Full Version : Drop Down Menu w/ Descriptions



navaro
04-16-2005, 12:42 AM
http://www.dynamicdrive.com/dynamicindex1/combodescribe.htm

I would like to modify this script to have the output appear in an inline frame (called "inline") in my current document rather than navigate to a new URL, which seems to be the default mode. I'm not a code writer, but I suspect that a slight modification of the following piece of code in red will do the trick. Any suggestions?
================
function jumptolink(what){
var selectedopt=what.options[what.selectedIndex]
if (document.getElementById && selectedopt.getAttribute("target")=="newwin")
window.open(selectedopt.value)
else
window.location=selectedopt.value
================
By the way, I have set all of my menu values to include 'target="inline"'

Thanks for any help

navaro
04-16-2005, 01:15 AM
Thanks anyaway, but a little digging in the JK JavaScript Reference yielded the answer. I was looking for 'parent.inline.location=... in lieu of 'window.location=...'
Works great!

jscheuer1
04-16-2005, 04:23 AM
Don't look now but, oops you are a code writer. At least that is how it starts . . .