• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

how to refer to new window using javascript

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I need to open a new window(having same url as parent window )from the parent window with header and footer disabled. So I need the control of the new window before it is fully loaded so that I can disable header and footer of new window from the parent window. Can you please suggest some solutions for this problem.
 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hey

what do you mean by
header and footer disabled ??

can you give some explaination

Amit Pandit
 
Karishma Kuriachan
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
What I meant by header and footer disabled is I need the new window with some filelds not present. In my parent window I will have some secondary navigation,left navigation and footer and I dont want to see it in the new window. SO I need to disable these fields before I get the new window keeping parent window not affected(ie it should be as same as earlier).
 
amit pandit
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

Is your secondary navigation and footer display code on a web page ?
If yes, then how can you enable or disable it?

I guess, it is done by some conditional arguments on PageLoad() event.
so by checking some page properties like title, you can distinguish between parent window and child window.
and according to that on PageLoad() event you can enable or disable your code stuff.

if my answer is not up to mark, please ask your question with some code to undestand your problem correctly.

bye
Amit Pandit
 
(instanceof Sidekick)
Posts: 8791
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, much like your other post about opening windows, you can set variables on the child window before the child page loads:

The child can manipulate the visibility of divs based on window.showFooter. Hmmm, I'm not sure how or where to do that so you don't see the visibility change.
 
Karishma Kuriachan
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
Actually the problem is that i don't get showFooter element of child in the parent window unless the page is completeley loaded.....
code:
---------------------------------------------------------------------------

var child = open(...);
/* say here if you try to get getElementById("showFooter").. will return a null value..*/
child.showFooter = false;

---------------------------------------------------------------------------
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why don;t you pass the values in as querystrings and have the server read the querystring value and hide the elements automatically?

Eric
 
Stan James
(instanceof Sidekick)
Posts: 8791
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Much, better than my suggestion. Thanks!
 
Forget Steve. Look at this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic