Re: [PHP] Click....download and update
The Content-Type header changes, when uploading, you can get it from $HTTP_POST_FILES['userfile']['type'], also set the filename using header("Content-Disposition: attachment; filename='. $filename ); Christian Ista wrote: >>You'll need to prompt the download by sending the appropriate headers. >>Something like.. >> >>http://www.mydomain.com/downloadmyfile.php>Download >> >>>header("Content-Type: application/zip"); >>header("Content-Disposition: attachment"); >>readfile("file.zip"); >>?> >> >> > >It's not only .zip file but may be .exe or .rar > >That's change something in your code ? > >I can put the code to update a database field in the downloadmyfile.php >? > > >Bye > > > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Click....download and update
> You'll need to prompt the download by sending the appropriate headers. > Something like.. > > http://www.mydomain.com/downloadmyfile.php>Download > > header("Content-Type: application/zip"); > header("Content-Disposition: attachment"); > readfile("file.zip"); > ?> It's not only .zip file but may be .exe or .rar That's change something in your code ? I can put the code to update a database field in the downloadmyfile.php ? Bye -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Click....download and update
Christian, You'll need to prompt the download by sending the appropriate headers. Something like.. http://www.mydomain.com/downloadmyfile.php>Download This is untested but from my experience it should work. Good luck, Kevin - Original Message - From: "Christian Ista" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, September 19, 2002 1:21 PM Subject: [PHP] Clickdownload and update > Hello, > > I'd like when I click on a link http://www.website.com/file.zip> > update a table and start the download without change the page. > > Could you tell me how to do ? > > Christian, > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Click....download and update
Hello, I'd like when I click on a link http://www.website.com/file.zip> update a table and start the download without change the page. Could you tell me how to do ? Christian, -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php