homepage Welcome to WebmasterWorld Guest from 54.167.173.250
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Visit PubCon.com
Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

    
PhP to upload images
BoneHeadicus




msg:1303680
 1:50 am on Mar 16, 2001 (gmt 0)

I just need a simple way for clients to upload an image and write a sentence or two underneath it. I have scoured HotScripts and resourceindex and gotten close but no cigar.

Any body got a script like this?

 

sugarkane




msg:1303681
 9:57 pm on Mar 19, 2001 (gmt 0)

I've not got one to hand, but when you call a php script from an upload form [cgi-lib.berkeley.edu], php creates a variable using the name you gave to your <input type="file"> field.

This variable contains the path to the uploaded file - from there it'd be a pretty simple matter to move the file to somewhere more permanent and reference it from HTML.

jamesbond




msg:1303682
 11:14 pm on Mar 19, 2001 (gmt 0)

[gemini1consulting.com...]

I used this simple uploadform in an admin section for a travelsite I developed, it works and is easy to modify to your own needs.

It should work if you set the directory to have write permission (and php is not running in safe mode)

Hope this helps!

BoneHeadicus




msg:1303683
 4:44 pm on Mar 20, 2001 (gmt 0)

Thanks guys.

I must be in "ForRest Gump" mode again. Will have to wait for the brain juice to flow again but at least now I have something to jump right into.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved