/    Sign up×
Community /Pin to ProfileBookmark

Some JavaScript help.

function newWindow()
{
window.open(‘comments.php’, ‘Video Comments’, ‘toolbar=0,location=0,statusbar=1,menubar=0,scrollbars=yes,width=400,height=450,resizable=no’);
}

function newWindowIE(){
window.open(‘comments.php’,’myWindow’,’menubar=no,width=10,height=10,toolbar=no,
directories=no,resizable=no,scrollbars=no,location=no,status=yes’);
};

These two functions are working on my local host, but not when actually put online.

Anyone know what I could try to get it to work when it’s actually active?

to post a comment
JavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@phpmikeJun 27.2008 — can we see the context its used in
Copy linkTweet thisAlerts:
@KorJun 27.2008 — http://www.webdeveloper.com/forum/showthread.php?t=184988

As for the rest... they should work on a server as well. can we see a link to your test on server?
Copy linkTweet thisAlerts:
@webDevShaneauthorJun 27.2008 — <input type="button" value=" > View Comments (5)" onclick='javascript:newWindow(); return false;' style="margin: -2px 614px 0px -20px; cursor:pointer;background:transparent;border:0;font-family: Calibri;font-size:10.5pt;" />

Is the call for FF

<input type="button" value=" > View Comments (5)" onclick='newWindowIE();' return false;' style="margin: 72px 614px -20px -20px; cursor:pointer;background:transparent;border:0;font-family: Calibri;font-size:10.5pt;" />

Is the call for IE

Thanks
Copy linkTweet thisAlerts:
@KorJun 27.2008 — drop the unnecessary and wrong[B] javascript:[/B] and use double quotes:

onclick="newWindow()"

onclick="newWindowIE()"
===


Note. Not everybody has installed Calibri font (it is a commercial Microsoft - I guess - font). Give some options: [B]font-family: Calibri, Verdana, Arial, sans-serif[/B]
×

Success!

Help @webDevShane 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 6.2,
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: @meenaratha,
tipped: article
amount: 1000 SATS,

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

tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,
)...