html - why won't my image show? -


my image saved in same folder tree or whatever called webpage, , won't load. it's simple can't figure out. hint appreciated.

    <!doctype html public "-//w3c//dtd html     4.01//en" "http://www.w3.org/tr/html4/strict.dtd">     <html>     <head>     <meta content="text/html; charset=iso-8859-1"     http-equiv="content-type">     <title>website</title>     <style type="text/css" media="screen, print, projection">      body{          background-image:url('c:\users\blah\desktop\webdesign\randompicture.png');     }       </style>      </head>     <body>     </body>     </html> 

try using relative paths, if picture in same directory html file, write:

background-image: url(randompicture.png); 

also, don't need apostrophes in url() notation of css.

if put rules separate css file, path should relative css file, not html.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -