CSS Shortcuts
March 12, 2011
Shortcuts are a good thing. They save time, gas, and make life easier. And who wouldn’t like things easier?
Shortcuts are a good thing. They save time, gas, and make life easier. And who wouldn’t like things easier?
A website tends to look more balanced when it’s centered on the monitor, instead of clinging to the left side with lots of white space on the right. This looks even worse with increased resolution. And it’s not that folks will use that white space to make notes…..
A webpage usually consists of several different parts – of course that can vary depending on content and design, but almost every page has a header, a navigation, content, and a footer. We’ve already discussed the beauty of an external stylesheet to define the look and layout of an entire website. For this reason, it’s very useful to proclaim the specific parts clearly in the html, so we can address them in the stylesheet.
There are actually three ways to add CSS to a web page and each one has a very specific purpose and use.
If I haven’t made it clear in the earlier HTML tutorials, I’m making it clear now: A well-designed website is styled with an external Cascading Style Sheet. Even as a child, "because I say so" was never good enough for me, and I don’t expect it to be good enough for you.
There is a list of HTML tags that have been deprecated, meaning they are outdated and should be avoided. Since browsers in general are backwards compatible, those tags still work, but there is no guarantee that they will continue to do so. And since using CSS is a much better, cleaner way to do things – then why NOT use it?
The <br> tag is called ‘line break’ tag, because it is meant to break lines. by inserting a single line break. It is not there to create paragraph breaks or to add space around images or move things around on your page.
Tables are often misused to lay out a page. Before CSS positioning, that was a good solution, but is no longer necessary, and with the better alternative, a bad idea. It creates quite a mess out of the code, which causes problems with spiders and search engines and makes updating a page much harder. However, using tables to display tabular date – which is what they are meant for – is perfectly fine.
There are three different types of lists that can be created with HTML: Ordered Lists, Unordered Lists, and Definition Lists. When to use which list largely depends on the content that’s being presented.
Another important and very useful feature of a website is the display of images. When coding a site, so, one does not actually include or insert images at all – the browser does that for us. We just need to tell the browser where to find and how to display the image.