Results 1 to 3 of 3

Thread: IFrame SSI script II error

  1. #1
    Join Date
    Aug 2007
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default IFrame SSI script II error

    Hi,

    I am trying to use the IFrame SSI script II to change a website I am writing and have run into a problem.

    The dynamic frames are working, the problem I have is with a hyperlink

    I need to be able to change the contents of the frame via a link on the page currently loaded into the frame, I will try to explain in clearer English

    My test site is http://www.smovemove.co.uk/framed

    The main page loads a frame into 'mainframe' called welcomepage.html

    At the bottom of this page I have a link, when clicked I want the contents of frame 'mainframe' to change to placead.html

    I have copied into the code that I believe should work for this link

    <a href="javascript:loadintoIframe('mainframe', 'placead.html')" title="I WANT TO SAVE &pound;1000&rsquo;S">I WANT TO SAVE &pound;1000&rsquo;S</a

    But just get an error saying

    <code>is null or not an object

    Is what I am trying to do possible, I have trouble believing it's not

    And if so, any idea's what is wrong with my code.

    I have another test site

    www.smovemovedemo.co.uk

    This uses the same code and links but the hyperlinks are outside of the page loaded into the frame and it works fine...!

    Any help would be appreciated.

    Thanks...Pigsfoot

  2. #2
    Join Date
    Aug 2007
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Doh...

    sorry, posted my questions to teh wrong forum, it's now been moved.

    Thanks...Pigsfoot

  3. #3
    Join Date
    Aug 2007
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Fixed...

    Thanks everybody for having a look, been a bit of a plonker I’m afraid.

    I changed the link to be a standard Hyperlink and it fixed the problem. I think what has happened is because the page is already loaded inside the frame the new page that loads simply replaces it in the same place.

    The only time you will need to use the Javascript code it to load a different frame or when you completely change the main page with a new frame layout.

    Hope this helps anyone in the future...

    Cheers...Pigsfoot....

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
  •