www.webdeveloper.com
Results 1 to 2 of 2

Thread: Borders with CSS

  1. #1
    Join Date
    Sep 2009
    Posts
    172

    Borders with CSS

    All,
    I'm trying to put borders around certain places and I can't figure out how to do it. I have the following code:
    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <title>Untitled Document</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    </head>
    <body style="padding:0px; margin:0px;"> 
    <table width="590">
      <tr>
        <td colspan="3" rowspan="2" style="border-right-color:#7D7D7D; border-width:5px;">
    		<img src="images/TopLeftText.png"> </td>
        <td width="314" height="124" valign="bottom"><img src="images/news.png"></td>
        <td width="174"><img src="images/logo.png" width="146" height="122"></td>
      </tr>
      <tr>
        <td height="56" colspan="2" background="images/LeftSidebarBlueBackground.png"><img src="images/you_can_use.png"></td>
      </tr>
      <tr>
        <td width="25" rowspan="2"  background="images/LeftSidebarBlueBackground.png">
    	</td>
        <td width="125" height="31" background="images/LeftSidebarBlueBackground.png"></td>
        <td width="25" rowspan="2" background="images/LeftSidebarBlueBackground.png"></td>
        <td colspan="2" rowspan="2" valign="top">
    	<div style="padding:10px; ">
    		<h1>Headline 1</h1>
    		<p>Igna faci ero conullaortie dolor at. Henit, vulluptatie cortinc illamet, sit, quamet, conseq-uisl ullutate tissequat ipeugait autat lum ipissed modiamconse tat.
    		</p>
    		<p>Gue facillamet, sit nullandit, quate dolore dio deliusciduisim dolum dolor incip exer alissed minisim verit volesequisi tionsequat. Putpat vercidunt vent venim nibh eniam irit nim velisi.
    		</p>
    		<p>Doloreet, cons elit illa conum nullaore vulluptatio et ing eu faccummy nullum vulpute mincidu iscipsum- mod duisi.
    		</p>
    		<h1>Headline 2</h1>
    		<p>Lit lobor sit wissi te delis dolut wis adit alis et, quis nullaorer si te molorem nim dolenit lum et lobore dunt niamcommy nos nonulla alisim dignim eum zzriusci blan hent lortionsenit et wisi.
    		</p>
    	</div>
      	</td>
      </tr>
      <tr>
        <td background="images/LeftSidebarGradientFillBackground.png" valign="top" bordercolor="#5C7E94"><div style="padding:10px"><img src="images/attorney1.png" width="100" height="100"><br>
    		<br>Name<br>
    		Title<br>
    		</div>
    	</td>
      </tr>
      <tr>
      	<td colspan="5" height="75px" background="images/footerbackgroundcolor.png" valign="middle">
    		<div align="center"><font color="#FFFFFF">Footer</font><br></div>
    	</td>
      </tr>
    </table>
    </body> 
    </html>
    You can see that in my upper left column I tried to add a right border but it still shows a space between my left column and my right column. Here is that code:
    Code:
    <td colspan="3" rowspan="2" style="border-right-color:#7D7D7D; border-width:5px;">
    <img src="images/TopLeftText.png">
    </td>
    Any ideas what I'm doing wrong? I don't want any spaces between my columns so I'm trying to specify where my borders should be. Thanks in advance!

  2. #2
    Join Date
    Sep 2008
    Location
    Akron, OH
    Posts
    1,112
    Try setting your cellspacing and cellpadding on the table.

    Code:
    <table width="590" cellpadding="0" cellspacing="0">
    I'm always up for networking with fellow web professionals. Connect with me on LinkedIn if you like!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles