How to Put a Border Around My Web Page

How to Put a Border Around My Web Page thumbnail
Create a border with a simple code.

CSS, or cascading style sheets, is the most common way to create a border around your website. You can customize almost every aspect of the border with a simple code added after the body tag in your HTML file. Even amateur web designers can add a custom, colorful border around a website.

Instructions

    • 1

      Open your website's HTML file in Notepad. Make sure that your HTML document has <body> </body> tags at the beginning and end of the document.

    • 2

      Add this code after the <body> tag:

      <style type="text/css">

      body {border: 10px solid #000000;}

      </style>

    • 3

      Modify the code to suit your preferences. Change the color of the border by finding the six-digit hexadecimal code for the color and inserting it after the "#" sign. Find the hexadecimal code for a color by using an online chart; see Resources. Alternatively, open an image-editing program and choose the color you want. Copy and paste the six-digit number beside the color into your HTML.

    • 4

      Change border attributes by replacing "solid" with "dash," or adjust the thickness of the border by changing the number in front of "px."

Related Searches:

Resources

  • Photo Credit Jupiterimages/Comstock/Getty Images

Comments

You May Also Like

Related Ads

Featured