473,326 Members | 2,680 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

JavaScript doesn't work in Firefox2

The script below doesn't bring the window to the front using Firefox2. Using
IE7, it works fine. What am I doing wrong? Thanks.

<script language="JavaScript">
<!--

/* tcwin is name of this window - avgwin is other window*/
/* same code in both windows - changed as it applies to window*/

window.name = "tcwin";

function loadit()
{
var win = open ('avg.htm', 'avgwin',
'scrollbars=yes,width=690,height=511,top=0,left=0' )
}

//-->
</script>

<body onload="window.focus()">

<area coords="11, 140, 189, 175" shape="rect" href="javascript:loadit()">
Nov 4 '06 #1
2 1401
Poten Tate wrote:
The script below doesn't bring the window to the front using Firefox2. Using
IE7, it works fine. What am I doing wrong? Thanks.
<body onload="window.focus()">
Browsers can be configured to disallow many operations for script. Check
for Firefox 2.0 whether
Tools -Options -Content -Enable JavaScript -Advanced ->
Allow scripts to "raise or lower windows"
is enabled. Of course you can only configure that for your browser so
using window.focus() and expecting it works on the web in general is not
possible, to many ad popups have forced browsers to allow configuration
of whether script can do such things.
--

Martin Honnen
http://JavaScript.FAQTs.com/
Nov 4 '06 #2
Thanks, Martin. That fixed the problem (on my end). I guess I'll have to
include a note about this to the users of my website.
"Martin Honnen" <ma*******@yahoo.dewrote in message
news:45***********************@newsspool1.arcor-online.net...
Poten Tate wrote:
>The script below doesn't bring the window to the front using Firefox2.
Using IE7, it works fine. What am I doing wrong? Thanks.
><body onload="window.focus()">

Browsers can be configured to disallow many operations for script. Check
for Firefox 2.0 whether
Tools -Options -Content -Enable JavaScript -Advanced ->
Allow scripts to "raise or lower windows"
is enabled. Of course you can only configure that for your browser so
using window.focus() and expecting it works on the web in general is not
possible, to many ad popups have forced browsers to allow configuration of
whether script can do such things.
--

Martin Honnen
http://JavaScript.FAQTs.com/

Nov 4 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: francisco lopez | last post by:
hallo, I Have the following problem: I want to shake (earthquake-effect) the browser when someone hits the button. So I used the following script: ...
3
by: Bob | last post by:
I'm a total newbie at Javascript, but a programmer for over 20 years... so, my plans may be bigger than they are possible. I'm trying to set with Javascript the value of a form field... easy...
18
by: cjl | last post by:
Hey all: I know that it is silly in the age of Google to 'lose' something on the internet, but I recently checked out a project that had implemented a database with a subset of SQL in pure...
1
by: Neil Cherry | last post by:
What I'm basically trying to do is call a Java applet public method ( public void setInterval(int i) {...} ) from javascript in Firfox 1.0.7. I've not done this before but most of google agrees...
4
by: Darrel | last post by:
I have an asp button I want to apply some javascript to. I have this in the page head: <script type="text/javascript"> function myOnSubmitEventHandler() {...
4
by: iamthebest | last post by:
Hello, I am trying to call a javscript function from c#. But it is not getting called. The error comes up saying funtionname is not defined even though it is defined and visible in page source. ...
2
by: Armo | last post by:
Hi, I have developed a site using a free CSS template and like many others have problems with the site (www.stepanavanyouthcenter.org) displaying just fine in Firefox2 and going crazy in IE6. ...
1
by: manojuniverse | last post by:
Hi can any body help me in knowing in javscript on client side whether session has expired or not. Plz help me. Thanks in advance.
2
by: mmxmsmmzm | last post by:
Would everyone begin to post JavaScript editors that include watch and debug windows! These tools are probably very new... but posting responses to this post will aid in gathering a number of...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.