Re: file upload utility ?
| From: | Jim Lucas | Date: | Mon, 07 Feb 2011 16:26:15 +0000 |
| Subject: | Re: file upload utility ? | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-311183@lists.php.net to get a copy of this message | ||
On 2/7/2011 8:03 AM, Frank Bonnet wrote:
> On 02/07/2011 05:01 PM, Daniel Brown wrote:
>> On Mon, Feb 7, 2011 at 10:56, Frank Bonnet<f.bonnet@esiee.fr> wrote:
>>> Hello
>>>
>>> I'm searching for a utility that let our users upload a file
>>> on a server , then generate a temporary link that point
>>> to the real file.
>>>
>>> As this is for internal use we don't need security, the file
>>> can be read by anyone.
>>>
>>> The goal is to distribute the file to our users by sending
>>> them an email containing the address of the http temporary
>>> link instead of sending it as an email attachement X 1000 ...
>> Sounds great. Good luck in your Google search.
>>
> I found nothing that's why I wrote this !!!
>
>
>
Frank,
Not sure what words you used, here was mine
php file upload examples
Those words resulted in these two at the top of the list
http://www.tizag.com/phpT/fileupload.php
http://www.w3schools.com/PHP/php_file_upload.asp
I briefly read each of them and they are sufficient for what you are trying to
do. All you have to do is tie in the email portion and that's that.
So, again, to google, I typed these wonderful words of wisdom.
php email example
The first result was this
http://www.w3schools.com/PHP/php_mail.asp
This will get you a very simple email script working. Personally, I would not
do it this way, but since you mention that this will be all internal, it will
probably do just fine. If you want a little more control over the email or plan
to use this to send email to outside recipients, I would recommend doing it
differently.
phpmailer
Download that package, then follow its tutorials on how to set it up and send
emails.
phpmailer examples
The first result is this
http://phpmailer.worxware.com/index.php?pg=examples
It has a variety of examples that should cover almost any scenario you can
possibly think of.
Just one thing, do not try and be a cut/paste god here. Actually take time to
read the examples and understand what they do before you put them into production.
This will now end my "How to use Google" segment for the day.
Jim Lucas