HTML/CSS Service

How jQuery Works

Category: Learn jQuery    |    2,753 views    |    Add a Comment  |   

 

THE BASICS

This is a basic tutorial, designed to help you get started using jQuery. If you don’t have a test page setup yet, start by creating a new HTML page with the following contents:

 

<html>

 

  <head>
    <script type="text/javascript" src="jquery.js"></script>
    <script type="text/javascript">
      // Your code goes here
    </script>
  </head>
  <body>
    <a href="http://jquery.com/">jQuery</a>
  </body>
  </html>

Edit the src attribute in the script tag to point to your copy of jquery.js. For example, if jquery.js is in the same directory as your HTML file, you can use:

 <script type="text/javascript" src="jquery.js"></script>

You can download your own copy of jQuery from the Downloading jQuery page.

Launching Code on Document Ready

 

The first thing that most Javascript programmers end up doing is adding some code to their program, similar to this: Read more…

Share/Save/Bookmark

 

CSS Padding Tutorials

Category: CSS, CSS 2 Tutorial, CSS Tutorials    |    1,070 views    |    Add a Comment  |   

In this tutorial you will learn about Cascading Style Sheets (CSS) Padding,

The padding is the space between the element border and the element content from the four sides, the padding attributes enables you to increase or decrease this space; unlike spacing padding space values can’t be negative.

To declare the padding you can use the following properties:
padding-top, padding-right, padding-bottom, and/or padding-left.
The values of these properties can be an absolute length, a percentage.

Example:

table
{
padding-top: 5px;
padding -right:3px;
padding -bottom: 5px;
padding -left: 2px;
}

Read more…

Share/Save/Bookmark

 

CSS Margin Tutorials

Category: CSS, CSS Examples, CSS3 Tutorial    |    1,154 views    |    Add a Comment  |   

In this tutorial you will learn about Cascading Style Sheets (CSS) Margin and Using the shortcut.

The margin is the space around the element from the four sides, the margin attributes enables you to increase or decrease this space; the space can be a negative value, which may make elements overlap.

Using margins is very easy and straight forward, to declare the margin you can use the following properties:

margin-top, margin-right, margin-bottom, and/or margin-left.

The values of these properties can be an absolute length, a percentage.

Example:

.margins
{
margin-top: 5px;
margin-right:10px;
margin-bottom: 5px;
margin-left: 12px;
}

Read more…

Share/Save/Bookmark