Q: Dropdown onchange event within an iframe not working For a variety of complicated reasons I have a Joomla page with an iFrame in it. The page that the iframe calls is classic asp, and the dropdown on there looks like this:
<select name="pulldown" onchange="nav_pulldown(this)">
<option value="?wherearewe=here">I want to go here</option>
<option value="?wherearewe=there">I want to go there</option>
</select>

The JavaScript:
<script type="text/javascript"> 
<!-- //
function nav_pulldown(list) {
if (list.options[list.selectedIndex].value != "#"); {
top.document.location = list.options[list.selectedIndex].value;
}}
//-->
</script>

So, user changes the dropdown menu and the javascript submits the form. The asp page grabs that querystring and renders something or other depending on what was selected. This all works fine when the page is rendered by itself outside of the iframe (when top.document is valid). But I can't determine the proper name or call to have the dropdown target and populate itself onchange. I've tried a bunch of different things.
I have control over both pages, the Joomla and the ASP. For a variety of reasons the querystrings cannot change. The iframe's name is currently formframe, if it matters.

A: As per comments, you need to use self.location (or the slightly redundant, but equivalent self.document.location) rather than top.document.location.
self refers to the document where the javascript code resides.  top will refer to the top-most parent document.  So when you're not iframing a page, top refers to self.  But when you are iframing a page, top refers to the top-most parent document.
