WordPress.org

Support

Support » How-To and Troubleshooting » How to open a page that loads scrolled to the right.

How to open a page that loads scrolled to the right.

  • Hey all…

    I am working on fishingpierinc.com/vote.

    I have a page within a page. The inner page opens with a horizontal line. However it naturally loads to the left of the page. I would like it to load inner page scrolled to the right… and if possible, without the possibility to scroll horizontally.

    I have an iframe code for inserted page within the page.

    Thanks for the help!

Viewing 1 replies (of 1 total)
  • Well, I kept running into my own post throughout my search for the code and how to use it in iFrames. I worked it out… for those of you who may also need it this is what I worked up.

    <head>
    <style type=”text/css”>
    body{
    margin:0;
    padding:0;
    }
    #maincontainer
    {
            height:100%;
            width:100%;
    }

    </style>
    <script language=”Javascript”>
    function pageScroll() {
            window.scrollBy(1000,0); // 1st parameter – horizontal and 2nd parameter – vertical scroll increments
            scrolldelay = setTimeout(‘pageScroll()’,100); // scrolls every 10 milliseconds
    }
    </script>

    </head>
    <IFRAME SRC=”address.com” body onLoad=”pageScroll()” div id=”maincontainer” WIDTH=848 HEIGHT=500 right=0>
    </IFRAME>
    </html>

Viewing 1 replies (of 1 total)
  • The topic ‘How to open a page that loads scrolled to the right.’ is closed to new replies.