Related: see here
I've got this command:
exec("(wget -O http://domain/file.zip && mysql -u user -ppassword database -e \"UPDATE \\`table\\` SET \\`status\\` = 'live' WHERE \\`id\\` = '1234'\") & echo \$!");
The above command works fine, however PHP waits for the video to finish downloading before going on to the next download. The following line, however, sends the download to the background, which is what I'm trying to achieve from the previous line.
exec("wget -O http://domain/file.zip &>/dev/null & echo \$!");
How do I go about changing the first line above to send the download to the background?