going back a directory to retrieve image?

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
Patriot
Forum Commoner
Posts: 34
Joined: Tue Jun 18, 2002 1:36 pm

going back a directory to retrieve image?

Post by Patriot »

how do you do this in php?
like if you want to include a file in previous directory.
pretend your file is in /tutorials and you want to include the file in the root, how would you? i can't move it, because the file is a pollbooth, and needs alot of others
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

Code: Select all

include '../thisfile.php';
Put as many ../ as you have folders to go back.

Mac
Post Reply