CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Recognizing document type to create thumbnail

Print topic Send  topic

Author Message
Shnokey

Posts: 7
Posted: 09/29/2004, 5:44 AM

I have created a libray and an up-load page for MySQL and PHP. I currently have an area on the upload page to check a radio button to choose what type of document it is (.DOC, PDF) and that in turn places small icon next to the document link in the library. (just basically selects an image from the database) Now the end user can identify the document type by looking at the little icon. How can I have the up-load application look at the extension of the up-loaded document, and if the extension = .PDF - then place "pdf.gif " into the image area? - this way I dont have to have the library admin click on the document type. And the process would be much more professional.

Thanks for you help -

Jon
View profile  Send private message
hidran

Posts: 29
Posted: 09/29/2004, 6:21 AM

You can use $_FILES[ 'file_variable_name']['type'] to detect the uploaded
file type
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.