classifieds100 Posted April 19, 2006 Share Posted April 19, 2006 Hi,I have a script in which I need to get these two values automatically:# full root path to directory (ie: /www/data/docs/user.com/public) $this->directory_root = ".";# http path to directory (ie: [a href=\"http://user.com/public)\" target=\"_blank\"]http://user.com/public)[/a] (no trailing slash) # Note: this must be a directory path you cannot use [a href=\"http://user.com/public/sitemap.php\" target=\"_blank\"]http://user.com/public/sitemap.php[/a] $this->homepage = ".";I have try to replace the first $this->directory_root = "."; with:$this->directory_root = "$_SERVER['DOCUMENT_ROOT'] . dirname(__FILE__)";But I'm sure I get it wrong somehow. And the second part I also can't get it to work either.See more here:############################## CONFIGURATIONS ################################# # html page on/off toggle writing of html header and footer $this->html = "on"; # width of <table> $this->table_width = "100%"; # on/off $this->debug = "off"; /* turn off/on display of working path. not recommened to leave on during public use. */ # full root path to directory (ie: /www/data/docs/user.com/public) $this->directory_root = "."; # http path to directory (ie: [a href=\"http://user.com/public)\" target=\"_blank\"]http://user.com/public)[/a] (no trailing slash) # Note: this must be a directory path you cannot use [a href=\"http://user.com/public/sitemap.php\" target=\"_blank\"]http://user.com/public/sitemap.php[/a] $this->homepage = "."; # http path to images $this->img_src = "/images"; # alternating row color; $this->alt_color = "on"; /* on/off */ $this->alt_color_one = "#f6f6f6"; $this->alt_color_two = "#c0c0c0"; # show directories first on/off $this->order = "on"; # blacklist file names and directories so they will not show $this->blacklist = Array(".", "..",.... rest of the code goes here....Please can someone help me to get right these values$this->directory_root = ".";$this->homepage = ".";automatically from the server?Thanks for your help in advance Quote Link to comment 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.