Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Regular Coder najkiie's Avatar
    Join Date
    Oct 2008
    Location
    Sweden
    Posts
    103
    Thanks
    7
    Thanked 0 Times in 0 Posts

    Question I need some small help with CSS id's/classes... its not working :(

    Hey, i just started making a new website... Its going pretty smootly so far but i need some help.

    First off, for all those ppl who have small screens (like 17" or smaller) the webpage will cover the whole page (with no vertical scrollbars...)... but its not doing it correctly... at the left side it has some free space, how do i get rid of it? its the same thing at the top of the page, how do i remove it? I used a big table and i have all my div's and stuff inside there... couse i can't center div's. Right?

    Check this out!
    http://img227.imageshack.us/img227/4...enshot1cu1.png


    Second problem, when you go to my website http://www.blubbz.com/website/ you can see two text lines. The first one is a link, and the second one is empty. The link is green, how can i style it with css to have another color? Ive seen ppl using something like

    #whatever {
    background-color: gray;
    color: white;
    }

    #whatever a:link, whatever {
    }

    (im not using that css, its just an example.)

    Im not sure if its coded right, but it should make the links look like the normal text... right? I also wan't the "visited" links to look like the normal text...

    And also, if its possible, could i make a link of the whole div tag instead of making a link of the text? It looks better if they can hover over the div and press it...?


    Plz help, thanks
    (im really really tierd right now so im sorry for my english.)

  • #2
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,675
    Thanks
    22
    Thanked 1,827 Times in 1,811 Posts
    Hello najkiie,
    The table is really not needed - you can center a div, usually with margins one way or another.


    Start on your links with something like this:
    Code:
    #whatever a:link, #whatever a:visited, #whatever a:active {
    			font-size: 1em;
    			color: #FFFFFF;
    			text-decoration: none;
    		}
    		#whatever a:hover {
    			text-decoration: underline;
    		}
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad

  • #3
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,675
    Thanks
    22
    Thanked 1,827 Times in 1,811 Posts
    Try this for a start, see if that works a little better.
    (you'll need to change the path to your images)
    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Blubbz - Home</title>
    <style type="text/css">
    body {
    	background: #000000 url(images/stripe_bg_red.jpg) repeat-x;
    	font: 12px Arial, Helvetica, sans-serif;
    	color: #b2b2b2;
    }
    * {
    	margin: 0;
    	padding: 0;
    	border: none;
    }
    #wrap {
    	width: 980px;
    	margin: 20px auto; /**positions wrap 20px down and centers it**/
    }
    #header {
    	background: url(images/header_red.gif);
    	height: 89px;
    	border: 1px solid #FFF;
    }
    </style>
    </head>
    <body>
    <div id="wrap">
    	<div id="header">
        </div>
    <!--end wrap--></div>
    </body>
    </html>
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •