Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem with frames

Status
Not open for further replies.

swordfishsm

Technical User
Sep 16, 2007
3
US
I have a web application with frames. I have a simple function to remove some options from some select objects which are hidden.

function removeOptionSelected()
{
var elSel = document.getElementById('addressPersonTemp');
name = document.forms[0][pername].value

for (i = elSel.length - 1; i>=0; i--) {
if (elSel.options.value == name) {
elSel.remove(i);
}
}
}

When this function runs , the targets of the frames suddenly becomes a new window. Can anyone tell me why this might be happening ?
 
My only thought is that you've got a JS error somewhere which might be stopping some frame blocking going on. Try putting an alert at the end of that function, after the loop, and see if it gets called.

Other than that, I'd post a URL to your page.

Hope this helps,
Dan



Coedit Limited - Delivering standards compliant, accessible web solutions

[tt]Dan's Page [blue]@[/blue] Code Couch
[/tt]
 
When this function runs , the targets of the frames suddenly becomes a new window. Can anyone tell me why this might be happening ?

I would say that the form the dropdown lives in is being submitted. And that's why you see the "new window" appearing.

Just a thought.

Cheers,
Jeff

[tt]Jeff's Blog [!]@[/!] CodeRambler
[/tt]

Make sure your web page and css validates properly against the doctype you have chosen - before you attempt to debug a problem!

FAQ216-6094
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top