Jump to content

Shorten Source Directory


Hazukiy

Recommended Posts

Hi, I have a question that's bugging me really badly, I want to make it so that when I have a <img> tag, the source of that image is shortened to look something like this...

<img src="../../image.jpg" alt="picture_1" />

But when I do this, it doesn't work. I've tried many methods and different combination but it doesn't seem to work, so I figured that It must be some kind of option in the apache .htaccess file?

 

Help would be much appreciated, thanks.

Link to comment
https://forums.phpfreaks.com/topic/279344-shorten-source-directory/
Share on other sites

Skips? It ../ goes back up the directory tree one directory from where it is called. ../../ goes back up 2 etc etc

 

So, all this (../../image.jpg) says is go back up two directories (relative to the current url) and find the file image.jpg

 

If you have used any kind of computer from a terminal this type of thing becomes second nature. If you haven't (and your a programmer) do so.

  On 6/19/2013 at 12:58 PM, trq said:

Skips? It ../ goes back up the directory tree one directory from where it is called. ../../ goes back up 2 etc etc

 

So, all this (../../image.jpg) says is go back up two directories (relative to the current url) and find the file image.jpg

 

If you have used any kind of computer from a terminal this type of thing becomes second nature. If you haven't (and your a programmer) do so.

 

Ah ok thanks.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.