Charisma Posted March 12, 2007 Share Posted March 12, 2007 Hi, I'm trying to find the realpath location of a folder on my Yahoo! server. I believe it can be achieved through a PHP script. Is that correct? If so, can anyone please help me with an example? Quote Link to comment https://forums.phpfreaks.com/topic/42381-realpath/ Share on other sites More sharing options...
SammyGunnz Posted March 12, 2007 Share Posted March 12, 2007 <?php $path = $_SERVER['SCRIPT_FILENAME']; echo $path; ?> Quote Link to comment https://forums.phpfreaks.com/topic/42381-realpath/#findComment-205585 Share on other sites More sharing options...
Charisma Posted March 13, 2007 Author Share Posted March 13, 2007 Thanks but heres the problem. I have a php configuration file, refering to a function that allows me to batch upload images from a folder on my server, into one of my databases: <?php # This defines the path where all your albums are stored # Put all your images into folders under this directory # then use the batch add files for adding the images into the # iGallery # *nix servers should be #define("images_path", "realpath here"); # Windows server should be #define("images_path", "realpath here"); ?> The folder containing the images is located at: www.surfstream.co.uk/gallery/images/test From advice, between the " " quotes, should start something like: /usr/www/html/...etc.. However, do I need to replace the www or html? Can anyone please show me the correct format Quote Link to comment https://forums.phpfreaks.com/topic/42381-realpath/#findComment-206360 Share on other sites More sharing options...
wildteen88 Posted March 13, 2007 Share Posted March 13, 2007 Try this: define("images_path", $_SERVER['DOCUMENT_ROOT'] . "/gallery/images"); Quote Link to comment https://forums.phpfreaks.com/topic/42381-realpath/#findComment-206466 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.