Welcome Guest ( Log In | Register)



2 Pages V  < 1 2  
Reply to this topicStart new topic
> Max Table Width
galexcd
post Oct 9 2005, 03:54 AM
Post #11


Define:EVIL PROGRAMMER (ē'vəl prō'grăm'ər)- n. An organism that converts caffeine into evil software.
*********

Group: [HOSTED]
Posts: 975
Joined: 25-September 05
From: The dungeon deep below the foundation of trap17
Member No.: 12,251



QUOTE(Tyssen @ Oct 4 2005, 03:13 PM)
Not if they've got js turned off it won't.  dry.gif
And if you know what you're doing with CSS, there are work-arounds to get IE to accept min-width & min-height.
*



how many browsers do you know nowadays that dont have js enabled?
Only weird people dont enable js on their browsers, or they do it to tempararily test something.
Go to the top of the page
 
+Quote Post
Tyssen
post Oct 9 2005, 07:26 AM
Post #12



***********

Group: Members
Posts: 1,161
Joined: 9-May 05
From: Brisbane, QLD
Member No.: 6,818



QUOTE(qwertyiscool @ Oct 9 2005, 01:54 PM)
how many browsers do you know nowadays that dont have js enabled?
Only weird people dont enable js on their browsers, or they do it to tempararily test something.

It's not browers; it's users and you'd be surprised at the number. It's generally not something that individual users do, but rather IT departments looking after big networks of computers that only want users to have the minimum of functionality.
Go to the top of the page
 
+Quote Post
iGuest
post Oct 31 2007, 06:20 AM
Post #13


Trap Double Mocha Member
***************

Group: Members
Posts: 2,360
Joined: 21-September 07
Member No.: 50,369



My first time here, and I noticed this question on max-width.
The problem of course is that IE doesn't recognize that property, but there IS a way around it. Unfortunately, the line of code wont validate, but blame IE for that, for not having a decent browser!!

This will apply to a main content table too, so you can go full width, but stop it expanding beyond a certain point. Say 1000px, that way you don't get your line length too long for comfortable reading.

Suppose you want the table to expand to 500px, but no wider?
In your style sheet, put the max-width: 500px; in the correct place. (in the body} section)
Now, you need to define how your table displays with IE
so add in this.

table {
width:expression(document.body.clientWidth > 500? "500px": "auto" );
}


This is for IE....it will work on versions above 4.

What it's saying, is, is the table wider than 500px? If so, make it 500px....anything below will expand to an auto width.
Firefox will ignore this, and IE will ignore the max-width, so you need both of them.

Unfortunately, the ? will stop a clean validation, but thats about the easiest way around the problem. There are other solutions, using ems, but they are more complex.

If only IE would design a compliant browser, these sort of problems wouldn't arise!

Cheers, Jonny.

-Jonny
Go to the top of the page
 
+Quote Post
iGuest
post Mar 19 2008, 08:19 AM
Post #14


Trap Double Mocha Member
***************

Group: Members
Posts: 2,360
Joined: 21-September 07
Member No.: 50,369



thanks, man
Max Table Width

Jonny, thanks man. You not only helped me control my table width, you also opened up a new galaxy for me-- css expressions.

People named jonny are tops.

-reply by johny
Go to the top of the page
 
+Quote Post

2 Pages V  < 1 2
Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. Table Width Help(2)
  2. Ie Table Width In A Div Tag(4)
  3. Width Of Display Area Of Browser Window(6)


 



- Lo-Fi Version Time is now: 27th July 2008 - 01:50 AM