Jump to content

Photo

HTML Problem


  • Please log in to reply
2 replies to this topic

#1
Shmoo97

Shmoo97

    Member

  • Member
  • 79 posts
when i use the following lines it looks like the CSS isn't working (btw it's outline CSS)
Html link ->
<link rel="StyleSheet" href="style.css" type="text/css"/>

CSS lines ->
body
{
list-style-type : none;
background-image : url(D :\Thomas\AE 4.0\MY AE 4.0»Background.JPG);
}

between d & : in the background url the space shouldnt be there but otherwide it gives :angry:

Edited by Yuxi, 27 September 2011 - 06:46 PM.
Code tags added - please use this feature in the future when posting code snippets.

RedBird , CEO of Red Bird Airlines


#2
Conor

Conor

    Angry Irishman

  • AE Moderator
  • 1,404 posts

when i use the following lines it looks like the CSS isn't working (btw it's outline CSS)
Html link ->

<link rel="StyleSheet" href="style.css" type="text/css"/>

CSS lines ->
body
{
list-style-type : none;
background-image : url(D :\Thomas\AE 4.0\MY AE 4.0»Background.JPG);
}

between d & : in the background url the space shouldnt be there but otherwide it gives :angry:



Firstly it is always better to use lowercase letters. To link your stylesheet to the .html instead of:
<link rel="StyleSheet" href="style.css" type="text/css"/>

use:


<link rel ="stylesheet" href="whatever_your_path_name_is" />


Secondly in your "background-image" the slashes are the wrong way. Also you dont need to specify the disk drive. Assuming your .html file is in "MY AE 4.0" the path name try just:
background-image: url(MY AE 4.0/background.jpg);

Im not really to sure but I dont think path names can include spaces so if they cant put %20 instead, but i dont think this is right. Someone else should be able to help you if you cant get it to work.
background-image: url(MY%20AE%204.0/background.jpg);


#3
Shmoo97

Shmoo97

    Member

  • Member
  • 79 posts
problem is solved now conor :)

RedBird , CEO of Red Bird Airlines





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users