473,779 Members | 1,867 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

CSS: Comments Please...

TAM
Hi,

I have redesigned one html page by removing all the tables. You can
see this test page at http://www.ngrain.com/css/home1.htm. Only
home1.htm has been redesigned without tables. Rest of the site uses
tables for layout.

I would appreciate if you can take a look at this page and CSS and
comment on the coding.

The page looks fine in IE but when I open up the page in Dreamweaver
or FrontPage, I see that all the div's are everywhere. Is it common or
something is wrong with the code?

This page looks fine in IE 6 but for some reason some parts of the
page are messed up in NN, Opera, Mozilla and FireFox. Do I need to
create a separate style sheet for NN, Opera, Mozilla and FireFox
browsers?

Thanks in advance and I look forward to your comments.

TM
Jul 20 '05 #1
2 1645
TAM wrote:
Hi,

I have redesigned one html page by removing all the tables. You can
see this test page at http://www.ngrain.com/css/home1.htm. Only
home1.htm has been redesigned without tables. Rest of the site uses
tables for layout.

I would appreciate if you can take a look at this page and CSS and
comment on the coding.

The page looks fine in IE but when I open up the page in Dreamweaver
or FrontPage, I see that all the div's are everywhere. Is it common or
something is wrong with the code?

This page looks fine in IE 6 but for some reason some parts of the
page are messed up in NN, Opera, Mozilla and FireFox. Do I need to
create a separate style sheet for NN, Opera, Mozilla and FireFox
browsers?

Thanks in advance and I look forward to your comments.

TM


Validate the CSS as well, at
http://jigsaw.w3.org/css-validator/validator-uri.html

BTW: http://tinyurl.com/68g9h is the result for the CSS at
http://www.ngrain.com/styles/basic_cross_plat.css
--
/Arne
Jul 20 '05 #2
On 20 Aug 2004 09:48:38 -0700, TAM <gr*******@cana da.com> wrote:
Hi,

I have redesigned one html page by removing all the tables. You can
see this test page at http://www.ngrain.com/css/home1.htm. Only
home1.htm has been redesigned without tables. Rest of the site uses
tables for layout.

I would appreciate if you can take a look at this page and CSS and
comment on the coding.

The page looks fine in IE but when I open up the page in Dreamweaver
or FrontPage, I see that all the div's are everywhere. Is it common or
something is wrong with the code?

This page looks fine in IE 6 but for some reason some parts of the
page are messed up in NN, Opera, Mozilla and FireFox. Do I need to
create a separate style sheet for NN, Opera, Mozilla and FireFox
browsers?
Basically, I think it looks spiffy in Opera. A nice overall look.
Thanks in advance and I look forward to your comments.

TM


Wow, this turned out long...

The scrollbar styles are not "valid" CSS. Be aware they will not function
in all CSS browsers. DOn't have to actually remove them, I don't think
they do any harm, just don't claim valid CSS.

The most important goal in web design is making the text readable. When
you size fonts in points, IE users cannot resize the text. There is no way
of determining how many points or pixels are too small for your many
users, so this unit is not useful for the WWW.

Instead, use 100% which is based on the default font-size of the UA, which
has either been customized by the user or works well enough that the user
has seen no need to adjust it. Use 90% at minimum for non-critical content
like legal stuff. Serve any content you want every user to read at
font-size: 100% or higher.

