5

I want to allow my users to upload files in admin panel, but I'm not sure where should I upload these files and how the script should look like?

<p>Please provide link to a file or click "Upload" to upload it from your PC:</p>
<form>
Link: <input type="text" name ="logo_url">
Upload: <input type="file" name="logo_file">
<input type="Submit" value="Upload">

How should back-end look for that script? I mean the type="file" part :)

Oh and of course I have fully working theme option page (so the first input works like a charm).

1

2 Answers 2

1

See this very similar question. The answer can be adjusted to work with all types of files, not just images.

-2

If you use the Contact Form 7 plugin your visitors can upload an attachment to a file that sends you an email with the file as an attachment.

1
  • 4
    Sorry, I don't use Contact Form, and I'm looking for an answer not connected to any plugin, I just want to understand the concept and then write my own php script. Thanks anyway. Jan 19, 2011 at 12:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.