Announcement

Collapse
No announcement yet.

Adding to Header

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Adding to Header

    Hello... I would like to to add to the header of my site. I have created columns on the left and right. All works well on EVERY page till I add some thing to my header. The only page that doesn't work well is when I try to create a new thread (newthread.php, the same one I use to create this). The page will show up fine, but I am unable to type ANYTHING in the main body area, but I can type in a subject up above it.

    this is my header:
    PHP Code:
    <!-- logo -->
    <a name="top"></a>
    <script type="text/javascript">

    /****************************************************
    Start - added for image rollover
    ****************************************************/

    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;
    /****************************************************
    End - added for image rollover
    ****************************************************/
    </script>

    </head>
    <body>
    <table width="100%"  border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td><table width="794"  border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
            <td><img src="http://www.4xtraders.com/forum/images/main.gif" width="676" height="72" /></td>
            </tr>
        </table></td>
      </tr>
      <tr>
        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td valign="bottom"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td height="18" nowrap="nowrap" background="http://www.4xtraders.com/forum/images/blue_bottom_top.gif">&nbsp;</td>
              </tr>
            </table></td>
            <td>
              <table width="100%"  border="0" cellspacing="0" cellpadding="0">
                <tr>
                  <td><table width="794"  border="0" cellspacing="0" align="center" cellpadding="0">
                    <tr>
                     <td width="118" height="23" nowrap="nowrap"><img src="http://www.4xtraders.com/forum/images/globe_bottom.gif" width="118" height="23" /></td>
                     <td width="100" height="23" nowrap="nowrap"><img src="http://www.4xtraders.com/forum/images/gloss_w.gif" hsrc="http://www.4xtraders.com/forum/images/gloss_b.gif" width="100" height="23" /></td>
                     <td width="70" height="23" nowrap="nowrap"><img src="http://www.4xtraders.com/forum/images/stud_w.gif" hsrc="http://www.4xtraders.com/forum/images/stud_b.gif" width="70" height="23" /></td>
                     <td width="71" height="23" nowrap="nowrap"><img src="http://www.4xtraders.com/forum/images/review_w.gif" hsrc="http://www.4xtraders.com/forum/images/review_b.gif" width="71" height="23" /></td>
                     <td width="70" height="23" nowrap="nowrap"><a href="http://www.4xtraders.com/forum" target="_blank"><img src="http://www.4xtraders.com/forum/images/forum_w.gif" alt="Forex Discussion Board" width="70" height="23" border="0" hsrc="http://www.4xtraders.com/forum/images/forum_b.gif" /></a></td>
                     <td width="71" height="23" nowrap="nowrap"><img src="http://www.4xtraders.com/forum/images/resource_w.gif" hsrc="http://www.4xtraders.com/forum/images/resource_b.gif" width="71" height="23" /></td>
                     <td width="70" height="23" nowrap="nowrap"><img src="http://www.4xtraders.com/forum/images/demo_new_w.gif" hsrc="http://www.4xtraders.com/forum/images/demo_new_b.gif" width="106" height="23" /></td>
                     <td width="70" height="23" nowrap="nowrap"><img src="http://www.4xtraders.com/forum/images/blank.gif" width="70" height="23" /></td>
                     <td width="118" height="23"nowrap="nowrap">&nbsp;</td>

                  </tr>
                  </table></td>
                </tr>
                <tr>
                  <td><table width="100%"  border="0" cellpadding="0" cellspacing="0" id="table1">
                    <tr>
                      <td width="122" height="18" nowrap="nowrap" background="http://www.4xtraders.com/forum/images/blue_bottom_top.gif">&nbsp;</td>
                      <td width="583" height="18" nowrap="nowrap" background="http://www.4xtraders.com/forum/images/blue_bottom_top.gif">&nbsp;</td>
                      <td width="264" align="right" nowrap="nowrap" background="http://www.4xtraders.com/forum/images/blue_bottom_top.gif"><strong><div id="date"><?php echo (strftime ("%A, %d %B %Y"time()+($mosConfig_offset*60*60))); ?></div></strong></td>
                      <td width="122" height="18" nowrap="nowrap" background="http://www.4xtraders.com/forum/images/blue_bottom_top.gif">&nbsp;<script language="JavaScript1.2" type="text/JavaScript1.2">
    Function dated(){
    var now = new Date();
    var hours = now.getHours();
    var minutes = now.getMinutes();
    var time = hours + '  ' +minutes;
    var today = now.getDate();
    var month =  now.getMonth();
    switch(month){
    case 0 :
    monthname='January';
    break;
    case 1 :
    monthname='February';
    break;
    case 2 :
    monthname='March';
    break;
    case 3 :
    monthname='April';
    break;
    case 4 :
    monthname='May';
    break;
    case 5 :
    monthname='June';
    break;
    case 6 :
    monthname='July';
    break;
    case 7 :
    monthname='August';
    break;
    case 8 :
    monthname='September';
    break;
    case 9 :
    monthname='October';
    break;
    case 10 :
    monthname='November';
    break;
    case 11 :
    monthname='December';
    break;
    }
    document.write(''+today +' '+ monthname+' ');
    }
    //use
    dated();
                </script></td>
                    </tr>
                  </table></td>
                </tr>
            </table></td><td valign="bottom"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td height="18" nowrap="nowrap" background="http://www.4xtraders.com/forum/images/blue_bottom_top.gif">&nbsp;</td>
              </tr>
            </table></td>
          </tr>
        </table></td>
      </tr>
    </table>

    <!-- /logo -->

    <!-- content table -->
    <!-- begin left column -->
    <table width="stylevar[outertablewidth]" align="center" cellpadding="0" cellspacing="0">
    <tr>
    <td width="1%" align="center" valign="top">

    THE CONTENTS OF YOUR LEFT COLUMN
    </td>
    <td>
    <!-- end left column --> 
    $spacer_open

    $_phpinclude_output
    Any Help would be great as I realllllly want this in my header so I can have it on every page. let me know if you need any more info.
    Coll

  • #2
    I am guessing your custom javascript code is causing the problem. Try removing the javascript to see if that fixes it. If it does, then you know what the problem is.

    I am not very good with javascript. For help with troubleshooting your code, I recommend you post in the PHP / MySQL / JS / (X)HTML forum on www.vbulletin.org.

    Comment


    • #3
      Originally posted by Jake Bunce
      I am guessing your custom javascript code is causing the problem. Try removing the javascript to see if that fixes it. If it does, then you know what the problem is.

      I am not very good with javascript. For help with troubleshooting your code, I recommend you post in the PHP / MySQL / JS / (X)HTML forum on www.vbulletin.org.
      Man you are the boom... would of never thought it was the java... I commented it out and it works great.... Thanks so much,

      I'm off to org to post... once again thanks
      Coll

      Comment


      • #4
        Well I just took out the java script (it was a image rollover) also took out the 2 images and just made them css rollovers. Take a look www.4xtraders.com

        Comment


        • #5
          Were the people on www.vbulletin.org able to help?

          Comment


          • #6
            Originally posted by Jake Bunce
            Were the people on www.vbulletin.org able to help?
            I never got that far... I really just wanted the rollover, AND since I moved some of the navbar into the header, the images that I was having rollover looked very poor next to the rollover text with the CSS, so I just replaced the images with text and used the same CSS as what the navbar is using

            Comment

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