Unstoppable Domains

External CSS Script Problem -HELP!

Spaceship Spaceship
Watch

briguy

Guru In Remission!Top Member
Impact
60,909
Hey..I sure need some coding help..
Here is my problem, I been building html/css sites with the css style script as part of the coding. Since I wanted to make the CSS script external (so I change edit it all from one spot)
Anyway..here is the original page
http://1m1.info/EasyFruitWineRecipe.html

All I did was copy the stylescript directly
and put it as a "style.css" in my directory

This is what I get
(linked removed)


this is the script


PHP:
<style type='text/css'>

.wrapper{
   margin: 0px auto;

   width: 782px;
   background-color: rgb(93, 168, 248)
}
.header{
   float: left;
   width: 100%;
   height: 100%;
   background-color: rgb(246, 248, 94)
}
.content{
   float: left;
   width: 100%;
   height: 100%;
   background-color: rgb(246, 248, 94)
}
.footer{
   float: left;
   width: 100%;   height: 100px;
   background-color: rgb(246, 248, 94)
}
body {
   padding: 0px;
  margin: 0px;
   font-size: 90%;
   background-color: rgb(0, 0, 204)
}

</style>
What am I missing? How do I make the new site (second link) look the first?
Thanks in advance
 
Last edited:
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
Unstoppable DomainsUnstoppable Domains
Just the basics

Save your external CSS to file as FileName.css.
Insert that file in any directory that the server for page can directly access. You don't need <style type='text/css'> and </style> tags in this file.
You do need those in the head section if styles are in same file as page markup. You can have multiple style sheets/css files with different urls.

Insert the following in head section of every page that will reference FileName.css.

<link rel="stylesheet" type="text/css" href="http://Domain.ext/DirectoryPath/FileName.css" />

Reccommended reading - http://www.w3schools.com/css/css_howto.asp
 
Last edited:
1
•••
You linked it properly. Take the <style> tags out of the stylesheet (first and last lines) - that's html markup, not CSS and it's breaking the stylesheet.

:).
 
Last edited:
1
•••
Thanks Weber for the link!
Thanks enlytend, for pointing out the html coding!
 
0
•••
<style> tag is not required in external css file.
You have to give the link and reference in HTML head tag and then use it.

<link rel="stylesheet" type="text/css" href="reference of the required page" />

And also, you are missing semi-colon at the end of background-color property in css file " background-color: rgb(93, 168, 248) ; " in each.
 
1
•••
Dynadot — .com Registration $8.99Dynadot — .com Registration $8.99
Appraise.net

We're social

Unstoppable Domains
Domain Recover
DomainEasy — Live Options
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back