Wednesday, June 3, 2020

How to Create a File Upload Form in WordPress

Do you need to have your website visitors upload files on your contact form?

Maybe you’re hiring employees and want to collect resumes, or perhaps you’re running another application form or photography contest where you need the applicant to attach files.

In this tutorial, we’ll show you how to create a file upload form in WordPress (step by step).

How to create a file upload form in WordPress

Why Create a File Upload Form in WordPress?

If you want to collect any kind of file from your users, then a file upload form is a great idea. You could let users upload images, PDF files, Word documents, or other types of files.

Using a file upload form makes life easy for you, and your users.

Instead of the email back-and-forth, you can create a form that include all the fields you need, so you can collect all information at once.

Also, your form should automatically save the form data in your WordPress database. That way, you can easily find the submissions, even if you miss or delete an email.

How to Create a File Upload Form in WordPress

For this tutorial, we’ll be using WPForms, which is the best contact form plugin for WordPress.

If you’re on a tight budget, you can get the file upload feature on WPForms’ Basic plan. However, the fully-featured Pro plan gives you access to bonus form templates, survey reports, and tons of other powerful features.

First, you’ll need to install and activate the WPForms plugin. If you’re not sure how, just check out our step by step guide on how to install a WordPress plugin.

Once you’ve activated the plugin, you’ll see a new WPForms tab in your dashboard.

Go to the WPForms » Addons page and scroll down to the Form Templates Pack Addon. Click on the ‘Install Addon’ button to install and activate it.

Installing the WPForms form template pack addon

You are now ready to create your first file upload form.

Head over to the WPForms » Add New page.

Creating a new form using WPForms

You’ll be taken straight to the WPForms builder. You can give your form a name at the top of the screen:

Giving your form a name in WPForms

You’ll also need to choose a template. We recommend using the File Upload Template, which you can find in the Additional Templates section. Click on the template to use it.

The File Upload Form will automatically be created for you.

The default file upload form, created from the template

You can use the file upload form without making any changes at all, if you want.

By default, it’ll allow users to upload the following file types:

  • Images files: .png, .gif, .jpg
  • Documents: .doc, .xls, .ppt, .pdf
  • Audio: .wav, .mp3, .mp4
  • Video: .mpg, .mov, .wmv

If you’d like to restrict the file types further, click on the File Upload field to edit it. You’ll see the Field Options on the left hand side of your screen:

Editing the file upload field in WPForms

In the Allowed File Extensions box, you can type in whatever file formats you want to accept. We’re going to allow the image formats .png, .gif, and .jpg. Make sure you separate them with a comma.

Enter the file types that you want to allow users to upload

Note: WordPress limits the types of files that can be uploaded to the site for WordPress security reasons. You can add additional file types to WordPress if you want to allow users to upload file types that aren’t normally allowed.

You can also set a maximum file size and a maximum number of files. For our competition, we’re going to allow people to submit up to 3 photos of up to 50MB each.

If you want to prevent people from submitting the form without attaching their file(s), you can check the Required box. This means the form can’t be submitted unless at least 1 file has been uploaded.

The edited file upload field on our form

By default, the File Upload Field uses a modern format that lets users drag and drop their files. However, if you have limited space for your form, or you prefer a classic upload field, you can change this.

Simply click on ‘Advanced Options’ to open up more options for the field. You can then switch the style from Modern to Classic using the dropdown.

Editing the advanced options for the file upload field

Tip: The classic upload field only allows one file to be uploaded. If you want users to be able to submit more than one file, you’ll need to add more than one File Upload Field to your form.

You can also choose to store the submitted files in the WordPress Media Library, if you want. This makes it easy for you to add them to a post or page. For instance, with our photography competition, we might include the best photos when we announce the winner.

Note: The uploaded files are still saved in your WordPress database, even if you don’t check this box. They’re just stored in a separate folder in your WordPress hosting account.

If you want to edit any of the other fields on your form, you can click to edit them on the left hand side in the same way.

You can also add new fields using the Add Fields tab. Simply drag and drop any field that you want to add to your form.

Here, we’ve added a Website/URL field to the form, so that photographers can give us the link to their website.

Adding a website / URL field to the form

If you want to remove a field, hover your mouse cursor over it and click the red trash can icon. We’re going to remove the Phone field as we don’t need the photographers’ phone numbers.

Deleting the phone field from the form

Once you’re happy with your form, click the Save button at the top of the screen.

Click the Save button in WPForms

Setting Up Your File Upload Form’s Notifications

