Re: [PHP] Finding the depth

2001-03-16 Thread Christian Reiniger
On Thursday 15 March 2001 16:51, you wrote: ok, this is what you asked for ?php function depth() { global $PHP_SELF; $count = count_chars($PHP_SELF); for($c = 0; $c $count[ord('/')]; $c++) $return[] = ".."; if (isset($return)) return implode('/', $return); }

Re: [PHP] Finding the depth

2001-03-16 Thread Christian Reiniger
On Friday 16 March 2001 06:04, you wrote: Hi, Chris Lee wrote: ok, this is what you asked for snip/ Thanks! I haven't tried it, but I am sure it will work. but why cant you just do this. echo " img src='/image/back.gif' "; I don't want to do that because that sort

[PHP] Finding the depth

2001-03-15 Thread Harshdeep S Jawanda
Hi all, To explain my problem, I'll have to draw a directory structure (please bear with me :-): web-server-document-root | +--dir:common-pics | +--dir:sub-dir1 || |+--dir:sub-sub-dir1 | +--dir:sub-dir2 | +--dir:sub-sub-dir2

Re: [PHP] Finding the depth

2001-03-15 Thread Harshdeep S Jawanda
Hi, Chris Lee wrote: ok, this is what you asked for snip/ Thanks! I haven't tried it, but I am sure it will work. but why cant you just do this. echo " img src='/image/back.gif' "; I don't want to do that because that sort of link will work only when this page is served up