/    Sign up×
Community /Pin to ProfileBookmark

popup doesn’t work in IE but works in everythign else

Hi,

I’m trying to create a popup window for my site. The window will contain a flash mp3 player & the popup will be activated when the user clicks a button.

It works in every browser known to man apart from internet explorer. Any ideas why this might be??

heres my code

[code]

var newwindow;
function mp3popup(url)
{
newwindow=window.open(url,’mp3player.html’,’height=370,width=300′);
if (window.focus) {newwindow.focus()}
}

[/code]

Cheers

Tim

to post a comment
JavaScript

6 Comments(s)

Copy linkTweet thisAlerts:
@FangSep 16.2007 — The 2nd parameter is a name not an URL: http://developer.mozilla.org/en/docs/DOM:window.open#Syntax
Copy linkTweet thisAlerts:
@SylvesterWebsteauthorSep 16.2007 — Oh my god,

I've spent forever trying to get this to work,

Thank you kindly, much appreciated.

Cheers

Tim
Copy linkTweet thisAlerts:
@SylvesterWebsteauthorSep 16.2007 — While I'm on,

any ideas why in netscape it opens a new tab the same size as the browser window rather than the size specified in the script?

Cheers

Tim
Copy linkTweet thisAlerts:
@hoangkcSep 16.2007 — oNewWindow = window.open( [sURL] [, sName] [, sFeatures] [, bReplace])

where sName is string that specifies the name of the window. This name is used as the value for the TARGET attribute on a form or an a element.

It can be _blank, _media(IE6 or later), _parent, _search(IE5 or later), _self and _top (they are former)

Or any string you type without point ([COLOR="Red"][B].[/B][/COLOR]) character in that string (not former)
Copy linkTweet thisAlerts:
@hoangkcSep 16.2007 — Oh, after I post my reply, there were 3 posted replies ;(
Copy linkTweet thisAlerts:
@FangSep 16.2007 — Don't forget the user can control how the window opens with their browser options.
×

Success!

Help @SylvesterWebste spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...