Under the Settings tab, you can click Notifications to set up your form’s email notifications. You may want to change the default settings.

By default, the form sends an email notification to {admin_email}.

If you created your WordPress site by yourself, then this will be your email address. If not, then you can delete {admin_email} and type your own email address here instead.

Changing the email address that the form notifications are sent to

Tip: Not sure if {admin_email} is your email address or not? Go to Settings » General in your WordPress dashboard. Look for the Administration Email Address. You can change it here. Just click Save Changes at the bottom after doing so.

Checking or changing the WordPress Administration email address

If you want the submitted files to be sent to more than one person, you can also set up multiple notifications here.

You may also want to change the confirmation message that users sees after the form is submitted. You can do this under Settings » Confirmations.

Simply type the message you want into the box. You can add formatting like bold and italic if you want to. This is how the default message looks:

Changing the confirmation message that the user sees after submitting the form

Don’t forget to save your form once you’ve made changes. You can exit the form builder by clicking the X in the top right.

Adding Your File Upload Form to Your Website

Once you’ve created your form, you’ll need to add it to your website. You can add it on an existing post or page, or you can create a new page.

We’re going to add our form to a new page. To create a new page, go to Pages » Add New. Then, add a new block to your page by clicking the (+) icon.

Creating a new page in WordPress and adding a new block to it

Next, you’ll need to select the WPForms block from the Widgets section. You can use the search bar to find it if you prefer.

Adding the WPForms block to your page or post

After you’ve added the block to your page, select the form that you created from the WPForms dropdown.

Select the correct form from the WPForms dropdown

Now, preview or publish your page and take a look at your form live on your site. Here’s how our form looks.

The finished file upload form live on the website

You can make changes to your form by going to WPForms » All Forms. Just click on the name of the form, or run your mouse over it and click the ‘Edit’ link, to edit it.

Editing a form you've already created in WPFormsv

When you edit your form, it’s automatically updated on your website. You don’t need to add it to your page again.

Tip: It’s a good idea to test your form to make sure it’s working as expected. If you don’t get an email notification after creating a form entry, then take a look at our step by step guide on fixing the WordPress not sending email issue.

Viewing or Downloading the Uploaded Files

When someone sends a file through your file upload form, you can get it through your email inbox or through your WordPress dashboard.

With each form entry, you’ll get an email like this:

The email you receive with the form entry details, including file download links

Just click the links to view or download the files themselves.

You can also easily find the files through WordPress itself. Go to WPForms » Entries then click on the name of your form.

Select your form to view the form entries in your WordPress dashboard

Next, you can see the uploaded files in the table of form entries. Alternatively, you can click the View link to see the full details of the form entry.

The file links shown in the WPForms entry in the table

We hope this tutorial helped you learn how to create a file upload form in WordPress. You might also want to check out our guide on the best WordPress survey plugins and our guide on how to create an email newsletter.

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

The post How to Create a File Upload Form in WordPress appeared first on WPBeginner.


June 03, 2020 at 04:30PM

Tuesday, June 2, 2020

How to Create Smart Coupons in WooCommerce

Several of our readers have asked us how to create smart coupons in WooCommerce to extend the default functionality.

If you want to go beyond the built-in WooCommerce coupons to add items like buy one get one coupon, free gift coupon, etc, then you’re in the right place.

In this article, we’ll cover how to create smart coupons in WooCommerce.

How to create smart coupons in WooCommerce

What You Can Do With Smart Coupons for WooCommerce

Smart coupons (or advanced coupons) are a great way to increase your sales and revenue.

Instead of simply giving your customers a blanket discount on everything in their WooCommerce cart, you can use smart coupons to do all sorts of clever things.

For instance, you can create a “buy one get one” coupon that lets customers buy one product and get another free. This can be a great way to boost sales, or even to clear out stock that you want to move faster.

You could even create a free gift coupon. This could be a great way to build your email list, reward loyal customers, and encourage people to try a new product.

You may think that creating these types of coupons for your online store would be complicated and require technical knowledge. The good news is that it’s really straightforward.

We’re going to show you how to create smart coupons using the Advanced Coupons plugin for WooCommerce.

Create Smart Coupons with Advanced Coupons Plugin

Advanced Coupons is the best WordPress coupon code plugin on the market. It allows you to create smart coupons to boost your sales and grow your business.

First, you’ll need to install and activate the Advanced Coupons plugin. For more details, see our step by step guide on how to install a WordPress plugin.

Once you’ve done that, you’ll find the new coupon functionality under WooCommerce » Coupons page in your WordPress admin dashboard.

