{ LearnWebSiteDesign.com }
HTML, HTML5, XHTML, CSS and CSS3 Tutorials
CSS Syntax Tutorial
CSS Syntax
In CSS (cascading style sheets), a series of rules are applied to one or more HTML documents. Each rule is made up of two main parts: a selector and one or more declarations.
Video Tutorial:
View our video tutorial to learn how to create HTML forms, text-fields, password fields, submit buttons and textareas.
| selector | The selector is typically the HTML element(s) that you want to apply the style(s) to. Following the selector is the declaration block. |
| declaration block | Everything within the curly brackets ({ and }) is called the declaration block. Each declaration block is made up of one or more declarations. You can have as many declarations as you want to have within each declaration block. |
| Declaration | Each declaration is made up of a CSS property and a value(s). |
| Property | The property is the style attribute of the HTML element that you want to change. |
| Value | The value specifies the change that you want made. |
NOTE: The property is always followed by a colon (:) and each declaration is separated with a semicolon (;).
| Selector: | Specifies what HTML element(s) the styles should be applied to. |
| Declaration Block: | Everything within the curly brackets ({ and }) is called the declaration block. |
| Declaration: | A declaration is a combination of a property and its' value(s). Each declaration block can contain an unlimited number of declarations. |
| Property: | The property is the style attribute that is to be changed. The property is followed by a colon (:) |
| Value: | Value(s) assigned to the property. The last value is followed by a semi-colon (;) |
An example of a CSS rule is shown below:
A CSS rule can be placed on one line or on more than one line to make it more readable, for example:
Comments in CSS
Comments are lines of text that you can place within your CSS code that will be ignored by web browsers. Commen
A CSS comment begins with a forward slash immediately followed by an asterisk (/*) and ends with and asterisk immediately followed by a forward slash (*/). CSS comments can span one or more lines. For example:
Tutorials
Templates
References
Sponsors
You can get your website online using Velnet, a leading UK web hosting provider. They provide free template and installation for WordPress blogs. Discuss webmaster related topics at Webmaster Serve, a Webmaster SEO forum
SouthernWebGroup.com provides high quality website design in Atlanta, GA as well as around the world.
Find low cost cheap website hosting and domain registration.
Browser our free no ads web hosting directory and find the free web hosting that's right for you and your budget.
Advertise your web design and web development related products and services here.
- Web Hosting UK
- Web Design Manchester
- Cheap Web Hosting
- free website hosting reviews
- ecommerce design
- Advertise
Recommended
Download free css web hosting templates that are easy to edit at FreeWebHostingTemplates.com.
Friends
- free web hosting templates
- free web hosting templates
- free web hosting reviews
- Web Development
- HD Wallpapers
- best web hosting providers
- Web Hosting Blog
- domain names
- iPage Host Reviews
- Reliable Bluehost Reviews
- Programming Forum
- Alojamento Web
- criar sites
- Free Facebook Banners
- Free No Ads Web Hosting Reviews
- Cheap Web Hosting Reviews
- Free Web Hosting Templates
- Free Premium Wordpress Themes
- Free Premium Wordpress Themes
- Free Joomla Template
- Free Wordpress Themes
- Best Android Apps
- Wordpress Themes Gallery
- Information technology courses
- Free PSD Files