SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Zealot Oznob's Avatar
    Join Date
    Jun 2002
    Posts
    161
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    iframe properties

    Here is my iframe code:

    Code:
     
    <IFRAME 
    
    src=http://www.URL.com name=main frameBorder=0 
    
    width=765 scrolling=yes height=578></iframe>
    
    
    QUESTION: Can i make a hyperlink that changes the scrolling variable (i.e. so i can have one link that changes the content of the 'main' iframe BUT also changes the main frame to be set to no scroll bars. Then of course i need to change it back so need to know if this is possible within the hyperlink code somehow.

    Any help appreciated.
    If the above is not clear - I will reattempt to explain below - if you get what I am after you can stop reading here .

    REPHRASED with EXAMPLE:

    I have my iframe on my page and named 'main'
    This iframe has properties set so the scrollbars ARE shown
    (i.e. scrolling=yes)
    I want to switch between two different content pages within this iframe
    I want one of the pages to show WITH scrollbars and...
    I want the other page to show WITHOUT scrollbars (i.e. scrolling=no)
    I want to be able to switch back and forth with a hyperlink
    I dont know how to do this


    Thanks in advance,
    Oznob

  2. #2
    SitePoint Wizard rbutler's Avatar
    Join Date
    Jul 2003
    Location
    Springfield, MO
    Posts
    1,867
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    What you could do is create another iframe tag within this main page to accompany the existing iframe and toggle back and forth. But you're going to have to create separate files to accomplish this. For example, say you have an index.html, that pulls two iframes, each side by side. The one on the right is completely independent of the one on the left. Within these files that make up both the right and left iframe, put links referecing the other files or the same files, does that make sense? And then just add scrolling=no to the <iframes> respectivefully. Hopefully I haven't confused you. If I have, let me know, and I'll create a quick example tomorrow, bit tired at the moment, or PM me.
    Ryan Butler

    Midwest Web Design

  3. #3
    SitePoint Zealot Oznob's Avatar
    Join Date
    Jun 2002
    Posts
    161
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    ......

    Aye - i understand i think - and I actually was thinking along same lines of just having my <iframe> with no scrollbars by default and intstead of pointing to the content i want in my scrolling frame - i point to a new 'loaderpage' that is simply an <iframe> with my content it it that HAS scrollbars on (i.e. an iframe in an iframe).

    Still - was thinking maybe another way of passing that variable back to the scrolling variable in a link somehow. If so - I will watch this post.

    Oznob

  4. #4
    SitePoint Wizard rbutler's Avatar
    Join Date
    Jul 2003
    Location
    Springfield, MO
    Posts
    1,867
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Oznob
    Still - was thinking maybe another way of passing that variable back to the scrolling variable in a link somehow. If so - I will watch this post.
    Oznob
    Unless someone comes along saying differently, don't think you can do what you're wanting with variables.
    Ryan Butler

    Midwest Web Design


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •