Webmaster Forum

Advertise Here   Keyword Research Tool   V7N Directory
Go Back   Webmaster Forum > Web Development > Web Design Lobby > Coding Forum
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Coding Forum Problems with your code? Let's hear about it.

Reply
 
LinkBack Thread Tools Display Modes
Old 09-06-2007, 01:20 PM   #1 (permalink)
Inactive
 
Join Date: 09-06-07
Location: Toronto, Ontario Canada
Posts: 12
iTrader: 0 / 0%
Latest Blog:
None

CdnRebel is liked by many
using <div> tags instead of <table>, <tr>, <td>

Hi,

I am told it is better to use <div> tags than <table>, <tr>, <td>. Since I am creating a new website, I thought I should start with <div> tags. I used Adobe Photoshop 7 to convert my graphics to code, but it used <table>, <tr> and <td> tags. Although there are samples for changing most of the variables, I was unable to find samples where they dealt with the colspan and rowspan features. How would I convert the following?:

<TR>
<TD COLSPAN=3 ROWSPAN=2>
<IMG SRC="images/homePage_01.jpg" WIDTH=209 HEIGHT=149 ALT=""></TD>
<TD COLSPAN=12>
<IMG SRC="images/centre_Top.jpg" WIDTH=438 HEIGHT=92 ALT=""></TD>
<TD COLSPAN=3 ROWSPAN=2>
<IMG SRC="images/homePage_03.jpg" WIDTH=153 HEIGHT=149 ALT=""></TD>
</TR>

Thanks...
CdnRebel is offline  
Add Post to del.icio.us
Reply With Quote
Sponsored Links
SEO Hosting by HostGator  Advertise Here  Buy Blog Links
Old 09-06-2007, 04:08 PM   #2 (permalink)
Empress™
 
chicgeek's Avatar
 
Join Date: 08-19-04
Location: York, UK
Posts: 17,964
iTrader: 0 / 0%
Latest Blog:
My Favourite Poem

chicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest order
If you have a sliced layout and don't have a cue about css positioning, it might be easier to use the tabling you have.

What's with your crazy colspans? And I'm not sure your plans for the what goes in the second row, under the second image.

If you want to do it "right" with all CSS...

To go in the header, or an externally referred CSS file.
Code:
html, body, #wrap { width: 100%; margin: 0px; padding: 0px; } #ltop { background-image: url(images/homePage_01.jpg); width: 209px; height: 149px; position: relative; float: left; } #mtop { background-image: url(images/centre_Top.jpg); width: 438px; height: 92px; position: relative; float: left; } #rtop { background-image: url(images/homePage_03.jpg); width: 153px; height: 149px; position: relative; float: left; } .clear { clear: both; }
To go in your html file.
Code:
<div id="header"> <div id="ltop"></div> <div id="mtop"></div> <div id="rtop"></div> <div class="clear"></div> </div>
__________________
laura / chicgeek
soprano & web designer
laurakishimoto.ca
chıcgeeĸ @ flickr

Last edited by chicgeek : 09-07-2007 at 11:13 AM.
chicgeek is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-07-2007, 11:00 AM   #3 (permalink)
Inactive
 
Join Date: 09-06-07
Location: Toronto, Ontario Canada
Posts: 12
iTrader: 0 / 0%
Latest Blog:
None

CdnRebel is liked by many
The second row goes right below the second image between the first and third images. The second row is a menu bar and the bottom row of the webpage also has a number of tabs for clicking. So I need to be able to indicate the colspan and rowspan values for positioning somewhere. I am working on putting the information into a style sheet. I have a lot to learn yet. What does that last line -- #clear {
clear: both;
}
do?

Thanks
CdnRebel is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-07-2007, 11:26 AM   #4 (permalink)
Empress™
 
chicgeek's Avatar
 
Join Date: 08-19-04
Location: York, UK
Posts: 17,964
iTrader: 0 / 0%
Latest Blog:
My Favourite Poem

chicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest order
Is your website live? Might be easier to see what you're trying to do instead of verbally describing it.

And no better time to learn this than the present! Try taking a skim of some of the features here, particularly position: absolute, position: relative, and floats:The .clear class (I had initially put a #clear id, which is incorrect, sorry.) "resets" the layout, so that any new content will start after any floats that you used, instead of (potentially) beside it. A float essentially pushes things to one side, leaving the rest of the content to flow around it; a clear ensures content to start on a new line after the end of any floats.



More info. It's worth it.
__________________
laura / chicgeek
soprano & web designer
laurakishimoto.ca
chıcgeeĸ @ flickr
chicgeek is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-07-2007, 02:52 PM   #5 (permalink)
Inactive
 
Join Date: 09-06-07
Location: Toronto, Ontario Canada
Posts: 12
iTrader: 0 / 0%
Latest Blog:
None

CdnRebel is liked by many
Hi Laura,

No, the website is not live yet. I am just beginning to put it together. Thanks for all the info. I've checked them all and I have a better understanding. I'll just have to play around with it a bit to see what I can do with it.

Thanks again,
Mary
CdnRebel is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-07-2007, 02:58 PM   #6 (permalink)
Empress™
 
chicgeek's Avatar
 
Join Date: 08-19-04
Location: York, UK
Posts: 17,964
iTrader: 0 / 0%
Latest Blog:
My Favourite Poem

chicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest order
No problem, Mary!

It's a pretty steep learning curve, but worth the trudge. Play around with duplicating simple examples for a weekend and it'll come together. Ask here if you need any more help.

PS. Huzzah, Canadians.
__________________
laura / chicgeek
soprano & web designer
laurakishimoto.ca
chıcgeeĸ @ flickr
chicgeek is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-07-2007, 04:16 PM   #7 (permalink)
Inactive
 
Join Date: 09-06-07
Location: Toronto, Ontario Canada
Posts: 12
iTrader: 0 / 0%
Latest Blog:
None

CdnRebel is liked by many
Laura,

What does the #wrap in your style sheet do?

Thanks,
Mary
CdnRebel is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-07-2007, 05:10 PM   #8 (permalink)
Empress™
 
chicgeek's Avatar
 
Join Date: 08-19-04
Location: York, UK
Posts: 17,964
iTrader: 0 / 0%
Latest Blog:
My Favourite Poem

chicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest orderchicgeek is a web professional of the highest order
The wrap is essentially just a container. Keeps things nicely in a box. Sometimes it's useful to nest divs, sometimes its not. For example, if you have a page where you want all the content centered, you'd have #wrap with "padding: 0 auto;".

Here's a site and its css file that uses some floats. Might help you, might confuse you. If you'd like I could probably find a simpler example:

http://beartoothkawasaki.com/
http://beartoothkawasaki.com/style.css

Note in the css:
Code:
#navigation { width: 171px; position: relative; float: left; } #content { width: 601px; position: relative; float: left; }
__________________
laura / chicgeek
soprano & web designer
laurakishimoto.ca
chıcgeeĸ @ flickr
chicgeek is offline  
Add Post to del.icio.us
Reply With Quote
Go Back   Webmaster Forum > Web Development > Web Design Lobby > Coding Forum

Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Showing data from a table based on infos from another table! anarchoi Coding Forum 0 06-16-2007 04:58 PM
CSS Table-less madeinacari Coding Forum 4 04-19-2006 12:23 PM
.swf as table bg uuood Coding Forum 3 04-19-2006 11:10 AM
Table Gap ?? Sketch Coding Forum 2 08-30-2005 04:11 PM
Table help Leader of Men Coding Forum 5 11-25-2003 10:53 AM


Sponsor Links
Get exposure! Get exposure! Find Scripts Web Hosting Directory Get exposure! SEO Blog


All times are GMT -7. The time now is 05:49 PM.
© Copyright 2008 V7 Inc


Search Engine Optimization by vBSEO 3.1.0 ©2007, Crawlability, Inc.