To create any kind of coupon, you start by clicking ‘Add New’ and then enter your chosen coupon code at the top of the screen.

Entering a code for your free gift coupon - we've used 'freeshirt' for ours

There are loads of different ways you can create smart coupons. In this article, we’re going to take you through some of the most popular and effective ways to use coupons on your WooCommerce store.

You can jump straight to each one using these quick links:

Creating a Buy One Get One Free Coupon in WooCommerce

Advanced Coupons lets you create all sorts of “buy one get one” (BOGO) coupons. You don’t necessarily have to give away something for free. You could instead have a “buy one get one half-price” offer.

A BOGO coupon could be a great way to encourage people on your email list to make their first purchase. It can also be a great way to encourage repeat purchase from existing buyers.

To create a BOGO coupon using Advanced Coupons, go to WooCommerce » Coupons and add a new coupon. Click on the BOGO tab and set the conditions for your deal.

Add coupon for your BOGO deal

You can create lots of different types of offers, including “buy two get one” or similar. The item that the customer gains doesn’t have to be free. Instead, you could discount it by any percentage you want.

Here, we’ve created an offer where customers can buy any t-shirt and get a green t-shirt for free.

A buy one get one free coupon

Tip: BOGO coupons are most effective when you’re offering a free item that’s related to the one people are buying. For instance, if you sell winter clothing, you might offer a free pair of gloves with every hat purchased.

If you want more help creating your BOGO coupon, check out our full tutorial on how to create buy one get one coupons in WooCommerce.

Creating a URL Coupon (Auto-Apply) in WooCommerce

When you send out an email newsletter or social media post with a coupon code, sometimes users don’t know how to apply the coupon code.

This leads to increase in cart abandonment. Wouldn’t it be nice if you could auto-apply the coupon code with a click of a link?

This is where WooCommerce coupon URLs come in handy.

Instead of needing to remember a code, customers can simply click on a special URL. When they do so, Advanced Coupons will automatically apply the correct coupon to their cart.

This is really useful for social media marketing, where you might be limited in how many characters you can include in a status. Being able to give the coupon code within your store’s URL saves space.

To create a URL coupon using Advanced coupons, go to WooCommerce » Coupons and add a new coupon. Set the discount under the General tab.

You’ll need to publish the coupon in order to get the URL. After that, go to the URL Coupons tab, and you’ll see the coupon URL here.

It’ll be yoursite.com/coupon/couponcode, where couponcode is whatever you entered for your coupon code.

Creating a URL that automatically adds the coupon to the customer's cart

You can customize the coupon’s URL if you want, using the Code URL Override box. This will change the end of the URL (the coupon code part).

If you want more help creating your URL coupon, check out our full tutorial on how to create URL coupons in WooCommerce.

Creating a Pre-Scheduled Coupon in WooCommerce

Planning a holiday or special sales promotion?

If you run a lot of sales during the year, scheduling coupons ahead of time can make it easier. For instance, you could set up a bunch of coupons in January for your spring sale, your summer sale, and your Black Friday deals.

Scheduling coupons can also help you improve your marketing communications with affiliate partners because you can share the coupon code with them ahead of time without worrying about it being used live.

To schedule a coupon, you simply create it in the normal way by going to WooCommerce » Coupons and clicking ‘Add New’.

Next, click on the Scheduler tab and enter a start and end date for your coupon.

Note: The coupon will begin at 12:00:00 am on the start date and end at 11:59:59 pm on the day before the end date.

Using the scheduler in Advanced Coupons

You can also edit the default messages here, if you want to. These will be shown if the customer tries to use the coupon before it’s valid or after it expires.

If you want more help creating your scheduled coupon, check out our tutorial on how to schedule a coupon in WooCommerce.

Creating a Free Gift Coupon in WooCommerce

Do you want to offer your customers a free gift? You don’t need to set a product’s price to $0 to do this. There’s a better way, by using a free gift coupon.

Free gift coupons let customers add a product to their cart for free. You can set them up so that customers have to spend a certain amount in order for the coupon to work.

This is a great way to increase average order value on your online store.

For instance, you might create a coupon, so that customers who spend $20 or more can get a free mini teddy bear. If they haven’t got $20 worth of items in their cart, they can’t use the coupon.

You could also offer a free gift without any minimum spend. This could be a great way to reward loyal customers, or to get first-time customers to give your store a try.

To create a free gift coupon, go to WooCommerce » Coupons and add a new coupon.

Next, click the Add Products tab, find the product you want to giveaway, and select ‘$: Override price’ from the Price/Discount dropdown. You can leave the box blank or enter 0.

