Extra Space in IE - The Sequel

Discussion in 'HTML' started by fleemo17@comcast.net, Jun 21, 2006.

  1. Guest

    I have another table layout that looks good in all the browsers I've
    tested it in *except*, once again, IE on the PC. In IE there's extra
    space around some of the table cells making up the layout. Apparently,
    the problem lies with the bit of javascript I've used to randomly
    display a photo on the page. If I take the javascript out, the pieces
    of the layout fit together seamlessly. Put the javascript back in and
    gaps appear.

    Here's the line of code:
    <td colspan="2"><script type="text/javascript"
    src="random_header.js"></script><noscript><img src="images/random1.jpg"
    width="268" height="275" alt="Polaroid of Kilee"></noscript></td>

    And here's the page:
    http://www.kileecooper.com

    Any clue why the addition of a javascript reference would add space
    around the layout?

    Thanks.

    -Ray
     
    , Jun 21, 2006
    #1
    1. Advertising

  2. Martin Jay Guest

    In message <>,
    writes
    >I have another table layout that looks good in all the browsers I've
    >tested it in *except*, once again, IE on the PC. In IE there's extra
    >space around some of the table cells making up the layout. Apparently,
    >the problem lies with the bit of javascript I've used to randomly
    >display a photo on the page. If I take the javascript out, the pieces
    >of the layout fit together seamlessly. Put the javascript back in and
    >gaps appear.
    >
    >Here's the line of code:
    ><td colspan="2"><script type="text/javascript"
    >src="random_header.js"></script><noscript><img src="images/random1.jpg"
    >width="268" height="275" alt="Polaroid of Kilee"></noscript></td>


    The HMTL of the page looks like this here.

    <SCRIPT src="The Kilee Cooper Website_files/random_header.js"
    type=text/javascript></SCRIPT>
    <NOSCRIPT><IMG height=275 alt="Polaroid of Kilee"
    src="The Kilee Cooper Website_files/random1.jpg"


    I'm not splitting hairs, though. Just pointing out that </SCRIPT> and
    <NOSCRIPT> need to be next to each other, like so:

    <SCRIPT src="The Kilee Cooper Website_files/random_header.js"
    type=text/javascript></SCRIPT><NOSCRIPT><IMG height=275
    alt="Polaroid of Kilee"
    src="The Kilee Cooper Website_files/random1.jpg"


    And remove the "\n" from the random_header.js file, so:

    document.write(programs[index] + "\n");

    becomes:

    document.write(programs[index]);

    --
    Martin Jay
    Phone/SMS: +44 7740 191877
    Fax: +44 870 915 2124
     
    Martin Jay, Jun 21, 2006
    #2
    1. Advertising

  3. Guest

    > And remove the "\n" from the random_header.js file...<

    Martin, you da man! Removing that "/n" did the trick! Thank you!
    What the heck was that supposed to do, anyway?

    On a side note, the other items you mentioned, like having the <script>
    and <noscript> together, etc., it must be an issue of whatever you used
    to view the source code, as the actual code does do just that. Here's
    the code as it appears in the HTML document:

    <script type="text/javascript"
    src="random_header.js"></script><noscript><img src="images/random1.jpg"
    width="268" height="275" alt="Polaroid of Kilee"></noscript>

    But hey, bottom line is you fixed the problem! Many many thanks! :D
     
    , Jun 21, 2006
    #3
  4. wrote:
    >> And remove the "\n" from the random_header.js file...<

    >
    > Martin, you da man! Removing that "/n"


    \n, not /n

    > did the trick! Thank you!
    > What the heck was that supposed to do, anyway?


    Exactly what it did. In all the character strings of all C-like
    languages including Javascript, \n = new line, \r = carriage return, \t
    = tab, \f = form feed, etc.
     
    Harlan Messinger, Jun 21, 2006
    #4
  5. Martin Jay Guest

    In message <>,
    writes
    >> And remove the "\n" from the random_header.js file...<


    >Martin, you da man! Removing that "/n" did the trick! Thank you!


    Pleased to help. :)

    >What the heck was that supposed to do, anyway?


    \n is new line.

    >On a side note, the other items you mentioned, like having the <script>
    >and <noscript> together, etc., it must be an issue of whatever you used
    >to view the source code


    Oh, that's odd. But as you say, it may have been added by one of the
    applications I use. :(
    --
    Martin Jay
    Phone/SMS: +44 7740 191877
    Fax: +44 870 915 2124
     
    Martin Jay, Jun 22, 2006
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Shuo Xiang

    Stack space, global space, heap space

    Shuo Xiang, Jul 9, 2003, in forum: C Programming
    Replies:
    10
    Views:
    2,936
    Bryan Bullard
    Jul 11, 2003
  2. Christian Seberino
    Replies:
    21
    Views:
    1,717
    Stephen Horne
    Oct 27, 2003
  3. Ian Bicking
    Replies:
    2
    Views:
    1,053
    Steve Lamb
    Oct 23, 2003
  4. =?Utf-8?B?ZHc=?=
    Replies:
    5
    Views:
    1,133
    Alan Silver
    Jul 30, 2006
  5. Sharon Rosner
    Replies:
    0
    Views:
    151
    Sharon Rosner
    Apr 16, 2007
Loading...

Share This Page