Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
Old 02-12-2009, 06:17 AM CSS questions please
Super Talker

Posts: 132
Trades: 0
I am having trouble with the CSS tutorials, first question, can anyone put this is simple words please or what's the purpose of a Selector?

Selectors

Any HTML element is a possible CSS1 selector. The selector is simply the element that is linked to a particular style. For example, the selector in
P { text-indent: 3em } is P.
mikehende is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 02-12-2009, 06:59 AM Re: CSS questions please
rogem002's Avatar
PHP Chap

Posts: 843
Name: Mike
Location: United Kingdom
Trades: 0
They let you add style to tags such as
<p></p>
and
<img></img>
__________________
My Blog/Site:
Please login or register to view this content. Registration is FREE
rogem002 is offline
Reply With Quote
View Public Profile Visit rogem002's homepage!
 
Old 02-12-2009, 08:04 AM Re: CSS questions please
Super Talker

Posts: 132
Trades: 0
Thanks, I am ready to start trying out CSS, I opended Notepad and placed this code and save the doc as "church.css":

Quote:
<html>

<head>
<link rel="stylesheet" type="text/css" href="page.css">
</head>

<body bgcolor="white" text="blue">

<h1> This is My first page </h1>

This is my first web page and I can say anything I want in here - I do that by putting text

or images in the body section - where I'm typing right now Smile

<img src="jesus.jpg" width="150" height="150" alt="Image of Jesus">

span {
font-variant:small-caps;
}

</body>

</html>
I have the index.church file with the code:

Quote:
<html>
<body>

<h1>My First Heading</h1>

<p>My first paragraph.</p>

<img src="/jesus.jpg" />

index

</body>
</html>
What do I do next to view the webpage with the new css code please?
mikehende is offline
Reply With Quote
View Public Profile
 
Old 02-12-2009, 10:57 AM Re: CSS questions please
Super Talker

Posts: 132
Trades: 0
ok, I am totally confused now, I deleted the css file from from BOTH Apache's htdocs folder and the c:websites/church folder and it now shows in localhost but since there's no css file then why is this index.html code working?

<html>

<head>
<link rel="stylesheet" type="text/css" href="page.css">
</head>

<body bgcolor="white" text="blue">

<h1> This is My first page </h1>

This is my first web page and I can say anything I want in here - I do that by putting text

or images in the body section - where I'm typing right now Smile

<img src="jesus.jpg" width="150" height="150" alt="Image of Jesus">

span {
font-variant:small-caps;
}

</body>

</html>
mikehende is offline
Reply With Quote
View Public Profile
 
Old 02-12-2009, 12:05 PM Re: CSS questions please
racer x's Avatar
Ultra Talker

Posts: 457
Name: Randy
Location: Northern Wisconsin
Trades: 0
You'll want to visit http://www.w3schools.com/ to get a grasp on html and css and how they work together, etc. Don't be overwhelmed by the many categories w3schools has of languages to learn, just focus on html and css for now.

There's quite a bit of explaining to do here based on what you have above.

Good luck!
racer x is offline
Reply With Quote
View Public Profile Visit racer x's homepage!
 
Old 02-12-2009, 12:38 PM Re: CSS questions please
Super Talker

Posts: 132
Trades: 0
I have been over the css and html tutorials a FEW times and my main problem is how to insert a style sheet? If someone could instruct me on this, would be great as I can try the editing of the page via css myself. Let me start from scratch in a step by step manner and simply tell me [anyone] where I am going wrong and how to correct it please?

I have placed the css insert code:

Quote:
<head>
<link rel="stylesheet" type="text/css"
href="mystyle.css" />
</head>
in the index.html document where it should be placed,
between the head elements so the index file is now:

Quote:
<html>

<head>

<link rel="stylesheet" type="text/css" href="page.css">

</head>

<body bgcolor="white" text="blue">



<h1> This is My first page </h1>



This is my first web page and I can say anything I want in here - I do that by putting text



or images in the body section - where I'm typing right now Smile



<img src="jesus.jpg" width="150" height="150" alt="Image of Jesus">


</body>
I now want to add this simple css style to the page:


Quote:
body {color: black}
What do I do next?
mikehende is offline
Reply With Quote
View Public Profile
 
Old 02-12-2009, 03:37 PM Re: CSS questions please
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
You REALLY should read our stickies:
http://www.webmaster-talk.com/css-fo...he-basics.html
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 02-13-2009, 07:03 AM Re: CSS questions please
Super Talker

Posts: 132
Trades: 0
I've read your stickies and everyone else's, while they do help a lot they are almost exclusively generalized and not personalized, for example, I got the answered I needed last night on another forum, this simply how I would write the tutorial for "linking stylesheets to html"

Step:
1] Any style definitions should be placed in the external stylesheet and any html code should be placed in your html file.

2] Open your text editor such as Notepad, create your index file with your html code and save it as index.html.

3] Open your text editor and place only the css code into it and save the document as whatever you wish to name it but with the extension .css

4] Place the css doc into the same folder as the index file.


So easy! I do realize that most folks just may not have the time to create "step by step" tuts in the same fashion above, the point I am trying to make is that this is the only method which works FOR ME personall and is why I ask the questions that I do, hope you all understand, thanks for the help as always guys, it is much appreciated, now on to more css experimenting and please look out for more questions, thanks.
mikehende is offline
Reply With Quote
View Public Profile
 
Old 02-16-2009, 10:42 AM Re: CSS questions please
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
Unfortunately, your posts were not all that clear. You asked for an explanation of selectors - you were given that in several forms. How you insert a link to a stylesheet was correct in the code you posted.

As for the body{color:black} - one it's not necessary, as the default text color IS black. However, you would just add that selector to your CSS file, it doesn't matter where, though it would be helpful organizationally to put it at the top of your CSS file.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 02-16-2009, 11:01 AM Re: CSS questions please
Super Talker

Posts: 132
Trades: 0
Agreed, my posts could be better organized, just that I don't wish to create new threads for each particular issue so as not to flood the site therefore all questions I should ask for all CSS issues, I wish to keep in in one thread unless you mods say otherwise?
mikehende is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to CSS questions please
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.41941 seconds with 12 queries