You are here: Re: Local file reference « HTML « IT news, forums, messages
Re: Local file reference

Posted by David Dorward on 11/20/38 11:26

Edward wrote:

> I'm creating and testing basic web pages, and learning HTML.
> How do you refer an image source or a link to a local file.jpg for
> example?

Absolute URLs? Depends on the browser and OS. You're almost certainly best
off using relative URLs ...

http://www.iusmentis.com/technology/www/relativeurls/

.... , or installing a webserver on your workstation ...

http://httpd.apache.org/

> I've tried <img src="C:\image.jpg" align="center"/> without success.

Aside from the issues of how absolute URLs to local file systems are
handled, the "align" attribute is deprecated and should not be used, the
alt attribute (which you don't have) is required, and Appendix C of the
XHTML 1.0 spec requires a space before the "/" (although XHTML is not
usually a good idea and you would be better off sticking to HTML 4.01).

--
David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация