Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Web Programming > HTML > HTML Code Clinic
| Search | Today's Posts | Mark Forums Read
HTML Code Clinic Do you have some HTML code you'd like to share and get suggestions from others for tweaking or improving it? This discussion is the place.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the HTML Code Clinic section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old January 20th, 2004, 02:01 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: Arlington, TX, USA.
Posts: 119
Thanks: 0
Thanked 1 Time in 1 Post
Default Sync Top Frame with Web Page

We have a secured web site that contains a TOP FRAME which contains the banner to our website and then under that are our HTML/ASP pages. Our problem is that if a user is on a 15" monitor with a 800x600 resolution, when scrolling right the TOP FRAME does not move with the rest of the page. Is there a fix for this? If so, can someone give me some direction or help it would be appreciated.

Thank you.
  #2 (permalink)  
Old January 20th, 2004, 04:36 PM
planoie's Avatar
Friend of Wrox
Points: 16,481, Level: 55
Points: 16,481, Level: 55 Points: 16,481, Level: 55 Points: 16,481, Level: 55
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2003
Location: Clifton Park, New York, USA.
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

In the body tag of your main page (bottom frame):

<body onScroll="topFrame.document.body.scrollLeft = document.body.scrollLeft;">

Here's an example where the frameset actually sets up the "scroll syncing". Useful for an application with many pages that you might need to have this capability:

http://www.geekdork.com/samples/dhtml/HSyncedFrames.htm
(Look at the frameset source for the exact code.)

Peter
------------------------------------------------------
Work smarter, not harder.


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why does page scroll to top? dotnetDeveloper ASP.NET 2.0 Basics 7 July 28th, 2008 01:57 PM
Merge Replication using Web Sync Error wangjt18 SQL Server 2005 1 May 6th, 2008 04:54 AM
Chapter 15 p.774 at the top of page shade cat BOOK: Ivor Horton's Beginning Visual C++ 2005 0 June 5th, 2007 03:04 PM
Creating a "Frame" type page bruceaj CSS Cascading Style Sheets 7 April 16th, 2007 01:34 AM
question asked(bring flash page to the top) ExxWhyZee Flash (all versions) 1 April 13th, 2004 12:48 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.