Right here's the best way to permit customers to add pictures to a WordPress web site

Do you want users to be able to upload images to your WordPress site?

If you want to accept guest posts, product reviews, or a photo contest, you need to allow users to upload pictures. However, you may not want to give them access to your WordPress admin area.

In this article, we are going to show you how users can securely upload images to a WordPress site without giving them access to the WordPress administrator.

Users can securely upload images to WordPress

If you want to run a blog with multiple authors, the easiest way for users to upload images is to add them as an author on your website.

However, user access to the WordPress admin area isn't ideal for one-off scenarios like submitting guest posts, product reviews, photo contests, etc.

Fortunately, there are several WordPress plugins that allow users to upload images without compromising the security of your website or giving them access to the WordPress administration area.

However, let's take a look at a few ways that users can easily upload images to WordPress.

Method 1. Have users upload images using a file upload form

This method comes in handy when users just need to upload a picture or other file like resumes, cover letters, etc.

You can simply create a file upload form which will record the user's name, email address, photo / file itself and any messages they would like to include.

First you need to install and activate the WPForms plugin. For more information, see our step-by-step guide on installing a WordPress plugin.

WPForms is the best WordPress Form Builder plugin used by over 4 million websites. It comes with a file upload box that we will use in this tutorial.

After activation you have to visit the WPForms »Settings Page in your WordPress dashboard to enter your license key. You can find your license key in your account area on the WPForms website under the Downloads tab.

Here's what it looks like when you type it into your website:

Enter your license key for WPForms

Now go to WPForms »Add new to create your form. In this example we are using the "Simple Contact Form". Click on it and your new form will appear.

The simple standard contact form with fields for name, email and message

Then, drag and drop a file upload box onto your form. You can find this field on the left in the "Failed Fields" section.

Add a field to upload files to the form

Once added, click the File Upload field on your form to edit it.

We will change the name of this field (its label) to "Your Photo" and indicate what file extensions are allowed. We only want image files so we will allow JPG / JPEG, GIF and PNG files.

Note: By default, WordPress only allows certain types of files to be uploaded. For example, users cannot upload SVG images or ZIP files unless you explicitly add them to the Allow List. We'll explain how to do this in a moment.

First, let's tweak our field settings further. We recommend specifying a maximum file size of 5MB and checking the box next to "Required" so that the user cannot submit the form until they have uploaded an image.

The file size limitation helps you save hard drive costs in your WordPress hosting account.

Edit the field to upload files. The label says now

You can also set additional options for this field by clicking the down arrow next to Advanced Options.

Here you can choose the style of your upload field. A "modern" drag and drop field is used by default. If you want, you can replace it with a "Classic" field, which instead looks like this:

Switch to the field

You can also save the image in the WordPress media library by checking this box. This is a good idea if you want to put your submitted images together for a blog post or something similar.

Once you are happy with your form, you can save the form creator and exit.

Adding your image upload form in WordPress

Next, you want to add your form to a WordPress post or site. WPForms makes it easy to add your forms anywhere on your website.

Just edit the post or page you want to add the image upload form on. In the WordPress content editor, you need to add the WPForms block to your content area.

Add a WPForms block to your page

After that you need to select the form you created earlier from the drop down menu. WPForms shows a preview of your form in the content area.

You can now save your post or page and view it live to see your image upload form in action.

Allow additional file types to be uploaded

Sometimes your users will see this error when uploading a file, even if you have allowed that file type in the settings of your upload box:

Unfortunately, this file type is not permitted for security reasons

The problem is that WordPress only allows certain file types by default. The easiest way to allow more file types is to use a companion plugin.

We recommend the "File Upload Types" plugin from WPForms.

Once you've installed and activated the plugin in WordPress, go to Settings »File Upload Types.

You can then choose file types from the list that you want to allow, or you can add custom file types.

Whitelisting of additional file types in WordPress
Note that the list does not include the types that WordPress already allows by default.

Method 2. Allow users to upload pictures as guest authors

