Computing.Net > Forums > Web Development > Better way to force frames

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Better way to force frames

Reply to Message Icon

Name: RTAdams89
Date: December 2, 2008 at 18:24:53 Pacific
OS: na
CPU/Ram: na
Product: na
Comment:

I am currently using a pretty standard JavaScript coupled with the <body onload=""> tag to force pages into a frame set. Here is the script I am using:
<script language="JavaScript" type="text/javascript">
<!--
function into_frame()
{
if (top.location == location)
{
var str1, str2;
str1 = location.href;
str2 = str1.replace ("&", "andandand");
top.location.href = "http://asurfc.com/forum.php?iframe=" + str2;
}
}
-->
</script>

The only problem with this script is that there is a noticeable delay between the page loading, and the redirection to the frame set page. That is, the whole page is displayed to the user, and then the redirect occurs. Is there a better way to do the redirect (either in JavaScript or PHP) to eliminate this delay?

-Ryan Adams
Free Computer Tips and more:http://RyanTAdams.com

Paid Tech Support: Black Diamond



Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Web Development Forum Home


Sponsored links

Ads by Google


Results for: Better way to force frames

Content not lining up in frames www.computing.net/answers/webdevel/content-not-lining-up-in-frames/1059.html

Buttons with frames help www.computing.net/answers/webdevel/buttons-with-frames-help/528.html

Best way to redirect www.computing.net/answers/webdevel/best-way-to-redirect/3346.html