Jump to content

[SOLVED] Background images not showing.


csgcarl

Recommended Posts

Hello,

 

If someone could help me on whats wrong that would be great!

 

For some reason the background images don't show up...

 

<?php 
If ($vbulletin->userinfo['userid']!=0) 
    {      
    echo ' 
    <td style="background-image:url("http://www.battlestationextreme.com/images/homepage09.jpg"); height:40px"> 
      <table width="181" border="0" cellspacing="0" cellpadding="0" id="table28"> 
        <tr> 
          <td width="15"><img src="http://www.battlestationextreme.com/images/spacer.gif" alt="" width="15" height="40"></td> 
          <td width="166" class="text2"> My BSE</td> 
        </tr> 
        </table> 
    </td> 
      </tr> 

      <tr> 
        <td style="background-image:url("http://www.battlestationextreme.com/images/homepage10.jpg"); height:29px"> 
          <table width="100%" border="0" cellspacing="0" cellpadding="0" id="table29"> 
            <tr> 
              <td width="8%"><img src="http://www.battlestationextreme.com/images/spacer.gif" alt="" width="15" height="29"></td> 
              <td width="92%"><a class="link1" href="http://www.battlestationextreme.com/forums/usercp.php">Register!</a></td> 
            </tr> 
          </table> 
        </td> 
      </tr> 
      <tr> 
        <td style="background-image:url("http://www.battlestationextreme.com/images/homepage10.jpg"); height:29px"> 
          <table width="100%" border="0" cellspacing="0" cellpadding="0" id="table30"> 
            <tr> 
              <td width="8%"><img src="http://www.battlestationextreme.com/images/spacer.gif" alt="" width="15" height="29"></td> 
              <td width="92%"><a class="link1" href="http://www.battlestationextreme.com/forums/private.php">Login</a></td> 
            </tr> 
           </table> 
         </td>'; 
    } else { 
    echo "Your not logged in so we display this"; 
    } 
?> 

 

 

Thanks for looking.

 

Carl

Link to comment
https://forums.phpfreaks.com/topic/52320-solved-background-images-not-showing/
Share on other sites

do you need another ; after height?

 

td style="background-image:url("http://www.battlestationextreme.com/images/homepage09.jpg"); height:40px;"

 

instead of

 

td style="background-image:url("http://www.battlestationextreme.com/images/homepage09.jpg"); height:40px" ??

 

 

I always require a css file and do it there. sample code:

 

HTML

<td id="sample"></td>

 

CSS file

#sample {
background-image: url(../images/tip.gif);
background-repeat: no-repeat;
height: 153px;
width:215px;
display: block;
}

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.