Simple PHP doubt

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
jayjones01
Forum Newbie
Posts: 2
Joined: Sat Dec 11, 2010 12:16 pm

Simple PHP doubt

Post by jayjones01 »

I'm making a php script (im not that familiar with php) to download a lot of files from a server i have (to check the connection/server behaviour with a heavy workload). When i request a download, does the php script remain active till the download finishes ? or does it request the download and then ends ? I'm asking this because i want to record how long did the files take to download, and if the script ends before the files are transfered, how could i accomplish this?

Thanks in advance
User avatar
s.dot
Tranquility In Moderation
Posts: 5001
Joined: Sun Feb 06, 2005 7:18 pm
Location: Indiana

Re: Simple PHP doubt

Post by s.dot »

Unless you are forking the process, php is a linear language and the script execution will not end until the file is downloaded.
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
jayjones01
Forum Newbie
Posts: 2
Joined: Sat Dec 11, 2010 12:16 pm

Re: Simple PHP doubt

Post by jayjones01 »

Thanks a lot, that's all i needed to know :D
User avatar
s.dot
Tranquility In Moderation
Posts: 5001
Joined: Sun Feb 06, 2005 7:18 pm
Location: Indiana

Re: Simple PHP doubt

Post by s.dot »

For curiosity, how are you doing the download?
Set Search Time - A google chrome extension. When you search only results from the past year (or set time period) are displayed. Helps tremendously when using new technologies to avoid outdated results.
Post Reply