How do you make a php file a download? - Printable Version -Shoutbox (https://shoutbox.menthix.net) +-- Forum: MsgHelp Archive (/forumdisplay.php?fid=58) +--- Forum: Skype & Technology (/forumdisplay.php?fid=9) +---- Forum: Tech Talk (/forumdisplay.php?fid=17) +----- Thread: How do you make a php file a download? (/showthread.php?tid=40676) How do you make a php file a download? by .Roy on 03-20-2005 at 10:34 AM Ok i have a site and i want people to download a php script. But if i link to it the people get bunch of gibberish. how do i get them to download the script? RE: How do you make a php file a download? by Ahmad on 03-20-2005 at 10:38 AM One option is to put it in a zip file. RE: How do you make a php file a download? by .Roy on 03-20-2005 at 10:42 AM hmm i dont want to go through that trouble. Its annoying to put a 1 kb zip. whats the other options? RE: How do you make a php file a download? by Millenium_edition on 03-20-2005 at 10:45 AM
quote:if that's trouble, then you shouldn't have a webspace on your hands ¬¬ RE: How do you make a php file a download? by John Anderton on 03-20-2005 at 11:22 AM
quote: Is your host a php supporting one quote:Its just a zip Rar it U could make it a txt and when ppl open it, tell em to copy the text completely, open notepad, paste it and then save it as .php (In the save as box, unselect the text file option and keep it on all files then type the extension yourself) RE: How do you make a php file a download? by segosa on 03-20-2005 at 11:39 AM You can save it as .phps (s = source) which shows them syntax-highlighted source code and the script isn't parsed.. RE: How do you make a php file a download? by -dt- on 03-20-2005 at 11:46 AM
quote:and if your server dosnt support that use a script like this code: which will take ?file=filename on the url then ask the user if they wish to download the file , this will only download files from the same directory the script is in. RE: How do you make a php file a download? by .Roy on 03-20-2005 at 01:10 PM
-dt- i dont really understand what you are saying RE: How do you make a php file a download? by -dt- on 03-20-2005 at 01:14 PM
step1: copy and paste my code into notepad and save it as "phpdl.php" RE: How do you make a php file a download? by .Roy on 03-20-2005 at 01:29 PM
well -dt- THANKS A BUNCH!!! |