Menu

DOCUMENT_ROOT

Help
2007-11-25
2013-04-29
  • Nobody/Anonymous

    Hello !

    Thanks for this great tracker :)

    I replace  $_SERVER["DOCUMENT_ROOT"]  by  realpath ("../")  in "bta_configuration.php" and "bta_add.php"

    I make a "torrents" folder in http://mysite/tracker/

    And in "config.php" :
              $GLOBALS["allow_torrent_move"] = true;
              $GLOBALS["torrent_folder"] = "torrents";

    Else, with DOCUMENT_ROOT, I have /home/torrents. too bad...

    And now, I can send my torrents :)

    Tell me if this can help you or others...

     
    • Nobody/Anonymous

      I replace the line :

      $url = "http://" . $_SERVER["HTTP_HOST"] . "/" . $GLOBALS["torrent_folder"] . "/" . $copyFilename;

      With this one :

      $url = "http://" . $_SERVER["HTTP_HOST"] . "/" . "tracker/" . $GLOBALS["torrent_folder"] . "/" . $copyFilename;

      Now, I have correct links in the statistics page.

       
    • Nobody/Anonymous

      By default, i don't have rights access to download the torrent file directly by the statistics page.
      So, I add this in "bta_add.php" just after the line -> $copiedTorrent = true; :

      $ftp_server='server';
      $conn_id = ftp_connect("$ftp_server");
      ftp_login($conn_id, login, password);
      ftp_chmod($conn_id, 0644, 'path/to/torrentsdir'. '/' . $copyFilename);
      ftp_close($conn_id);

      Just replace :
      server by the ftp server address
      login and password by your ftp login and password
      path/to/torrentsdir by the path to the torrents ftp dir.

      I hope this help...

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.