Jump to content

Recommended Posts

Posted

Hello,

 

I have an Idea to do with javascript up it far beyond my mind and google.

 

On ecoadventure.com is the site

 

I have to load a popup when you first hit the site:

code looks like:

 

window.open ('index.html', 'newwindow', config='height=645, width=925, left=45, top=40, toolbar=no, menubar=no, scrollbars=no, resizable=yes, location=no, directories=no, status=no')

 

is their away to make it do like window.self so I don't load a popup

I looked in to window.resizeto but I can't take the menubar off and statsbar and so on.

 

???????????

Posted

All so tryed:

 

<script LANGUAGE="JavaScript">

<!--

window.resizeTo(655,450);

window.self.statusbar.visible=false;

window.top.scrollbars.visible=false;

window.self.personalbar.visible=false;

window.parent.directories.visible=false;

window.self.menubar.visible=false;

window.self.locationbar.visible=false;

window.top.toolbar.visible=false;

-->

</SCRIPT>

Posted

I don't think there's a way to do what you want without opening a pop-up window - which I strongly discourage anyway.

 

Actually, I'd advise you not to have that "entrance" page on your website. It may look neat the first time someone visits your site but the second time, the fun will be half replaced by frustration, since the visitor will have to wait ( = waste time, bandwidth and money) for the entrance page to load, click the logo on the center of the page and finally wait again for the main page to load up.

Think about it: if people go to your website, it's because they are interested in the contents, not a splash entrance page. :dance:

Posted

True...I ageer with you on splash screens I have done that till I can find how to make it not do a popup just do it to itsself their has to be a way to do it. I'm not that good with javascript but if yo can did it on a popup and I found you can do window.self just make seen you can do it to the main page while it loading.

 

talk to me on AIM. to maybe work these one out.

Posted

Well, I guess you were right!

 

window.resizeTo() is what you're looking for :dance:

resizeTo(x,y)  Resize the window to x by y pixels. Upper left corner stays where it is.

Note that if you want to resize the entire window from a frame, you need to do parent.window.resizeTo

Browser difference: Explorer and Netscape 6 takes x and y as the dimensions of the entire page, while Netscape 4 sees them as the dimensions of the inner window (without toolbars, location bars etc.). The example script below works around this browser incompatibility by subtracting the width and height of the toolbars and stuff (outerHeight - innerHeight) from the desired width and height.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...