My banner is aligned to the left under Internet Explorer but not Firefox, how to fix?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • gears
    Member
    • Dec 2006
    • 53
    • 3.6.x

    My banner is aligned to the left under Internet Explorer but not Firefox, how to fix?



    Firefox:



    Internet Explorer:




    Also, the titles on the forums appear centered.


    Here is the code in my header. Any idea what I'm doing wrong? Thanks


    -gears


    Code:
    <script type="text/javascript">
    
    /****************************************************
    *            DOM Image rollover:
    *        by Chris Poole
    *        [URL]http://chrispoole.com[/URL]
    *               Script featured on [URL]http://www.dynamicdrive.com[/URL]
    *        Keep this notice intact to use it :-)
    ****************************************************/
    
    function init() {
      if (!document.getElementById) return
      var imgOriginSrc;
      var imgTemp = new Array();
      var imgarr = document.getElementsByTagName('img');
      for (var i = 0; i < imgarr.length; i++) {
        if (imgarr[i].getAttribute('hsrc')) {
            imgTemp[i] = new Image();
            imgTemp[i].src = imgarr[i].getAttribute('hsrc');
            imgarr[i].onmouseover = function() {
                imgOriginSrc = this.getAttribute('src');
                this.setAttribute('src',this.getAttribute('hsrc'))
            }
            imgarr[i].onmouseout = function() {
                this.setAttribute('src',imgOriginSrc)
            }
        }
      }
    }
    onload=init;
    
    </script>
    
    
    
    
    <script language="javascript"> 
    <!-- 
    } 
    } 
    } 
    // --> 
    </script>
    
    
    
    <div align="center">
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <td>
       
    
     <td width="0" valign="top" style="background: url('$stylevar[imgdir_misc]/border_left_bg.gif') repeat-y top right; text-align: center;"><img src="$stylevar[imgdir_misc]/border_left.gif" alt="border" /></td>
        <td>
    
    
    
    <style type="text/css">
    <!--
    .style1 {
        font-family: Tahoma;
        font-size: 10px;
        color: #3c3c3c;
    }
    -->
    </style>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
    
    <!----------deleted header logo left--------->
    
    <!----------deleted header logo right-------->
    
    <!----------Front Page----------->
        <td width="151"><div align="center"><a href="index.php"><img src="http://www.politicsforumpoliticalworld.com/grunged/misc/header_right.jpg" width="700" height="135" border="0"></a></div></td>
    <!----------Front Page----------->
    
      </tr>
    </table>
    
    
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="25"><img src="$stylevar[imgdir_misc]/links_above_left.gif" width="25" height="12"></td>
    <!----------Deletion----------->
    <!----------Deletion----------->
        <td background="$stylevar[imgdir_misc]/links_above_bg.gif"><img src="$stylevar[imgdir_misc]/links_above_bg.gif" width="1" height="12"></td>
    
     
    
     <td width="25"><img src="$stylevar[imgdir_misc]/links_above_right.gif" width="25" height="12"></td>
      </tr>
    </table>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
      
        
    <!------deleted links underneath the banner here------>
    
        <td background="$stylevar[imgdir_misc]/links_bg.gif">&nbsp;</td>
        <td width="135" background="$stylevar[imgdir_misc]/links_bg.gif"><img src="$stylevar[imgdir_misc]/links_right.gif" width="135" height="32"></td>
      </tr>
    </table>
    
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td background="$stylevar[imgdir_misc]/links_undershadow.gif" bgcolor="#FFFFFF"><img src="$stylevar[imgdir_misc]/links_undershadow.gif" width="6" height="48"></td>
      </tr>
    </table>
    
    <!-- content table -->
    $spacer_open
    $_phpinclude_output
    Last edited by peterska2; Mon 29 Jan '07, 8:54am. Reason: added code tags

  • peterska2
    Senior Member
    • Oct 2003
    • 8869
    • 3.7.x

    #2
    Code:
     <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <td>
       
    
     <td width="0" valign="top" style="background: url('$stylevar[imgdir_misc]/border_left_bg.gif') repeat-y top right; text-align: center;"><img src="$stylevar[imgdir_misc]/border_left.gif" alt="border" /></td>
        <td>
    
    
    
    <style type="text/css">
    <!--
    .style1 {
        font-family: Tahoma;
        font-size: 10px;
        color: #3c3c3c;
    }
    -->
    </style>
    Where does this table end?

    Also right after the <table> opening row, you have two opening <td> rows.

    Comment

    • gears
      Member
      • Dec 2006
      • 53
      • 3.6.x

      #3
      I really have no idea where it ends. This is everything in the header:

      Code:
      <script type="text/javascript">
      
      /****************************************************
      *            DOM Image rollover:
      *        by Chris Poole
      *        [URL]http://chrispoole.com[/URL]
      *               Script featured on [URL]http://www.dynamicdrive.com[/URL]
      *        Keep this notice intact to use it :-)
      ****************************************************/
      
      function init() {
        if (!document.getElementById) return
        var imgOriginSrc;
        var imgTemp = new Array();
        var imgarr = document.getElementsByTagName('img');
        for (var i = 0; i < imgarr.length; i++) {
          if (imgarr[i].getAttribute('hsrc')) {
              imgTemp[i] = new Image();
              imgTemp[i].src = imgarr[i].getAttribute('hsrc');
              imgarr[i].onmouseover = function() {
                  imgOriginSrc = this.getAttribute('src');
                  this.setAttribute('src',this.getAttribute('hsrc'))
              }
              imgarr[i].onmouseout = function() {
                  this.setAttribute('src',imgOriginSrc)
              }
          }
        }
      }
      onload=init;
      
      </script>
      
      
      
      
      <script language="javascript"> 
      <!-- 
      } 
      } 
      } 
      // --> 
      </script>
      
      
      
      <div align="center">
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <td>
         
      
       <td width="0" valign="top" style="background: url('$stylevar[imgdir_misc]/border_left_bg.gif') repeat-y top right; text-align: center;"><img src="$stylevar[imgdir_misc]/border_left.gif" alt="border" /></div></td>
       <td>
      
      
      
      <style type="text/css">
      <!--
      .style1 {
          font-family: Tahoma;
          font-size: 10px;
          color: #3c3c3c;
      }
      -->
      </style>
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
      
      <!----------deleted header logo left--------->
      
      <!----------deleted header logo right-------->
      
      <!----------Front Page----------->
          <td width="151"><div align="center"><a href="index.php"><img src="http://www.politicsforumpoliticalworld.com/grunged/misc/header_right.jpg" width="700" height="135" border="0"></a></div></td>
      <!----------Front Page----------->
      
        </tr>
      </table>
      
      
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="25"><img src="$stylevar[imgdir_misc]/links_above_left.gif" width="25" height="12"></td>
      <!----------Deletion----------->
      <!----------Deletion----------->
          <td background="$stylevar[imgdir_misc]/links_above_bg.gif"><img src="$stylevar[imgdir_misc]/links_above_bg.gif" width="1" height="12"></td>
      
       
      
       <td width="25"><img src="$stylevar[imgdir_misc]/links_above_right.gif" width="25" height="12"></td>
        </tr>
      </table>
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
        
          
      <!------deleted links underneath the banner here------>
      
          <td background="$stylevar[imgdir_misc]/links_bg.gif">&nbsp;</td>
          <td width="135" background="$stylevar[imgdir_misc]/links_bg.gif"><img src="$stylevar[imgdir_misc]/links_right.gif" width="135" height="32"></td>
        </tr>
      </table>
      
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td background="$stylevar[imgdir_misc]/links_undershadow.gif" bgcolor="#FFFFFF"><img src="$stylevar[imgdir_misc]/links_undershadow.gif" width="6" height="48"></td>
        </tr>
      </table>
      
      <!-- content table -->
      $spacer_open
      
      $leftcolumn_advertisement
      
      $_phpinclude_output
      
      
      $welcomeheaders
      
      $header_advertisement
      Last edited by peterska2; Mon 29 Jan '07, 8:48am. Reason: added code tags

      Comment

      • gears
        Member
        • Dec 2006
        • 53
        • 3.6.x

        #4
        So I should get rid of one of the bolded <td>'s?

        Originally posted by Kerry-Anne
        Code:
         <table width="100%" border="0" cellspacing="0" cellpadding="0">
        [B]   <td>[/B]
           
        
         <td width="0" valign="top" style="background: url('$stylevar[imgdir_misc]/border_left_bg.gif') repeat-y top right; text-align: center;"><img src="$stylevar[imgdir_misc]/border_left.gif" alt="border" /></td>
         [B]   <td>[/B]
        
        
        
        <style type="text/css">
        <!--
        .style1 {
            font-family: Tahoma;
            font-size: 10px;
            color: #3c3c3c;
        }
        -->
        </style>

        Comment

        • peterska2
          Senior Member
          • Oct 2003
          • 8869
          • 3.7.x

          #5
          Ok, seeing as you don't know where the table is meant to end, and I don't know exactly how it's coded without spending a long time looking through your source code, this is a bit of guess work but it *should* work out right.

          FIND

          Code:
          <div align="center"> <table width="100%" border="0" cellspacing="0" cellpadding="0">
            <td>
             
          
           <td width="0" valign="top" style="background: url('$stylevar[imgdir_misc]/border_left_bg.gif') repeat-y top right; text-align: center;"><img src="$stylevar[imgdir_misc]/border_left.gif" alt="border" /></div></td>
           <td>
          REPLACE WITH
          Code:
          <table width="100%" border="0" cellspacing="0" cellpadding="0">
           <td align="center" valign="top" style="background: url('$stylevar[imgdir_misc]/border_left_bg.gif') repeat-y top right; text-align: center;"><img src="$stylevar[imgdir_misc]/border_left.gif" alt="border" /></td>
           </tr>
          </table>

          Comment

          • gears
            Member
            • Dec 2006
            • 53
            • 3.6.x

            #6
            It created a very large space above the banner that was black. Thanks for the try.

            Comment

            • gears
              Member
              • Dec 2006
              • 53
              • 3.6.x

              #7
              I think I've got it under control.

              I changed this part:

              Code:
              <!----------Front Page----------->
                 <td width="1051"><div align="center"><a href="index.php"><img src="http://www.politicsforumpoliticalworld.com/grunged/misc/header_right.jpg" width="700" height="135" border="0"></a></div></td>
              <!----------Front Page----------->
              Changed the td width from 151 to 1051.

              Comment

              widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
              Working...