POV-Ray : Newsgroups : povray.general : Pop-up web pages : Re: Pop-up web pages Server Time
9 Aug 2024 01:23:19 EDT (-0400)
  Re: Pop-up web pages  
From: Peter J  Holzer
Date: 1 Nov 2000 18:03:19
Message: <slrn9012nu.3vj.hjp-usenet@teal.h.hjp.at>
On Wed, 1 Nov 2000 17:24:17 -0000, Tom Melly wrote:
>"Ron Parker" <ron### [at] povrayorg> wrote in message
>news:slr### [at] fwicom...
>> On Fri, 27 Oct 2000 21:11:27 +0100, Tom Melly wrote:
>> >hmm, how about a bit of javascript form to give the users a preferred
>> >setting (same window or new). Default to same window. Could even save the
>> >choice as a cookie?
>>
>> No, don't use javascript unless it's necessary. Lynx can handle
>> frames and new windows, but it can't handle javas*t.
>>
>
>Hmm, you're right - I was thinking that the javascript could work alongside
>standard html, by over-riding the target (which would leave a default for
>non-javascript browsers). However, that can't be done.

It can be done. For example, the WIFO staff pages
(http://www.wifo.ac.at/staff/) contain HTML like this (slightly edited):

    <script language="JavaScript" type="text/javascript">
     
	function CreatePortraitWindow() { 
	    NewWindow = window.open("", "portrait", 
	    "width=400,height=250,status=yes,scrollbars=no,resize=no,menubar=no") 
	} 
     
    </script>

    [...]

    <a href="tel_guger.html" 
       target="portrait"  
       onclick = "CreatePortraitWindow ()" 
   > 
	<img src="../icons/camera.gif" border="0">
    </a>

This will open a new window with the specified size and attributes, if
JavaScript is enabled. It will create a new window (via the target
attribute) with default size and attributes if the browser doesn't
support or has disabled JavaScript, but can open new windows. It will
replace the document in the current window if it cannot open new
windows. So this will work for all browsers in a reasonable way.

	hp

-- 


| |   | hjp### [at] wsracat      |    -- Lutz Donnerhacke in dasr.
__/   | http://www.hjp.at/ |


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.