Lost Password?

Go Back   CodeCall Programming Forum > Web Development Forum > HTML Programming

HTML Programming Forum discussion covering HTML, XHTML, DHTML and all flavors of HTML. Hypertext Markup Language is used to create websites.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-13-2008, 02:59 PM
Xav's Avatar   
Xav Xav is offline
Guru
 
Join Date: Mar 2008
Location: London, England
Posts: 3,019
Last Blog:
Piano Exam
Rep Power: 26
Xav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to all
Send a message via MSN to Xav
Smile Size of Table Cell

I have a table split into two sections - the main content and the sidebar on the right. The sidebar consists of a single column, with multiple cells for each piece of info on the sidebar.

The sidebar cells use two CSS classes. For the heading cells, I am using a style to set the height of the cell to a certain (smallish) amount. I have also tried simply setting the 'width' property of the cell.

In both cases, the cell resizes correctly in Firefox, but in IE it's either the same as before, or really massive. Why does the cell behave like this? I'm setting it to 50px, and it shows as 50px in Firefox, but more like 300px in IE...
__________________
Xav, the power of youth
Worship the Creator... not his creations
Web Site | Beta Site
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #2 (permalink)  
Old 05-16-2008, 12:26 PM
Jordan's Avatar   
Jordan Jordan is offline
Administrator
 
Join Date: Nov 2005
Location: Hendersonville, NC
Age: 25
Posts: 4,529
Last Blog:
PHP: list()
Rep Power: 50
Jordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud of
Send a message via ICQ to Jordan Send a message via AIM to Jordan Send a message via MSN to Jordan
Default Re: Size of Table Cell

Do you have it on the web where I can view it? It is hard to diagnose without seeing it in both browsers myself. Also, post your CSS please.
__________________
CodeCall Blog | CodeCall Wiki | Shareware Site | Linux Forum | Write a Blog
Chat with other CodeCall members on IRC; connect to irc.codecall.net and join #codecall
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 05-16-2008, 12:35 PM
Xav's Avatar   
Xav Xav is offline
Guru
 
Join Date: Mar 2008
Location: London, England
Posts: 3,019
Last Blog:
Piano Exam
Rep Power: 26
Xav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to all
Send a message via MSN to Xav
Default Re: Size of Table Cell

Well, it's sort of rubbish and half-finished, but it's available here:

Home - Xav's Net Site

I don't have the CSS to hand, but I can tell you what it is:

@ The external CSS file contains the class "sidebar_heading", which contains the "width: 50px;" line (the other properties in the class work fine).

@ The CSS file is linked via a <link> tag. All the other styles work, including the background-color / text colour in the sidebar_heading class.

@ The cell links the CSS file, as in <td class="sidebar_heading">.

Is this enough info?
__________________
Xav, the power of youth
Worship the Creator... not his creations
Web Site | Beta Site
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 05-16-2008, 12:46 PM
Jordan's Avatar   
Jordan Jordan is offline
Administrator
 
Join Date: Nov 2005
Location: Hendersonville, NC
Age: 25
Posts: 4,529
Last Blog:
PHP: list()
Rep Power: 50
Jordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud ofJordan has much to be proud of
Send a message via ICQ to Jordan Send a message via AIM to Jordan Send a message via MSN to Jordan
Default Re: Size of Table Cell

Actually, I took a screenshot in FF and IE.

FF = 229px in Width
IE = 261px in Width.

Neither are actually 50px. You said you have "width: 50px;" above but I see this as your CSS:

HTML Code:
.sidebar_heading
{
background-color: #ff0000;
color: #ffffff;
font-size: 16px;
height: 50px;
}
I see no "width" but I do see a "height".


I want to point out some other errors.

You have:
HTML Code:
<tr class="sidebar_content"><td>
This site is dedicated to bring you only the finest of webpages.
Shouldn't this be:

HTML Code:
<tr class="sidebar_heading"><td>

This site is dedicated to bring you only the finest of webpages.
OR

HTML Code:
<tr><td class="sidebar_heading">
This site is dedicated to bring you only the finest of webpages.


You have:
HTML Code:
<td height="50px">Google Search</td>
You can't use "px" in a <td> tag. You can do:

HTML Code:
<td height="50">Google Search</td>
Or us inline CSS:

HTML Code:
<td style="height: 50px;">Google Search</td>
__________________
CodeCall Blog | CodeCall Wiki | Shareware Site | Linux Forum | Write a Blog
Chat with other CodeCall members on IRC; connect to irc.codecall.net and join #codecall
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 05-16-2008, 12:54 PM
Xav's Avatar   
Xav Xav is offline
Guru
 
Join Date: Mar 2008
Location: London, England
Posts: 3,019
Last Blog:
Piano Exam
Rep Power: 26
Xav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to all
Send a message via MSN to Xav
Default Re: Size of Table Cell

Sorry, my mistake. I meant HEIGHT, not WIDTH! Sorry for the confusion.

The cells containing the content are using "sidebar_content". I don't care how big those ones are for now - just the "sidebar_heading" one.

Just replace any occurences of "width" with "height" in my explanation. I just got that mixed up. Can you help?
__________________
Xav, the power of youth
Worship the Creator... not his creations
Web Site | Beta Site
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Sponsored Links
  #6 (permalink)  
Old 05-17-2008, 12:30 PM
Kaabi's Avatar   
Kaabi Kaabi is offline
Programming God
 
Join Date: Jul 2006
Posts: 884
Rep Power: 13
Kaabi is on a distinguished road
Default Re: Size of Table Cell

It's always weird how things work differently in Firefox than in IE. I'm sure the tables will work out fine, though.
__________________
Cheap Airsoft Guns

If you are looking for high-quality, yet cheap, airsoft guns, then check out MrAirsoft.com
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 05-17-2008, 12:54 PM
Xav's Avatar   
Xav Xav is offline
Guru
 
Join Date: Mar 2008
Location: London, England
Posts: 3,019
Last Blog:
Piano Exam
Rep Power: 26
Xav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to allXav is a name known to all
Send a message via MSN to Xav
Default Re: Size of Table Cell

I know - I think I've solved it, though. I'm just fixing it now.

It is IE that is the problem. IE is absolutely awful at rendering pages, and completely messes up on the Acid test (to see how good it is at displaying pages). Unfortunately, as IE is so popular, designers must make the page compatible, even if doing so introduces errors in the code.

However, the beta of IE8 passes the test, so maybe things are about to change... but what will happen to all those pages that were designed (with errors) to work on previous versions of IE?
__________________
Xav, the power of youth
Worship the Creator... not his creations
Web Site | Beta Site
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

BB 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
Layout problem with IE7 Alhazred HTML Programming 2 05-17-2008 12:37 PM
Tutorial: Advanced SQL Jordan Tutorials, Classes and Code 2 04-07-2008 03:18 PM
Mysql/Php help need mittalmak PHP Forum 17 01-12-2008 12:36 PM
ODBC API - Special Table and Column Names Tronman Database & Database Programming 0 07-30-2007 12:52 PM
Size of Table dirkfirst PHP Forum 2 08-06-2006 12:44 PM


All times are GMT -5. The time now is 11:28 PM.

Contest Stats

dargueta ........ 93.00000
John ........ 87.50000
Xav ........ 50.00000
MeTh0Dz ........ 20.00000
gaylo565 ........ 18.00000
Johnnyboy ........ 3.00000

Contest Rules

Ads