Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: PHP open download box  (Read 3204 times)

0 Members and 1 Guest are viewing this topic.

alecsillidan

    Topic Starter


    Beginner

    PHP open download box
    « on: December 01, 2009, 09:17:18 AM »
    Hi guys, I'm asking u what's the code to open a download box and download a file from my PC?
    I need the php code to use with wamp server, so when someone connects to <name>.zapto.org it will be redirected to my ip and download my modded counter strike 1.6 (it has more than 700 mb and cant upload on any site)
    so when someone connects it will open the file E:\CS16BlackOmega.rar
    can u pls help me? already got 60 ppl to download it but they wont download cause the down speed is 50-60kb/s :|
    I need it to work with wamp server (it needs index.php i think)
    Don't need any download buttons or titles or text...just download pls :D
    We never had to cheat 'cause we already won!

    kpac

    • Web moderator
    • Moderator


    • Hacker

    • kpac®
    • Thanked: 184
      • Yes
      • Yes
      • Yes
    • Certifications: List
    • Computer: Specs
    • Experience: Expert
    • OS: Windows 7
    Re: PHP open download box
    « Reply #1 on: December 01, 2009, 09:39:28 AM »
    Well people are still going to have to download it regardless of where you put it.

    What you want to do is basically set up your own home server which is not a good idea unless you know what you're doing.

    alecsillidan

      Topic Starter


      Beginner

      Re: PHP open download box
      « Reply #2 on: December 01, 2009, 09:43:02 AM »
      well i know what i'm doing (except the php part), i had many cool servers for wow and bf 2, 2142 modded by me so i know a bit.
      so can u help me tell me the code to make ppl download from me pls?
      i have the address and server, just need the php
      We never had to cheat 'cause we already won!

      kpac

      • Web moderator
      • Moderator


      • Hacker

      • kpac®
      • Thanked: 184
        • Yes
        • Yes
        • Yes
      • Certifications: List
      • Computer: Specs
      • Experience: Expert
      • OS: Windows 7
      Re: PHP open download box
      « Reply #3 on: December 01, 2009, 09:48:10 AM »
      You don't need PHP, although WAMP is built on it. You just need to configure the server properly to route all inbound requests for your IP to a particular folder inside the htdocs or www folder. Do a Google search for "set up home server using wamp".

      This opens a big security hole though, especially if you'll be posting the link on the WWW.

      alecsillidan

        Topic Starter


        Beginner

        Re: PHP open download box
        « Reply #4 on: December 01, 2009, 11:00:05 AM »
        doesn't work what i tried...
        The index.html:
        <html>
        <body>

        <form action="upload_file.php" method="post"
        enctype="multipart/form-data">
        <label for="file">Filename:</label>
        <input type="file" name="file" id="file" />


        <input type="submit" name="submit" value="Submit" />
        </form>

        </body>
        </html>

        And the upload_file.php:
        <?php
        $server = "188.26.182.155"
        if ($_FILES["E:\CS\cs.rar"]["error"] > 0)
          {
          echo "Error: " . $_FILES["E:\CS\cs.rar"]["error"] . "
        ";
          }
        else
          {
          echo "Upload: " . $_FILES["E:\CS\cs.rar"]["Black Omega"] . "
        ";
          echo "Type: " . $_FILES["E:\CS\cs.rar"]["Rar"] . "
        ";
          echo "Size: " . ($_FILES["E:\CS\cs.rar"]["806,519,514"] / 1024) . " Kb
        ";
          echo "Stored in: " . $_FILES["E:\CS\cs.rar"]["cs.rar"];
          }
        ?>

        What's wrong? I can open the index.html and see that but others that connect to the ip con't see anything!
        We never had to cheat 'cause we already won!