[Javascript] Doubt in style sheets

Thomas Bendixen horneyhokie at vt.edu
Thu Nov 27 12:14:48 CST 2003


Hello Nazir,

i know that you are looking to hide the toolbar, but here is a little 
script that i have to hide and unhide any object with an ID in it. it 
does for netscape, exploder, and a couple others.

function blocking(nr)
{
    if (document.layers)
    {
        current = (document.layers[nr].display == 'none') ? 'block' : 
'none';
        document.layers[nr].display = current;
    }
    else if (document.all)
    {
        current = (document.all[nr].style.display == 'none') ? 'block' : 
'none';
        document.all[nr].style.display = current;
    }
    else if (document.getElementById)
    {
        vista = (document.getElementById(nr).style.display == 'none') ? 
'block' : 'none';
        document.getElementById(nr).style.display = vista;
    }
}

where nr is the ID of the 'object' that you want to hide or not. maybe 
in explorer,    document.toolbar.display = 'none'      would work. just 
an idea.

new to the group, but no noob,

Thomas




Nazir Wasim Ahmed wrote:

>Hi Laurent,
>
>That is exactly my problem.
>i need an ie equivalent.
>
>Nazir
>
>  
>
>>-----Original Message-----
>>From: javascript-bounces at LaTech.edu 
>>[mailto:javascript-bounces at LaTech.edu]On Behalf Of Muchacho, 
>>Laurent (TWIi London)
>>Sent: Thursday, November 27, 2003 4:26 PM
>>To: '[JavaScript List]'
>>Subject: RE: [Javascript] Doubt in style sheets
>>
>>
>>oops I did a spelling mistake is window.toolbar.visible=false
>>that working on mozillia, netscape 7 and the value is read only 
>>froma window
>>you didn't open in netscape4
>>that is not working on Internet explorer
>>
>>Laurent
>>
>>
>>-----Original Message-----
>>From: Nazir Wasim Ahmed [mailto:nazirwa at sakinfotech.co.in]
>>Sent: 27 November 2003 06:55
>>To: [JavaScript List]
>>Subject: RE: [Javascript] Doubt in style sheets
>>
>>
>>
>>HI David,
>>
>>when i give window.toolbar.visible = false
>>it says object dosen't support this property...
>>How do i
>>    
>>
>>>>>"alter the visibility of the toolbar, but leave the
>>>>>"object" present."
>>>>>          
>>>>>
>>Thanx in advance
>>Nazir
>>
>>    
>>
>>>-----Original Message-----
>>>From: javascript-bounces at LaTech.edu
>>>[mailto:javascript-bounces at LaTech.edu]On Behalf Of David Lovering
>>>Sent: Thursday, November 27, 2003 12:23 PM
>>>To: [JavaScript List]
>>>Subject: Re: [Javascript] Doubt in style sheets
>>>
>>>
>>>Hmmm... that's a bit tricky, as different browsers have different
>>>conventions for it.  In general, once the window is opened only a
>>>protected
>>>script (i.e; a signed script) can alter it.
>>>
>>>It is better to simply alter the visibility of the toolbar, but 
>>>      
>>>
>>leave the
>>    
>>
>>>"object" present.
>>>
>>>-- Dave Lovering
>>>
>>>----- Original Message -----
>>>From: "Nazir Wasim Ahmed" <nazirwa at sakinfotech.co.in>
>>>To: "[JavaScript List]" <javascript at LaTech.edu>
>>>Sent: Wednesday, November 26, 2003 11:38 PM
>>>Subject: RE: [Javascript] Doubt in style sheets
>>>
>>>
>>>      
>>>
>>>>Hello list,
>>>>
>>>>i need to hide the toolbar from an existing window. what is 
>>>>        
>>>>
>>the api call
>>    
>>
>>>for
>>>      
>>>
>>>>the same
>>>>
>>>>thanx in advance
>>>>
>>>>
>>>>Nazir
>>>>
>>>>_______________________________________________
>>>>Javascript mailing list
>>>>Javascript at LaTech.edu
>>>>https://lists.LaTech.edu/mailman/listinfo/javascript
>>>>
>>>>
>>>>        
>>>>
>>>_______________________________________________
>>>Javascript mailing list
>>>Javascript at LaTech.edu
>>>https://lists.LaTech.edu/mailman/listinfo/javascript
>>>
>>>      
>>>
>>_______________________________________________
>>Javascript mailing list
>>Javascript at LaTech.edu
>>https://lists.LaTech.edu/mailman/listinfo/javascript
>>
>>
>>DISCLAIMER - The preceding e-mail message (including any attachments)
>>contains information that may be confidential, may be protected by the
>>attorney-client or other applicable privileges, or may constitute 
>>non-public
>>information.  It is intended to be conveyed only to the designated
>>recipient(s) named above.  If you are not an intended recipient of this
>>message, or have otherwise received it in error, please notify 
>>the sender by
>>replying to this message and then delete all copies of it from 
>>your computer
>>system.  Any use, dissemination, distribution, or reproduction of this
>>message by unintended recipients is not authorized and may be 
>>unlawful. The
>>contents of this communication do not necessarily represent the views of
>>this company.
>>_______________________________________________
>>Javascript mailing list
>>Javascript at LaTech.edu
>>https://lists.LaTech.edu/mailman/listinfo/javascript
>>
>>    
>>
>_______________________________________________
>Javascript mailing list
>Javascript at LaTech.edu
>https://lists.LaTech.edu/mailman/listinfo/javascript
>
>  
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.evolt.org/pipermail/javascript/attachments/20031127/92443f6b/attachment.htm>


More information about the Javascript mailing list