Posts Tagged ‘advantage’

Web Designing-Take advantage of the cascade

Wednesday, July 16th, 2008

The cascade lets you use multiple rules to specify the properties for an element. You can either redefine the same property or define additional properties. Let’s say you have the following markup:

1. <p class=”update”>Update: Lorem ipsum dolor set</p>

In the CSS, you can use separate rules to specify the properties that are common to all p elements and those that are specific to p elements with class=”update”:

1. p {
2. margin:1em 0;
3. font-size:1em;
4. color:#333;
5. }
6. .update {
7. font-weight:bold;
8. color:#600;
9. }

The two rules will be combined for p elements with class=”update”. Since a class selector is more specific than a type selector, the properties defined in the second rule will be used when a conflict occurs, as for color in this case.

More info on how the specificity of CSS rules is calculated can be found in Calculating a selector’s specificity in the CSS 2.1 specification.

Web Designing-Default values

Wednesday, July 16th, 2008

You can often eliminate the need to specify a value for a property by taking advantage of that property’s default value. This is especially important to consider when you use shorthand properties, since any unset properties are assigned the default values of the corresponding individual property.

Some common default values are 0 for padding (though there are exceptions to this), and transparent for background-color.

Since there are slight differences in the default values between browsers, some people like doing a Global white space reset by zeroing both margin and padding for all elements at the top of their stylesheets:

1. * {
2. margin:0;
3. padding:0;
4. }

SEO for Bloggers

Thursday, June 26th, 2008

Part 1: Getting Started with SEO.  Start here to learn exactly what SEO is and the basics of how to use it to promote your message, including choosing your keywords properly.  If you only read one of these posts, read this one (but you really should bookmark them all!).

Part 2: Link Building and Link Popularity.  This post covers a key component of any blogger’s SEO strategy: getting tons of incoming links.  Search engines love websites that lots of people are linking too - after all, popular blogs are popular for a reason, and that reason is simple: people like ‘em.

Part 3: Link Baiting for Fun and Profit.   Link baiting is the art of getting other bloggers and webmasters to link to your site by creating interesting posts that benefit your readers in some way, shape, or form.  After all, people link to content they find compelling.

Part 4: Building Your Cornerstone.  Strong flagship posts are the pillars of blog - they are your most compelling content, they bring in the links, and they naturally have an ultra high keyword density.

Part 5: Off-Site SEO and the Social Media.   This post describes how to use the social media networks and the user-driven aspects of Web 2.0 to enhance and promote your blog.   There are a whole lot of amazing tools and communities out there, so use them to your advantage.