[thelist] A Question of Relative Paths

VOLKAN ÖZÇELİK volkan.ozcelik at gmail.com
Mon Mar 14 10:08:31 CST 2005


Use base tag.

 <HEAD>
   <TITLE>Our Products</TITLE>
   <BASE href="http://www.aviary.com/products/intro.html">
 </HEAD>

...

 <BODY>
   <P>Have you seen our <A href="../cages/birds.gif">Bird Cages</A>?
 </BODY>
</HTML>

then the relative URI "../cages/birds.gif" would resolve to:

http://www.aviary.com/cages/birds.gif


For more info:

http://www.w3.org/TR/REC-html40/struct/links.html

HTH.
volkan.





On Mon, 14 Mar 2005 09:52:17 -0600, Casey Crookston
<casey at thecrookstons.com> wrote:
> I'm using a content editor tool to allow clients to update their own
> content.  It works pretty slick, except when it comes to images.  Here's the
> file and directory layout:
> 
> in the "inetpub/wwwroot/fubar_client" root directory:
> 
> > default.aspx
> > template.apsx
> > images (folder)
> > update (folder)
> >> update/text_editor.aspx
> >> update/conent (folder)
> >>>update/content/about.ascx
> >>>update/content/contact.ascx etc.
> 
> The file "template.aspx" calls content out of update/content based on the
> page the user has requested.  With the file "update/content/about.ascx" all
> of the image paths are simply <img src="images/a.jpg"> because, despite the
> file being located in the "update/content" folder, it is being called from
> the root folder.
> 
> The trouble is, when the same "update/content/about.ascx" file is being
> called from with the text editor at "update/text_editor.aspx" then the image
> path is no longer valid.  I'm struggling with how best to solve this
> problem.  I NEED the text_editor.aspx file to be in a separate folder so I
> can force a login. No matter where the "images" directory is located, the
> path will be different from the root directory and the update directory.
> 
> I seem to remember at some point hearing that it is possible to assign a
> root directory for relative file paths within the head of a file.  Is this
> true,, and if so, how?  Or is there some other way to solve this silly
> problem?
> 
> Thanks,
> 
> Casey
> 
> --
> 
> * * Please support the community that supports you.  * *
> http://evolt.org/help_support_evolt/
> 
> For unsubscribe and other options, including the Tip Harvester
> and archives of thelist go to: http://lists.evolt.org
> Workers of the Web, evolt !
>


More information about the thelist mailing list