Why Your Blog Should Probably Have a Print Stylesheet

If your blog has well-written and informative articles, like any good blog should, you should probably have a well-formatted print stylesheet declared. Just like your regular “screen” CSS controls how your webpage looks in a browser, the “print” stylesheet controls how your webpage prints on a printer.

First things first, you need to declare the stylesheet:

<link rel=”stylesheet” href=”print.css” type=”text/css” media=”print” />

Alternatively, you can pack all your “media styles” into one stylesheet, which is …

Chris Coyier Written by Chris Coyier from CSS-Tricks
Posted on February 29th, 2008 and filed under CSS
Do not forget to subscribe to our RSS feed for updates

Protecting Your Images From Theft

If you Google “stop image theft“, you will get some results of some really bad, non-effective ways of preventing image theft. Things like “disabling right-click” with JavaScript. Crippling usability is never good, especially when it will barely even slow down someone determined to steal your image. This is kind of like strip searching kindergardeners because one of them brought a knife to school once.

There are two different types of “theft” of …

Chris Coyier Written by Chris Coyier from CSS-Tricks
Posted on February 22nd, 2008 and filed under CSS
Do not forget to subscribe to our RSS feed for updates

Styling Specific Posts On Your Blog

One of the many, many smart things that WordPress does is apply the ID of posts to the div of that post. Most themes leave this intact, although I have seen some themes that remove it. This is how the container div for posts should look like:

<div class=”post” id=”post-<?php the_ID(); ?>”>

One of the reasons WordPress does this is for linkability. ID’s have that special ability to “skip down the page”, so if …

Chris Coyier Written by Chris Coyier from CSS-Tricks
Posted on January 25th, 2008 and filed under CSS
Do not forget to subscribe to our RSS feed for updates

Tips for Styling Code in your Posts

If you’ve ever included snippets of code on your blog, you know that presenting that text can be a unique challenge. HTML provides a tag for this purpose, the <code> tag. Unfortunately, just chucking your code in those tags isn’t the end-all solution. For one thing, you typically need to turn off your Rich Text editor and hand-write them in if you want to get those tags at all. For another, if …

Chris Coyier Written by Chris Coyier from CSS-Tricks
Posted on January 18th, 2008 and filed under CSS
Do not forget to subscribe to our RSS feed for updates

Document Your CSS Like You Are Working on a Team

Commenting your CSS is simple, just put them in between “/*” and */”, like so:

p {
font-size: 1.3em; /* Font size for main content */
}

That’s a single line comment, but you can do multi lines just as easily:

/*
Blog Design Template Author: Chris Coyier
Authors Website: css-tricks.com

Feel free to use, share, or alter this
template in any way.

Chris Coyier Written by Chris Coyier from CSS-Tricks
Posted on December 28th, 2007 and filed under CSS
Do not forget to subscribe to our RSS feed for updates

Seasonal CSS

With the changing seasons and the multitude of holidays some also change their sites design to fit. From winter and summer themes, too night and day, to Christmas and Valentines. But changing a sites look can be a chore, especially if you’re doing it frequently. But thats where CSS finds a perfect application, changing the entire look of your site with one file is certainly alot easier then the alternative. And now …

John Leschinski Written by John Leschinski from Leschinski Design
Posted on December 22nd, 2007 and filed under CSS
Do not forget to subscribe to our RSS feed for updates

File Paths in Your WordPress CSS and Theme Files

The directory of your WordPress theme probably looks a lot like this:

themedirectory.png

This is where all the files for your theme live, and this is where you will come to make edits. Notice the images folder in there. If your theme makes use of any images for it’s design (it probably does), they will be in this folder.

What can be a little confusing is just how to reference the images …

Chris Coyier Written by Chris Coyier from CSS-Tricks
Posted on December 21st, 2007 and filed under CSS
Do not forget to subscribe to our RSS feed for updates
Page 4 of 6« 1 2 3 4 5 6 »
Subscribe To BloggingTips Via RSS Subscribe To Blogging Tips Via Email Follow Us On Twitter Follow us on Facebook Find Out More About Our Newsletter

Sponsors

Blogging Tips Newsletter

Webmaster Corner

 

Our Free E-Books

Site Partners