When you use Verdana with its large x-height (it's like 7 or 8) it's
natural to make it small, as the x-height makes it legible at smaller
sizes. Now, if we could guarantee that each user had Verdana, it wouldn't
be so bad. But since we know some users don't have it, what will they see?
Arial or Helvetica, or their default sans-serif, all of which will have an
x-height of about 5. Smaller x-height = harder to read. Therefore, those
users will have difficulty accessing the content. Unless you make the
font-size such that Verdana looks stupidly big, the backup fonts will not
be legible. Solution: only use fonts in web pages whose x-heights are
about 5, or serve large x-height fonts conservatively large.

Be sure you set styles which apply to many elements higher up the tree. If
all (or most of) the text on your page is sans-serif or 100% or green, set
that in body and change it where needed. If many selectors will get almost
the same style, do it once:

..one, .two {font: italic 105% serif; border: 1px solid red; color: green;
background: white;}

and then make a small change to one.
..two {font-size: 110%;}

What we see in your CSS is typical generated output. The tool is dumb, you
be the brains.

Be cautious when setting widths as absolutes (pixels). As the goal is to
make the font-size right for the user, in some renderings there may be
overflow. Wisest to stick to ems for widths. Or, use % to make use of the
whole canvas - pixel-based widths inevitably end up shoved way over, or
centered with wide blank space either side, in say 25% of UAs, and in
another 25% it's wider than the viewport and invokes the user-unfriendly
horizontal scrollbar. That's what happens with your site, too.

A lot of web designers make the error of designing the website as if it
was an 8 1/2 x 11 sheet of paper. The paper's size is an unknown in web
design, and the best designers work with that rather than attempt to
eliminate it, as if it were a bug of browsers that they can be resized! If
you could make this flex to the user's viewport width, that would be an
improvement. It would be a little complicated, but doable.

A:link.topNav {color:#465465; text-decoration:none }

How do I know it's a link? Underlining on the WWW is universally
understood to mean "this is a link". Unless you have made absolutely clear
in some other way, leave in the underline.

Develop the habit of always specifying color and background together. If
the user has a custom stylesheet it may overrule your style, and make it
illegible. Although user stylesheet writers should be careful to avoid it
on their end, this is simple enough. Set color as inherit, or background
as transparent.

padding-top: 10px;
padding-right: 0px;
padding-bottom: 5px;
padding-left: 0px;

Use shorthand here. And no need for units on 0.

padding: 10px 0 5px;

Finally, I notice you have two divs nested in the HTML.

<div id="contain" class="containe r">
<!-- container begins -->
<div id="MainBody" class="body">
<!-- MainBody begins -->

....

</div><!-- MainBody ends -->
</div><!-- container ends -->

These divs are not used in the stylesheet. Why have this?
Jul 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
2050
by: Michael Kalina | last post by:
Hi everybody! I have three questions, maybe somebody could help me with it. 1. "If you have a minute or two..." I usually do not do a lot with CSS, but I decided to have my site run on pure xhtml and css. Now I made it, but I do not know, whether I "coded" a good css or not. If somebody has some minutes free, could you please post your opinion on my css, which you will find here:
8
4103
by: slawek | last post by:
Hi i have following stylesheet: ..linklist { width: 100%; font-size: 75%; background: #EEEEEE; margin: 5px; height: 300px; overflow: auto;
8
1716
by: TAM | last post by:
Hi, I have two pages designed using CSS (without tables), http://www.ngrain.com/CSS/home1.htm designed for IE and http://www.ngrain.com/CSS/home2.htm designed for NN, Mozilla, FireFox and Opera.
4
1726
by: Rob Ireland | last post by:
I'm working an a page... http://www.start.ca/users/bbscentr/ and I'm trying to get CSS set up so I can change the menu/menu options as I change sections on the site (The whole point of CSS, of course ;) ) I can't seem to get it to work though. Can anyone tell me what I'm missing? I'm new to CSS, so please forgive my naivete(sp?)
15
2230
by: Davide R. | last post by:
Ciao a tutti, vi spiego il mio problema Ho una pagina HTML che referenzia un CSS esterno. Ho alcuni elementi HTML che appartengolo ad una classe (chiamiamola "class1"). Avrei la necessità, alla pressione di un tasto di lanciare un javascript che mi cambia un attributo della classe "class1" (per esempio 'font-size', ma potrebbe essere qualsiasi altro attributo). Teoricamente potrei fare un loop in tutti gli elementi della pagina e
32
2584
by: Alan Silver | last post by:
Hello, I shamefully admit to be an old web designer, from before the days of CSS. In those heady days, tables were king and were used for every possible kind of alignment. When CSS came along, it was useful for specifying colours and fonts for a site in one central location, but useless for any real kind of design work due to the poor browser support. I got well in to using CSS for colours and fonts, but carried on using tables for...
19
3579
by: Dr Clue | last post by:
I'm not really an expert with RegExp() , although I do use it. The problem I have is that I want to strip comments out of a CSS file using RegExp() The reason is that I'm loading and parsing to simulate javscript access to stylesheets in Opera. I thought I had it licked untill the '/' characters in url('') tripped me up Below is a test case. I've tried many things. but if I can't figure out a nice clean RegExp(), I'm going to have to...
7
2178
by: Trammel | last post by:
Im trying to do something which I hoped would be alot easier than it seems. Im trying to design the layout of the page in CSS to avoid table, etc but having problems making the bottom "fade" background actually stick to the bottom of the page. Try making your browser window small... then scroll down & see how ugly it looks. ....now try resizing your browser & notice the wierd behavior. It also reacts differently in IE & FF (Which is...
5
10503
by: =?Utf-8?B?SmVycnkgQw==?= | last post by:
I have a machine running IIS 6.0. I just replaced the web.config and several aspx pages in the application and now the style sheets are not working. the images from the themes work but not the css files. Any help. -- Jerry
0
9636
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9474
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10138
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10074
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8961
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7485
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5373
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4037
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3632
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.