Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Community Forums
 Community Discussions (All other subjects)
 Maximizing window before redirect
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Nertz
Junior Member

Canada
341 Posts

Posted - 11 August 2004 :  12:35:51  Show Profile
On one of my sites, I have a default.asp whose only line of code is a redirect to david's portal page. Prior to the redirect, I would like to maximize the browser window to full screen if possible.

I have successfully used in the past this little javascript from dynamicdrive to do just that, placing it within the <HEAD> </HEAD> tags of the initial intro page. In this case it won't work, the script is ignored and the redirected page loads fine in the initial sized window without any error returned. My guess being the lack of <HTML> and <HEAD> tags in the redirect page.

Putting this script in the inc_header.asp works on the initial load, but errors on subsequent page changes.

Anyone have any idea how I can do this without using an intro page? Any suggestion would be greatly appreciated. Thanks....

cheers,
Nat

Sadly, most Family Court Judges wrongfully reward opportunistic gold diggers
that use our children unjustly as "instruments" of power.


www.fathers-4-justice-canada.ca

OneWayMule
Dev. Team Member & Support Moderator

Austria
4969 Posts

Posted - 11 August 2004 :  23:33:28  Show Profile  Visit OneWayMule's Homepage  Send OneWayMule an ICQ Message
quote:
My guess being the lack of <HTML> and <HEAD> tags in the redirect page.

What is holding you back from adding them? Simply output the required HTML and JavaScript and then redirect.

My MODs:
Birthdays - Custom Policy - F.A.Q. Administration - Forum Rules - Guestbook
Links Manager - MyOwnGoogle - Profile Views - Search Log - WebSearch

Useful stuff:
Forum and MOD Installation - MOD Installation Guide - Snitz v3.4.05 Readme - Free ASP Hosts - Support Snitz
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 12 August 2004 :  04:39:35  Show Profile  Send pdrg a Yahoo! Message
Interesting point here - at what point does the cache write to the client? The redirect will flush the cache, so maybe this stuff is never actually reaching the client, as the isapi will cache the page as it builds it up, then drop it all when it hits the response.redirect

I cannot remember the full syntax, but something along the lines of cache.sendtobrowser (ok so I completely forgot the syntax) should sent the partial page before the response.redirect, however I still doubt there will be an event to fire the script? Ideas, anyone?
Go to Top of Page

OneWayMule
Dev. Team Member & Support Moderator

Austria
4969 Posts

Posted - 12 August 2004 :  05:20:36  Show Profile  Visit OneWayMule's Homepage  Send OneWayMule an ICQ Message
Works for me:
http://www.onewaymule.org/redirect.asp

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
  <TITLE>Untitled Document</TITLE>
<script language="JavaScript1.2">
<!--
/***********************************************
* Auto Maximize Window Script- © Dynamic Drive (www.dynamicdrive.com)
* This notice must stay intact for use
* Visit http://www.dynamicdrive.com/ for this script and 100's more.
***********************************************/
top.window.moveTo(0,0);
if (document.all) {
top.window.resizeTo(screen.availWidth,screen.availHeight);
}
else if (document.layers||document.getElementById) {
if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<screen.availWidth){
top.window.outerHeight = screen.availHeight;
top.window.outerWidth = screen.availWidth;
}
}
//-->
</script>
<meta http-equiv="Refresh" content="0; URL=http://www.onewaymule.org/onewayscripts/">
</HEAD>
<BODY BGCOLOR="#FFFFFF">
</BODY>
</HTML>

My MODs:
Birthdays - Custom Policy - F.A.Q. Administration - Forum Rules - Guestbook
Links Manager - MyOwnGoogle - Profile Views - Search Log - WebSearch

Useful stuff:
Forum and MOD Installation - MOD Installation Guide - Snitz v3.4.05 Readme - Free ASP Hosts - Support Snitz
Go to Top of Page

Nathan
Help Moderator

USA
7664 Posts

Posted - 12 August 2004 :  05:31:22  Show Profile  Visit Nathan's Homepage
I advise you that messing with the window size is going to anger a portion of your audience.

Nathan Bales
CoreBoard | Active Users Download
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 12 August 2004 :  06:53:52  Show Profile
I'm with Nathan on this; any script that causes a vistor's browser/system to do something unexpected like this is one sure fire way of driving them away. If they want a maximised window; they'll hit the little square in the top-right of their browser window.


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

pdrg
Support Moderator

United Kingdom
2897 Posts

Posted - 12 August 2004 :  07:27:09  Show Profile  Send pdrg a Yahoo! Message
thirded - i feel the browser is *MINE* as it's on *MY* PC, so if I wanted it big, I'd ask for it
Go to Top of Page

Nertz
Junior Member

Canada
341 Posts

Posted - 12 August 2004 :  08:15:03  Show Profile
All, thanks for the comments. I know some may have objections to resizing the window, and I have taken those concerns in consideration... perhaps the subject of another discussion but the point is well taken.

Onewaymule, thanks for the example. Been so caught up into ASP that I had never thought of using meta http-equiv for the redirect. You're a genius!!!

cheers,
Nat

Sadly, most Family Court Judges wrongfully reward opportunistic gold diggers
that use our children unjustly as "instruments" of power.


www.fathers-4-justice-canada.ca
Go to Top of Page

OneWayMule
Dev. Team Member & Support Moderator

Austria
4969 Posts

Posted - 12 August 2004 :  08:49:05  Show Profile  Visit OneWayMule's Homepage  Send OneWayMule an ICQ Message
Glad to be of help.

My MODs:
Birthdays - Custom Policy - F.A.Q. Administration - Forum Rules - Guestbook
Links Manager - MyOwnGoogle - Profile Views - Search Log - WebSearch

Useful stuff:
Forum and MOD Installation - MOD Installation Guide - Snitz v3.4.05 Readme - Free ASP Hosts - Support Snitz
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.38 seconds. Powered By: Snitz Forums 2000 Version 3.4.07