Introduction to web design
Cascading style sheets is a common script used in the formatting and beautification of the web elements. The style recognizes three types which are normally used by many web developers depending on the choice of style they prefer. These styles include embedded, external and inline css types.
Inline CSS styles are styles that a web developer writes directly inside the code of the program. It is placed within the tags of a HTML document and as such influence or affect changes in the preceding elements associated with it. In other words the style will only influence the tag they are applied to. Bellow is an example of how the same style can be applied in HTM document (Nico, 2003).
The application of the above style will only affect the preceding text and any other text or elements placed in after the tag has been closed will not be affected in any way.
The main advantage of the inline CSS styles is that it allows for customization of the individual elements in the web page. The disadvantage is that it requires a lot of coding as each element must be applied a different style.
Embedded styles
Embedded styles unlike inline CSS style, is written at the head of the web document. This form of style has a lot of influence in the larger document. It affects the entire page in which the heading contains the CSS. However other pages are not affected by the style. If the first page contains the style, the effect of the same will only be felt on the first page and the subsequent pages will not be influenced by the same. To make the effects appear on the other pages, it will mean therefore that each page must have the same style embedded on each page. Below is an example how to embed CSS style on a web page (Gary, Albert, & Rivers, 2008).
p { color: #00f; }
This style reduces the difficulty experienced with inline style. A particular style will apply to the whole page and therefore save on time and resources. The disadvantage is that each page will require embedment of the style in order for efficiency to be realized.
External styles
The last style of application of CSS style sheets is external style. These are styles that are written in separate documents and then attached to various web documents. In essence a new document is created containing only the styles intended for use. The same document is then attached to the pages in which the effective style is desired to take effect. Most web developers recommend the use of external. Below is an example of how to attach an external style in CSS
This is the desired form of CSS application to the web pages. It is easy to implement and requires less time in coding. The only disadvantage is that it requires one to have good knowledge so that calling of the relevant functions can be realized.
Reference
Gary, S., Albert, N., & Rivers, O. (2008). Web design: introductory concepts and techniques. New York: Cengage.
Nico, M. (2003). What is web design? New Jersey: Wiley.