<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>DesignBash &#187; CSS</title>
	<atom:link href="http://www.designbash.com/category/css/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.designbash.com</link>
	<description>web magazine and more...</description>
	<lastBuildDate>Fri, 25 Nov 2011 01:00:03 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>What is CSS?</title>
		<link>http://www.designbash.com/css/what-is-css/</link>
		<comments>http://www.designbash.com/css/what-is-css/#comments</comments>
		<pubDate>Wed, 23 Nov 2011 06:45:38 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://www.designbash.com/?p=342</guid>
		<description><![CDATA[While the average web designer already knows what CSS is, the average internet user might have no idea what this term refers to. In the hopes that budding web designers find this article, I&#8217;ll give a brief explanation about CSS (Cascading Style Sheets) and try to explain, in laymen&#8217;s terms, what it actually is. A [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><a href="http://www.designbash.com/css/what-is-css"><img class="size-full wp-image-351 aligncenter" title="what-is-css" src="http://www.designbash.com/wp-content/uploads/2011/11/what-is-css.jpg" alt="What is CSS?" width="500" height="150" /></a></p>
<p>While the average web designer already knows what CSS is, the average internet user might have no idea what this term refers to. In the hopes that budding web designers find this article, I&#8217;ll give a brief explanation about CSS (Cascading Style Sheets) and try to explain, in laymen&#8217;s terms, what it actually is.</p>
<p><span id="more-342"></span></p>
<h3>A Non-Technical Definition</h3>
<p><iframe src="http://rcm.amazon.com/e/cm?lt1=_blank&#038;bc1=F1F7AF&#038;IS2=1&#038;nou=1&#038;bg1=F1F7AF&#038;fc1=333333&#038;lc1=3838BD&#038;t=desbas-20&#038;o=1&#038;p=8&#038;l=as1&#038;m=amazon&#038;f=ifr&#038;ref=tf_til&#038;asins=0596527330" style="float: right; width:120px;height:240px; margin: 15px;" scrolling="no" marginwidth="0" marginheight="0" frameborder="0"></iframe></p>
<p>Imagine for a moment that you are writing a book. You&#8217;ve spent hours and hours developing a plot, characters, narratives, and other literary devices in the hopes that readers will enjoy your amazing story. You have finally arrived at the point where you would like to publish your <strong>content</strong> for the world to see. For the purposes of this example, we will call this content <strong>HTML</strong>. At the moment it is nothing more than plain, boring, simple text. There are no italics, there are no bolded words, there are no big headlines&#8230; just standard 10 point text.</p>
<p>When you finally send your story over to the book publishers, they read it over and start thinking about the best way of <em>presenting it</em>. Maybe your story should be written on old, torn up pages – or perhaps a more suitable brillent and pristine white finish would be more suitable? Regardless of what they decide, these are questions specifically related to <strong>presentation</strong>, not content. For the purposes of this article, <em>presentation <strong>is</strong> CSS</em>.</p>
<p>As you are probably starting to understand, there is a theoretical division between the content of your story and the presentation. They certainly influence each other, but the words that make up your story have no inherent effect on the aesthetics of your printed book.</p>
<p>The modern web has adopted this philosophy and creates a clear separation of content (HTML) and style (CSS). If you only take one thing away from this entire article, remember that <strong>content is HTML and style is CSS</strong>.</p>
<h3>So what is CSS?</h3>
<p>Now that you have a basic understanding of the division between CSS and HTML, it&#8217;s time to become a little more technical. Take a look at the little HTML snippet below. It contains a few basic tags, but nothing more&#8230;</p>
<pre class="prettyprint">
<code class="html">
&lt;p&gt;
This is a paragraph, with some &lt;strong&gt;bolded content&lt;/strong&gt;.
&lt;/p&gt;
</code>
</pre>
<p>When you look at the above HTML you can see pretty clearly what the author was intending. They wanted a paragraph with some bold text. But it&#8217;s important to realize that when a web browser (eg. Chrome, Firefox, Internet Explorer) reads this HTML, it does not have any idea what the &#8220;strong&#8221; tag actually means. It guesses that you want that text bolded, but it&#8217;s really nothing more than a guess.</p>
<p>Enter CSS. CSS is a way to tell the browser exactly how you would like to <em>style</em> your content. Perhaps within your story, you want all &#8220;strong&#8221; tags to be red instead of bold. Well, with CSS that&#8217;s really really easy:</p>
<pre class="prettyprint">
<code class="css">
/*
* This is CSS!
*/
strong {color: red;}
</code>
</pre>
<p>At the most basic level that&#8217;s all it is. <strong>CSS is just a way to tell the browser how it should present your content to the user</strong>. These days CSS is way more complicated than just bolding text <em>(it&#8217;s used to construct entire layouts)</em>.</p>
<h3>But Wait, there&#8217;s more!</h3>
<p>In the olden days, people used to use HTML to style their content. Originally, HTML contained special tags to make text bold, italic, or even blink. The problem with this method of organization became evident when larger sites started publishing their content. Big sites would have thousands of pages, all written in HTML, with huge numbers of tags that would define how content should look.</p>
<p>This created situations where changing the style of your content would require going through thousands of individual documents, modifying the archaic HTML tags that would force text to be bold. With the adoption of CSS, a big site only needs to change one central file to see the changes across their entire site.</p>
<h3>Where should I start?</h3>
<p>If you actually want to start coding CSS and HTML, then you should take a look at the following resources. They all do a great job of explaining the basics:</p>
<ul>
<li><a href="http://css-tricks.com/">CSS Tricks</a></li>
<li><a href="http://net.tutsplus.com/category/tutorials/html-css-techniques/?tag=basix">Nettuts &#8211; CSS &amp; HTML Basix</a></li>
<li><a href="http://oreilly.com/pub/a/javascript/synd/2002/03/01/css_layout.html">Introduction to CSS Layout</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.designbash.com/css/what-is-css/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Rounded CSS Corners &#8211; The Basics</title>
		<link>http://www.designbash.com/css/rounded-css-corners-the-basics/</link>
		<comments>http://www.designbash.com/css/rounded-css-corners-the-basics/#comments</comments>
		<pubDate>Sun, 14 Feb 2010 21:04:50 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Tutorials]]></category>

		<guid isPermaLink="false">http://www.designbash.com/?p=284</guid>
		<description><![CDATA[For those of us who no longer want to support Microsoft's lagging browsers, the best and fastest way to create rounded corners is by using CSS. ]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.designbash.com/css/rounded-css-corners-the-basics/"><img src="http://www.designbash.com/wp-content/uploads/2010/02/rounded-corners-CSS.jpg" alt="CSS Rounded Corners" title="rounded-corners-CSS" width="500" height="120" class="aligncenter size-full wp-image-297" /></a><br />
For those of us who no longer want to support Microsoft&#8217;s lagging browsers the best <em>(and fastest)</em> way to create rounded corners is by using CSS3. Using CSS corners will dramatically reduce your development time while keeping your markup clean and flexible.<span id="more-284"></span></p>
<p>As it stands, rounded corners are currently supported in modern versions of <strong>Firefox, Safari, and Chrome</strong>. Unfortunately, you&#8217;ll need to use two different declarations to get all these browsers working. The basic declarations should look something like this:</p>
<pre class="brush:css">

/* Supported in Firefox */
-moz-border-radius
-moz-border-radius-topleft
-moz-border-radius-topright
-moz-border-radius-bottomleft
-moz-border-radius-bottomright

/* Supported in Chrome and Safari */
-webkit-border-radius
-webkit-border-top-left-radius
-webkit-border-top-right-radius
-webkit-border-bottom-left-radius
-webkit-border-bottom-right-radius
</pre>
<h3>The Rounded Example</h3>
<p>Below you will find an example of rounded corners in action. If you&#8217;re using a modern browser you should see the grey box with rounded corners. <em>(if using IE, I&#8217;ve put in a screenshot of what things look like when using a respectable browser)</em></p>
<pre class="brush:css">
.rounded {
width: 500px;
padding: 30px 0px;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
border-radius: 10px;
}
</pre>
<div style="background: #ffffff; padding: 30px 0; border: 1px solid #cccccc; margin-bottom: 15px;">
<div style="background: #cccccc; width: 450px; margin: 15px auto; padding: 30px 0; -moz-border-radius: 10px; -webkit-border-radius: 10px;">
<p style="text-align: center; margin: 0; padding: 0;">This paragraph is inside a rounded DIV</p>
</div>
</div>
<h3>Screenshot Example For Internet Explorer <em>(sigh&#8230;)</em></h3>
<p><img style="border: 1px solid #cccccc;" src="http://www.designbash.com/wp-content/uploads/2010/02/ie-rounded-css.png" alt="ie Rounded Rectangle CSS Example" title="ie-rounded-css" width="558" height="170" class="aligncenter size-full wp-image-292" /></p>
<h3>But What Does the W3C Say?</h3>
<p>Due to the fact that border-radius is not officially supported by any browser, it might be a good idea to check out what the W3C has to say about the subject. I was surprised to see how detailed they were and I highly recommend <strong><a href="http://www.w3.org/TR/css3-background/#the-border-radius">checking out their official specs</a></strong>. As a reference, the official (but currently unsupported) declarations are:</p>
<pre class="brush:css">
border-radius
border-top-right-radius
border-bottom-right-radius
border-bottom-left-radius
border-top-left-radius
</pre>
<p>There are tons of neat variations you can do, but they go a little beyond the scope of this article. Check out the W3C specs for the full explanation, or, check out some of these links that do a good job documenting css rounded corners:</p>
<ul>
<li><a href="http://www.css3.info/preview/rounded-border/">CSS3 Info</a></li>
<li><a href="http://www.the-art-of-web.com/css/border-radius/">The Art of Web</a></li>
<li><a href="http://www.zenelements.com/blog/css3-border-radius-rounded-corners/">Zen Elements</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.designbash.com/css/rounded-css-corners-the-basics/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