A major reason users can upload images is to collect guest posts. You can also use a very similar method for other user-generated content, such as: B. Testimonials.

First you need to install and activate the WPForms plugin. For more information, see our step-by-step guide on installing a WordPress plugin.

Note: You need the Pro version (or higher) to use the "Post Submissions" add-on.

After activating the plugin you need to visit that WPForms »Settings Page in your WordPress dashboard to enter your license key. You can find your license key under the Downloads tab of your account on the WPForms website.

Here's what you'll see when you enter the license key on your website:

Enter your license key for WPForms

Next go to WPForms »Addons to install the Post Submission Addon. Click the "Install Addon" button. It will be installed and activated automatically

Install the WPForms add-on for post-submissions

You are now ready to start creating your guest contribution form.

Go to WPForms »Add newThen scroll down to find the blog post submission form.

Create a blog post submission form

Click on it and your new form will be created for you. Here you will find standard fields for the guest author's details as well as the suggested title, content, selected image, contribution excerpt and the category of the contribution.

You can add more fields (sections of your form) if you want. For example, you might want to add a "Website / URL" field where the author can enter the URL of their own blog.

Adding a website / url field

To change the labeling of a field or any text in the form, simply click on it.

For example, you can click the Selected Image box and change the Description to indicate your preferred size for featured images.

Edit the field

Files uploaded via the preset "Selected Image" field are saved in your media library in WordPress.

You can toggle this option on and off by clicking the Advanced Options drop-down list for the field.

Choose whether to save uploaded images in the media library

Tip: If you want to create a form from scratch, note that the File Upload box does not save any files to the media library by default. Make sure to enable this setting if you want to use it.

If you want, you can change the types of images accepted in the File Upload field. For example, you may want users to upload PNG files only.

You can also enter a maximum file size in MB. If you want, you can allow users to upload two or more files.

Change the settings for uploading files

The "Modern" upload field (default setting) allows users to drag and drop files. If you want, you can change it to a "Classic" field under Advanced Options. Note that users can only upload a single file.

Switch to classic upload

When you have all of the fields you want on your form, switch to the Settings tab. You may want to change details under "Notifications" here.

For example, if your guest posts are being sent to an editor, you would want their address in the "Send to email address" field.

Change the settings of your form

You may also want to change the confirmation message a user sees after submitting the form. You can do this below Settings »Confirmation.

When you're happy with your form, click the "Save" button at the top of the screen.

Add the guest post form to your website

You can add your form in any post or page on your website. You may want to create a new page specifically for guest posting.

If you are using the Gutenberg Editor (Block Editor), just click the (+) icon to create a new block. Then, under the Widgets section, select WPForms.

Adding a form to your page with the block editor (Gutenberg)

Next, you'll see a WPForms drop-down list. Select your form from the list and it will be added to your post.

Tip: If you're still using the classic editor, you'll see an Add Form button next to Add Media instead. Click here for a drop-down list of your forms. Select the one you want and click "Add Form" to include it in your post.

You can of course use the "File Upload" field in any form you have created. That means you can use the method outlined above for any type of user-generated content you want to collect.

Method 3. Allow users to upload photos for a contest

A file upload form allows users to upload any type of file. However, this may not be the best solution if you are running a photo contest.

This is because WPForms is a form builder, not a competition plugin. Features such as selecting winners, sharing viruses, etc. are not included.

This is where RafflePress comes in. It's the best WordPress giveaway plugin that allows you to create viral contests to increase your traffic and social media followers.

You can use it to design a contest widget that allows users to upload photos, but it can also be used to incentivize sharing and other engagement activities to grow your following.

Submit a picture action

We have created a detailed guide on how to create a photo contest in WordPress with RafflePress that you can follow for more details.

We hope this article has helped you learn how users can upload images to a WordPress site. You might also want to see our comparison of the best email marketing services and push notification software to connect with your visitors after they leave your website.

If you enjoyed this article, please subscribe to our YouTube channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

Comments are closed.