Help - Search - Members - Calendar
Full Version: Free File Upload Utility for posting images
OpenSourcePhoto > Show Your Stuff! > How to Upload...
Robert Watcher
To go along with what David has written here:

http://www.opensourcephoto.net/forum/index.php?showtopic=96

As an active forum user and wanting to have control of my images (on my server space), about 4 years ago I developed a very simple File Upload Utility for my own use that was linked to an permission set (CMOD 777) upload folder on my website. I placed a shortcut to the "FLU" upload page on my "Links" toolbar for easy access. It was very easy to click the link, upload the file and then use the url and file name to enter into the [img][/img] tags in my forum messages and replies.

. . . . . . About a year later, I ran a photographers forum on phpBB software that did not include file upload ability. I adapted the FLU script to create a hack that was included in the message area that allowed anyone to upload to my server and then paste in the address where the image file was located.

Since then a 3d animations friend of mine who has a work group of artists, made good use of my FLU script just for the simplicity of it. Improvements were made as he required other file types than Jpgs to be uploaded. I then included the extension type validation. Also I decided it would be much easier if the "full path" of the image was returned to me so that I would simply have to copy and paste it into forum posts.

I haven't really changed much on it until a major upgrade yesterday. Previously FLU required 3 pages (including a CMOD 777 text datafile to store file names) and needed manual customization of the location where files would be stored.

This new January 2007 FLU version is even simpler, slicker, and more adaptable. Drawing on the simplicity of my OnePageGallery, the new script is One Page only - and simply sits inside the folder where images will be stored. It auto recognizes the path and so one could have multiple storage folders by creating one and naming whatever you please and then placing a copy of the script inside the folder. The only thing that must be done (as will all folders or pages on a server that need to be modified), is right click on the Upload Folder (Directory) and CMOD it to 777. You will then be able to upload files from wherever you may be by entering the address to the script (for security reasons the script does not have to be called index.php - can be any name followed by .php extension).

While the previous version included a file renaming function so that there would not be conflicts with onther files of the same name - this new version does the same but is much more efficient in using a unique time stamp to generate the file name. I have also included an option of appending the real file name to the end of the generated file name, just in case that is valuable for file identication. Also the default radio button can be set at the top of the page so that the most commonly used tag option is readily available.

After the file is uploaded, the full path to the file is returned and made available at the bottom of fthe FLU page. Any formatting tags are included in the url. Just copy and paste it into it into your message.

IT'S FUN - - - IT'S EASY - - - IT'S VALUABLE




You can download the zipped file here:
FLU.zip Free Download

--

Your server must have PHP installed - - - most do.
-
Robert Watcher
-----------------------------------
-----------------------------------

Update a few hours later:

I had several emails from ones worried about security and while it shouldn't be a big problem - - - I have added a password login to this newer version. I will make both versions available for now. The personal "user" & "password" are entered in the PHP part of the script where it cannot be accessed by outsiders. You can personalize these by editing the index.php page. In this way I can stay with the one page concept instead of having to rely on a database connection. Also a variable for "display name" is provided so that it is not the user name that is displayed when logged in. Nothing Grand - but it works well:

You can download the Password Protected FLU zipped package here:
FLUPW.zip Free Download
Robert Watcher
I was made aware that the FLU page did not display properly in Firefox. I have fixed that this morning and the Download Link in the first message, downloads the current fixed version. If anyone is running Safari could you let me know if it displays properly in that browser - I'd appreciate the input.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.