Images not loading

admin

Administrator
Staff member
I have been working on a site and the images are not working<br />
<br />
Here is the code<br />
<br />
<html><br />
<head><br />
<title>using images</title><br />
</head><br />
<body><br />
<body background="http://materials.netskills.ac.uk/resources/38webimages/yellow.gif"><br />
<p><img scr="http://materials.netskills.ac.uk/resources/38webimages/spider.gif" alt="spider"/></p><br />
<p>A picture of a lovely web spider</p><br />
<p>DNA</p><br />
<p><img scr="dna.gif" alt="DNA" /></p><br />
</body><br />
</html><br />
<br />
if you check the url for the spider gif it is valid.<br />
<br />
I haven't published this file yet, but when I have a image file in the same directory as my html file it won't load either.<br />
<br />
Any idea.<br />
<br />
Thanks.<!--content-->You have misspelled "src" as "scr".<br />
You have <br />
<img scr="http://materials.netskills.ac.uk/resources/38webimages/spider.gif" alt="spider"/><br />
<br />
and<br />
<img scr="dna.gif" alt="DNA" /><br />
<br />
Also I've not seen before an ending slash like that in a tag. Maybe it doesn't need to be there...<!--content--><html><br />
<head><br />
<title>using images</title><br />
</head><br />
<body><br />
<body background="http://materials.netskills.ac.uk/resources/38webimages/yellow.gif"><br />
<p><img scr="http://materials.netskills.ac.uk/resources/38webimages/spider.gif" alt="spider"/></p><br />
<p>A picture of a lovely web spider</p><br />
<p>DNA</p><br />
<p><img scr="dna.gif" alt="DNA" /></p><br />
</body><br />
</html><br />
<br />
<br />
Run your code through <!-- m --><a class="postlink" href="http://validator.w3.org/detailed.html">http://validator.w3.org/detailed.html</a><!-- m --> for a list of errors, so you will get used to checking your code.<br />
<br />
<br />
You'll see above that you have two <body> tags. Only one is allowed.<br />
<br />
You also mistyped src as scr in two places.<br />
<br />
Use the validator to discover other problems.<br />
<br />
You also need to add a DOCTYPE and meta Content-Type to the code, and later on add a meta description for search engines to index too.<!--content-->Thank you, it works.<br />
<br />
Thanks.<!--content-->
 
Back
Top