VideoHelp Forum




+ Reply to Thread
Results 1 to 3 of 3
  1. I'm a Super Moderator johns0's Avatar
    Join Date
    Jun 2002
    Location
    canada
    Search Comp PM
    Hi,i just got my own domain and in trying to put a counter on my site using a cgi script and i need to know how to get the full path name of my files on my server,the script requires a path name like "$imagefile{'0'}="/home/yourdomain/counter/0.gif".
    I think,therefore i am a hamster.
    Quote Quote  
  2. Member
    Join Date
    Jun 2002
    Location
    MO, US
    Search Comp PM
    Log in with command-line ftp and type "pwd".
    A man without a woman is like a statue without pigeons.
    Quote Quote  
  3. I'm a Super Moderator johns0's Avatar
    Join Date
    Jun 2002
    Location
    canada
    Search Comp PM
    Tried that but only gave me "/",need the absolute path,thanks for the help.I got this script from my shaw server,can anbody run it to see if it works for them,i get errors trying and shaw cant help.
    The absolute path (the directory path with reference to the server’s root directory) for your webspace can be determined by printing the $0 (dollar sign, zero) variable from within a script. The following script prints the $0 variable:
    #!/usr/local/bin/perl
    print "$0";
    The string returned by the script will look like this:


    /01/23/mydomain.com/cgi-bin/nameofscript.pl
    Therefore, the absolute path to the webspace for this domain is /01/23/mydomain.com/.
    I think,therefore i am a hamster.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!