HTML Basix - HTML tutorials and online webmaster tools

Htaccess code generators Code generators Tutorials

Subscribe to RSS feed
Subscribe to the HTML Basix RSS feed.

Stylesheet Code Generator

Use CSS to set your font/colour values for your website. If you use an external stylesheet, change values site-wide by changing one value in your stylesheet. Code can be placed on your webpage, which will set the style of that page only - or save your code in a file which you can link to from whichever page you choose.

Choose an element if you wish to style all instances of that element
For example:

  • body - sets the style for the body
  • p - formats all text between <p> </p> tags
  • td - formats text/properties of all <td> cells
  • etc...

Enter a 'name' instead if you wish to have different 'classes' to use for different elements
Say you called one class 'test'. Wherever you wanted something formatted with the 'test' properties, use the 'test' class:
For example:

  • <div class="text">
  • <span class="text">
  • <p class="text">
  • <td class="text">
  • etc...

Enter a 'name' and choose an element if you wish to have different 'classes' of the same element.
Say you chose 'p' and called one class 'red'. Wherever you wanted the <p> tag formatted with the 'red' properties, use <p class="red">. Choose a 'blue' class with the 'p' element, and you can also use <p class="blue"> wherever you want the 'blue' properties used within a <p> tag.
For example:

  • <p class="red">
  • <p class="blue">
  • <input class="red">
  • <input class="blue">
  • etc...

  • Choose properties for each class/element
  • Click 'add' only once for each one. Your code will be added to the text area at the bottom of the page
  • Click 'reset' between each class to reset the form and start again
  • When you've finished, choose whether you wish to have an external stylesheet created for you, or the code to paste into your individual pages
  • If you choose the external stylesheet, on the following page will be a download button. Change the name of the file to save from 'code.cgi' to 'style.css' and save it. Upload it to your website and use the link provided on the following page to use it on your webpages.
  • If you choose the internal stylesheet, copy and paste the generated code between the <head> </head> tags of each webpage you wish to use it on.

please choose...
     and/or * choose element and name together for element class
font properties
  font size:
  font weight:
  font style:
  font face:
  text decoration:
general properties
  background image: * path to image
  background attachment:
  background colour:
  horizontal align:
  vertical align:
  top margin: px
  bottom margin: px
  left margin: px
  right margin: px
table properties
  padding top: px
  padding bottom: px
  padding left: px
  padding right: px
  border width: px
  border colour:



Page opens in a new window

Site Stats     
Total: 9,768,786 Total: 28,332,419
Today: 235 Today: 600
Yesterday: 238 Yesterday: 618
Past Month: 7,378 Past Month: 19,158

272 visitors in the last 24 hours
This page has been visited 243,639 times
There is currently 1 visitor online
click to see where
most people online at once:
286 visitors on 06/27/2012
   You beaut

This site is © HTML Basix 2003 - 2009