Making your product free using the 'Price/Discount' dropdown

If you want more help creating your free gift coupon, check out our tutorial on how to create a free gift coupon in WooCommerce.

How to Promote Your Coupons in WooCommerce

Whatever type of coupon you’ve created, you’ll want to let your customers know about it.

Unless it’s an offer specifically for your email list or newsletter, it’s best practice to promote the coupon across your website.

The easiest way to do this is with OptinMonster. It’s a powerful conversion optimization tool that helps you turn casual website visitors into paying customers.

You can use it to create a coupon popup on your site like this:

BOGO coupon popup

For full instructions, just check out our tutorial on how to create a coupon popup in WordPress.

You can also use OptinMonster to display your coupons in lots of other ways such as a floating notification bar like this:

OptinMonster floating coupon bar

And even a gamified spin a wheel coupon where you can allow users to win different discounts.

Spin a Wheel - Gamified Welcome Mat

Final Thoughts and Best Practices

Smart coupons are a brilliant way to drive more sales and make more money from your store.

It’s a good idea to experiment with different types of coupon to see which works best with your audience.

This will help you consistently tweak and improve your results.

We hope this article helped you learn how to create smart coupons in WooCommerce. You might also like our ultimate guide to WooCommerce SEO and our step by step guide on how to set up conversion tracking in WooCommerce.

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

The post How to Create Smart Coupons in WooCommerce appeared first on WPBeginner.


June 02, 2020 at 05:00PM

Monday, June 1, 2020

How to Send SMS Messages to Your WordPress Users

Recently, one of our readers asked if it was possible to send SMS messages to their subscribers along with email newsletters.

The answer is yes. You can easily send text messages to your website users by using one of the many SMS plugins for WordPress.

In this article, we’ll show you how to send SMS messages to your WordPress users, step by step.

Sending SMS messages to your website's users

Why Send SMS Messages to Your Users?

Sending SMS messages can be highly effective in bringing back customers to your website. Particularly, when used with other marketing tools like an email newsletter, push notifications, and search traffic.

Text messages have a fantastic open rate. Some studies suggest that SMS open rates are as high as 98%.

Compare that with a typical open rate of just 20% for emails, and you can see why SMS messages are becoming a preferred marketing medium.

People check text messages much more quickly than they check emails. It takes an average of 90 seconds for someone to respond to a text and 90 minutes to respond to an email.

Of course, you don’t want to overdo it. Even when they’ve opted in, most users won’t want daily texts from you. Even weekly might be too much.

Important: Make sure you obey the law. Different countries have different legal requirements for text messages, particularly marketing messages.

You might also want to use SMS messages to send receipts or order updates. We’ll cover how to do that later in this tutorial.

Sending SMS Marketing Messages Using Sendinblue

Sendinblue is an email marketing service that also allows you to send SMS messages to your subscribers.

To get started, you’ll need to set up an account with Sendinblue if you haven’t already got one. On the Sendinblue website, click the ‘Sign up free’ button to start creating your account.

Once you’ve finished the account setup process, you’ll see your Sendinblue dashboard. If you didn’t complete your profile during the setup stage, you’ll be prompted to do so here.

Complete your Sendinblue profile

Before you can start sending messages, you’ll need to contact the support team. Go to the Sendinblue contact page and write a message that includes:

  • A request to activate your account.
  • Your site’s URL.
  • A note that you’ll be sending marketing messages.

Once your account has been approved, you’ll get an email from Sendinblue. Note that this can take up to 24 hours.

Buying SMS Credits for Your Sendinblue Account

While you’re waiting for your account to be approved, you can start creating an SMS campaign in Sendinblue.

First, click the + button in the Sendinblue menu to go to the Apps and Integrations page.

The Sendinblue Apps and Integrations page

Then, scroll down the page to find the SMS Campaigns app and click the slider to activate it.

Switching on SMS campaigns in Sendinblue

Next, you’ll need to purchase SMS credits. In your Sendinblue dashboard, you’ll see ‘0 SMS Credits’ on the left-hand side. You need to click the ‘Get more credits’ link to purchase SMS credits.

Click the 'Get More Credits' link

You’ll be taken to the ‘My Plan’ area of the dashboard. In the SMS Credits section, click the ‘Get More SMS Credits’ link.

Click to Get More SMS Credits

Sendinblue defaults to selling you 100 credits at a time. You can buy fewer, but the minimum charge is still $1.14 plus tax.

Choose how many credits you want to buy

