Welcome to the Cumulus Support forum.

Latest Cumulus MX V4 release 4.4.2 (build 4085) - 12 March 2025

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Legacy Cumulus 1 release 1.9.4 (build 1099) - 28 November 2014
(a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

If you are posting a new Topic about an error or if you need help PLEASE read this first viewtopic.php?p=164080#p164080

how to open a new window with a script?

Other discussion about creating web sites for Cumulus that doesn't have a specific subforum

Moderator: daj

Post Reply
n9mfk
Posts: 845
Joined: Sun 10 May 2009 8:52 pm
Weather Station: davis vp2 Serial datalogger
Operating System: Windows 7 64-bit
Location: Springfield, IL

how to open a new window with a script?

Post by n9mfk »

Hi all,
i need some help
im working on some code
that uses

Code: Select all

javascript:window.close();
I found that for this to work in firefox the page must be open with script
so I like to make a page with script that wood open another page
thanks for an help Beau
fractonimbus
Posts: 159
Joined: Thu 03 Feb 2011 1:15 am
Weather Station: WH1091
Operating System: Windows 7 on a Dell Vostro
Location: Canberra

Re: how to open a new window with a script?

Post by fractonimbus »

Is this the sort of thing you mean?

Click on the "NINO 3.4 Index" heading:

http://www.deakinwx.com/wx/index.htm

DN
Image
User avatar
daj
Posts: 2041
Joined: Tue 29 Jul 2008 8:00 pm
Weather Station: WH1081
Operating System: Pi & MX
Location: SW Scotland
Contact:

Re: how to open a new window with a script?

Post by daj »

Various ways to do it. Use the onclick event of the a tag

Code: Select all

<a href="Javascript:" onclick="window.open('new_page.html','New Page');">Click Me</a.>
(The href="javscript:" is often written as href="#" which does nothing, but some browsers need something in the href for completeness! I prefer to use javascript as it stops the browswer putting a # in the URL)

a quick Google found this..http://www.javascript-coder.com/window- ... open.phtml
David
kippfordweather.uk
Cumulus MX & Raspberry Pi
Post Reply