Results 1 to 6 of 6

Thread: IE and <object> problem

  1. #1
    Join Date
    Aug 2008
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default IE and <object> problem

    I can get IE to display my inserted objects as below. After some messing around I might add.

    However when I click a link in the object I am given an error and told about script errors.

    When I do the same thing in either Opera or Firefox under Windows or Linux I get no problems at all.

    Can you help as this is driving me nuts now.

    The main page calls the object as below - like I said it displays perfect.
    <p><object type="text/html" height="500" width="210" data="latest.html"></object></p>

    latest.html looks like this.

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
    <HTML>
    <HEAD>
    <link rel="stylesheet" type="text/css" href="toptips.css" />
    </HEAD>
    <body style="border:0;overflow:auto">

    <a href="link1.html">New training class</a>

    <p>As of 30th July we are offering training classes.</p>

    <a href="contact.html" target="_top">Can you help?</a>

    <p>Are you struggling to find training classes in your area?</p>

    <a href="http://www.some.site/" target="_blank">Some.Site</a>

    <p>For all the pampering your dog needs, why not treat them to a trip to the salon.</p><br>

    <p align="center"><img src="images/logo.jpg" title="Logo"/></p>


    </BODY>
    </HTML>

  2. #2
    Join Date
    Aug 2008
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    c'mon people

    64 views and no-one has an idea whats wrong?!!!

    Can anyone suggest then how I can load a basic html page inside another thus giving me a simple menu?

  3. #3
    Join Date
    Jul 2006
    Location
    just north of Boston, MA
    Posts
    1,806
    Thanks
    13
    Thanked 72 Times in 72 Posts

    Default

    loading 1 html page inside of another without a server side language is most popularly done through the use of frames... if you do not want a website done entirely in frames, you could use and inline frame <iframe>, however the best recommendation I have is to use some type of server-side language like (php/asp), which right now are the most popular and relatively easy to learn... and do an "include" statement that would actually parse the content of the extra page right into the existing page.

    If you do not have access to a server-side language or just do not want to use one, do a search on google for html frames or html iframe and just look through the tutorials

  4. #4
    Join Date
    Aug 2008
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I have tried a php include but the tutorial I looked through didnt work on my system.

    If anyone can recommend a simple php code that will work I will be more than grateful.

  5. #5
    Join Date
    Jul 2006
    Location
    just north of Boston, MA
    Posts
    1,806
    Thanks
    13
    Thanked 72 Times in 72 Posts

    Default

    PHP Code:
    <?php
    include_once('/path/to/script.extension');
    ?>
    the file that is using this script must now include the .php extension, meaning you cannot use a php command on a .html file

  6. #6
    Join Date
    Aug 2008
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Sorted - almost.

    It loads a file now and the links work correctly - something has just changed the colours though. I can sort that with a bit of tweaking.

    Thank you

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
  •