Note: It costs 1 credit to send a text message in the US, but you’ll need to pay more than 1 credit per message in other countries.

Once you have selected the number of credits, go ahead and complete your purchase.

Pay for your SMS credits

Once you’ve bought your credits, you may need to wait for up to 48 hours for them to appear in your account. You may also get an email from Sendinblue asking you for more details about what type of SMS marketing you plan to do.

This is to help you stay in compliance with SMS laws.

You’ll need to reply to them with answers to their questions before your credits can be added to your account.

Creating Your SMS Marketing List

In order to send out SMS messages, you’ll need to import your list. You can do this by going to the Contacts tab in your Sendinblue dashboard. Then, click the ‘Import contacts’ button.

You can either upload a .csv file from your computer, or you can copy and paste contacts line by line. Whichever option you choose, Sendinblue offers examples to help you.

Sendinblue's import options for your contacts list

Important: Your users need to have opted in for SMS marketing messages.

You can collect website visitor’s phone numbers and consent using a WordPress form plugin like WPForms, or using a marketing popup plugin like OptinMonster.

Sending Your First SMS Campaign

Once your credits show up and your account is approved, you can start sending messages.

First, you’ll want to add a test contact in Sendinblue, so you can test your SMS campaign.

Simply, go to the Contacts section in your dashboard, then click the ‘Add a contact’ button.

Adding a contact in Sendinblue

Next, fill in your details, including your mobile phone number.

Enter your own details to create a sample contact

After that, you can either add your test contact to an existing list, or you can create a new one.

Add your sample contact to a list

Once you’ve done that, click ‘Save and close’. You should see a message telling you that the subscriber has been successfully added.

When your SMS credits have been added to your account, you can test out sending a text message.

First, go to the SMS tab in your Sendinblue dashboard. Next, click the ‘Create my first SMS campaign’ button.

Create your first SMS campaign

You can enter whatever you want for your Campaign Name. This isn’t seen by the recipients. You should also enter an SMS Sender. This will display for users in certain countries.

Entering a name and a sender for your SMS campaign

Next, enter your SMS message. Beneath the message box, you can see how many characters you’ve used and how many SMS messages will be sent.

Entering the text for your SMS message

At the bottom of the screen, click the ‘Send a test’ button.

Send a test SMS message

Next, a popup box will appear. Enter your mobile number, which you included when you added yourself as a contact earlier.

Enter your mobile number

You should see a message telling you that your test message has been sent successfully.

Confirmation that the test SMS message was successfully sent

Now, check your phone to see if the text has come through. Here’s ours:

The text message campaign shown on a mobile phone

If your text hasn’t arrived, wait a minute or two and it should appear. If not, double-check that you’re using the right mobile number.

Once you know everything’s working, you can continue setting up your campaign. Click the X to close the ‘Send a test’ window, then click the ‘Next Step’ button on the top right of the screen.

Moving to the next step of the SMS campaign

Now, you’ll need to choose your contact list(s). Check all the lists you want to use, then click the ‘Next Step’ button.

Choosing the contact list for your SMS campaign

That’s all you need to do! Your SMS campaign is now ready to send.

You can review the details and change them if you want to, using the ‘Return to this step’ links. Once you’re happy, click ‘Schedule’ on the top right.

Reviewing your SMS campaign before sending

You can either schedule your campaign so that your texts are sent out at a specific time, or you can send it immediately.

Send or schedule your SMS campaign

Important: Avoid sending your text messages early in the morning or late at night. Be mindful of timezones, too. Not everyone will remember to turn on Do Not Disturb mode overnight.

Sending SMS Messages to Your WooCommerce Customers

What if you want to send your customers notifications about their orders?

If you’ve decided to start an online store, then you might want to send text updates as well as emails to your customers.

The easiest way to do that is with a suitable plugin such as YITH WooCommerce SMS Notifications. This plugin lets you use an SMS gateway, such as Twilio, to send SMS messages to your customers. They receive these when their order status changes, such as when it’s dispatched.

You can set up YITH WooCommerce SMS Notifications so that it’s enabled for all customers, or you can let customers opt-in at the checkout.

Also, you can use it to get SMS notifications yourself about new orders. This makes it easy to stay on top of things if you’re away from your computer.

We hope this tutorial helped you learn how to send SMS messages to your WordPress users. You may also want to see our list of best business phone services for small business, and our list of the best live chat software to grow your sales.

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

The post How to Send SMS Messages to Your WordPress Users appeared first on WPBeginner.


June 01, 2020 at 05:00PM