Portal   Forum   Members   Market   Gallery   Events

iframe help

Discussion in 'Help Forum' started by Jakeman, Aug 16, 2002.

  1. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,759
    Likes Received:
    27
    Market Rating:
    16
    i'm having trouble finding help elsewhere, so i'll try here :D .

    i am working on an improved design for the site. the new design uses an iframe for all the content so images only load once. this will reduce bandwidth usage and speed up load time. here is what i have so far - http://www.macsubculture.com/dev/iframe.php

    i got it so the iframe is generated when some one links directly to something within my forum. only two problems left.

    1) i have javascript in place that checks for the iframe. if it doesn't exist then you are redirected to iframe.php and the url of the page the user was original trying to load is passed to iframe.php through the url. the problem is that the iframe src that is passed through the url is getting truncated at the first ampersand. example:

    a user links directly to one of my forums and is redirected to this url - http://www.macsubculture.com/dev/iframe.php?iframesrc=http://www.macsubculture.com/dev/forumdisplay.php?s=&forumid=26 . the ending of the url (in bold) is truncated so that the iframe's src loads a page that says "no forum specified". it's getting confused because it thinks the &forumid=26 is a query of iframe.php . do you see the problem here? it's like i need to put the string value within quotes to separate it, except you can't do that with urls, can you?

    anyone know how i could fix this?

    2) the iframe's height. the iframes height is fixed at 600 pixels. ideally i would like a way to auto adjust the iframe's height to the height of the page inside the iframe... this way i could do away with the iframe's scroll bar and the iframe would be completely transparent to the end user. i haven't found a way to do this yet. in the meantime i'm just using a scroll bar.

    is it possible dynamically change the height of the iframe like that?
     
  2. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,759
    Likes Received:
    27
    Market Rating:
    16
    problem #1 solved by using some crude string cropping. :p

    a friend says he will try to figure out my problem #2 tomorrow.
     
  3. Beeble

    Beeble Peasant

    Joined:
    Jul 16, 2000
    Messages:
    2,699
    Likes Received:
    2
    Market Rating:
    0
    Good idea with the image thingy... I'm still using a 56k for a little until we get broadband, so it would be cool to hav the site load faster than it already does (fastest loading website i've been to on a 56k).
     
  4. aleldtritch

    aleldtritch Peasant

    Joined:
    Jul 15, 2001
    Messages:
    1,175
    Likes Received:
    0
    Market Rating:
    0
    your site loads fast anyway. why uglifiy it with frames?
     
  5. Jakeman

    Jakeman MSC Founder and Donator

    Joined:
    Feb 26, 2000
    Messages:
    25,759
    Likes Received:
    27
    Market Rating:
    16
    if i can fix problem 2 then the site will be visually identical and load much faster. that's the point of this post.
     
  6. aleldtritch

    aleldtritch Peasant

    Joined:
    Jul 15, 2001
    Messages:
    1,175
    Likes Received:
    0
    Market Rating:
    0
    oh, I should read all of your post.
     

Hitometer: 53,933,046 since 1995