Photoshop Tutorials, Flash Tutorials, 3Ds Studio Max Tutorials, Web Design Tutorials


Software Tutorials

Featured Free Templates
View All Templates!
Preview  |  Download
Name: metamorph_flame
Downloads:
Preview  |  Download
Name: metamorph_skyandclouds
Downloads:
View All Templates!
Recommended Hosting:
Host Unlimited Domains on 1 Account
1500GB storage and 15000GB bandwidth for $6.95/mo!
Recommended Hosting:
Host Unlimited Domains on 1 Account
1500GB storage and 15000GB bandwidth for $6.95/mo!
:: Free Website Templates
Preview  |  Download Preview  |  Download Preview  |  Download
Name: metamorph_sunset Name: metamorph_flower Name: metamorph_waterfall
Downloads: Downloads: Downloads:

Do You Like Our Website? Share With Others!
GoogleGoogle slashdotYahooMyWebDiggTechnoratiDelicious
Page: 12345678910111213141516171819202122232425
CASCADING STYLE SHEETS AND SERVER SIDE INCLUDES
by Amrit Hallan

Highlight: Below, first we learn how to define individual tags with multiple definitions using the Cascading Style Sheets, and then we learn how to include common components on multiple web pages with minimum effort.

We packed up with external Cascading Style Sheets in the previous section, and I had mentioned like a sage that their could be a point in your life when you would like to implement different CSS definitions for different sections of the same HTML page. I understand that as you go through these HTML gospels, you're growing wiser and wiser, and your unquenchable thirst for wisdom is attaining new heights. Good!

We use the CLASS attribute to render different CSS definitions to same tags. Ok, before we move ahead, today I read in an article that tags in an HTML file should be used in small caps so that they can be used in sync with the emerging trends like XML etc. So small caps from now on.

Supposing, in one section, we want <a> </a> to look purple, and in another, we want <a> </a> to look black. If we do it in the usual

a { font-size : 10 pt; font-family : Arial; font-weight : bold; color : Purple; text-decoration : none; }

a:hover { font-size : 10 pt; font-family : Arial; font-weight : bold; color : Purple; text-decoration : underline; }

manner, we'll only have a purple colored <a> </a> tag because the definition is applied universally. So what do we do. We uses "classes" in this manner:

a.sec1 { font-size : 10 pt; font-family : Arial; font-weight : bold; color : purple; text-decoration : none; }

a.sec1:hover { font-size : 10 pt; font-family : Arial; font-weight : bold; color : purple; text-decoration : underline; }

a.sec2 { font-size : 10 pt; font-family : Arial; font-weight : bold; color : black; text-decoration : none; }

a.sec2:hover { font-size : 10 pt; font-family : Arial; font-weight : bold; color : black; text-decoration : underline; }

If you're the noticing type, you'll notice the use of sec1 and sec2, which we can take as the two sections. We execute these definitions in the HTML page somewhat like this:

<a class="sec1" href="http://www.hereforever.alive.org">To see the site of the immortals, click this purple text.</a>

<a class="sec2" href="http://www.goneforever.dead.org">To see the site of the dead, click this black text.</a>

Let's now life the CSS affairs and move on to the SSI - Server Side Includes.

Although in the real world, it depends on the guy/girl managing your server whether you can use the SSIs or not, assuming you can use them, you should know how and why to use them. First, why?

The use is somewhat akin to the external CSS. One change, and it is reflected through the entire web site, even if there are thousands of pages.

The ideal use is the navigation bar. Of course you know that every web site deserving to be called a web site must have a navigational system so that you can explore it in an amiable manner. On this web site - http://www.Bytesworth.com - if you can see those gray buttons on the right hand side, they help you navigate through hundreds of information pages.

To facilitate hurdle-less navigation, these buttons should be on every page, so that you can immediately click to the section of your desire, irrespective of where you are loafing around.

This is achieved by including the line

<!--#include file="nav.inc" -->

Where "nav.inc" is some file you deem fit to include. The extension "inc" does not have any technical implication in this case - you can have any extension. Whatever code is there in the included file, gets included in the HTML file. So wherever you want to use the include file's content, append the above line where you want the output to appear.

There is another way to include file such as <!--#include virtual="nav.inc" -->, but for the time being, you can do without it.

Including a navigation bar is not the only utility of the SSI's. You can come up with complex ASP and CGI codes to include in your page, but that is beyond the scope of this tutorial, at least at the moment.

Another thing to keep in my mind while making pages that are destined to have included files in them: there extension should be SHTML rather than HTML or HTM. This extension informs the ignorant server that the file being loaded is going to use the SSIs.

In the next section, we are going to deal with a navigation bar, and how to use tables (remember them?) for it. We'll also learn how to define bulleted list.

About the author:
Amrit Hallan is a freelance web designer. For all web site development and web promotion needs, you can get in touch with him at http://www.bytesworth.com. For more such articles, visit http://www.bytesworth.com/articles and http://www.bytesworth.com/learn You can subscribe to his newsletter [BYTESWORTH REACHOUT] on Web Designing Tips & Tricks by sending a blank email at Bytesworth-subscribe@topica.com


Advertisements
Graphic Software, Flash Templates, Free Stock Photos, Web Templates, Web Design, Corporate Web Design, Royalty Free stock Photo, Affordable Website Design, Submit site, Add Url, Stock Photos, Survey Software, Anti Virus Software, E mail software, Computer Software

Premium Partners
  Free Website Templates - Flash templates, Affordable Website Design, Website Templates, Website Redesign, Custom Website Design, Web Design Tutorials, Flash Tutorials, Promotion Tutorials - that is what we do. Metamorphosis Design Studio offers quality, free and low cost web site templates for your business and personal life, we also offer affordable web design and site re-design.
  Vertex Website Tempales - It saves tones of time and money to use pre-made web designs to build your web site. You need a web site but you don't want to pay thousands dollars to professional web design companies? Our web templates is just for you! They are designed to be easilly edited by your favorite html editor, like MS FrontPage
  Photoshop Tutorials - Learn how to build stunning web pages using Adobe Photoshop, Macromedia Flash MX and 3D Studio Max software. The step-by-step approach makes it so easy, that even beginners can produce great web pages. Get started with these tutorials covering everything from page layout to content tips.
Free website templates and paid web templates are great tools to make your websites look perfect! You will save time and money with our flash templates and free website templates Our visitors are satisfied with the quality of our free and paid website templates! Please visit our free website templates and paid website templates sections. We offer free web templates, free web layouts, free web page templates and other stuff for free download. All templates come with the html and external css file so you may easily edit HTML with your favorite HTML editor. Feel free to download our free web templates for your personal websites.

Terms of use depend upon the website template vendor.
Home  |  Submit Tutorial  |  Top Sites  |  Free Templates  |  Website Templates  |  Privacy Policy  |  Contact Us
All Right Reserved by WebDesignTutorials.net