Wednesday, May 11, 2022

How to Sell Digital Downloads on WordPress (Beginner’s Guide)

Do you want to easily sell digital downloads online?

Maybe you’re planning to sell ebooks, online courses, your own photography, digital art, music, or something else.

No matter the type of digital product, WordPress makes it easy to sell these premium downloads and deliver them to your customers in a secure way. 

In this article, we will show you how to sell digital downloads on WordPress.

How to sell digital downloads the easy way (Beginner's guide)

Which Platform Should You Use to Sell Digital Products?

First, you’ll need to choose an eCommerce platform that you’ll use to sell digital products.

Digital downloads are basically products that users can download to their computers after making a purchase. Products like eBooks, digital art, images, illustrations, printables, software, music, and videos are a few examples of the most commonly sold digital products online.

An eCommerce platform is a software that allows you to upload your digital files and offer them for sale.

You’ll want to choose your eCommerce platform carefully. That’s because moving platforms can be complicated and take a lot of time and effort.

Some platforms are better suited for selling physical goods vs digital ones. You want to be sure that you’re choosing a solution that has features to protect your digital downloads, have proper licensing, subscriptions, and other key features built-in.

We recommend using WordPress + Easy Digital Downloads.

Easy Digital Downloads

WordPress is the best website builder on the market used by over 43% of all websites on the internet. Easily Digital Downloads is the best WordPress eCommerce plugin to sell digital products.

In fact, we use this plugin ourselves to sell many of our premium WordPress plugins which are downloadable files restricted for members only, and it comes with license keys built-in.

WordPress has a huge advantage over other platforms like Gumroad, Sellfy, or Sendowl. It gives you full control over your website, and you can sell as many products as you want without paying a high monthly or transaction fees.

Now, it’s important to know that there are two types of WordPress software, and you don’t want to choose the wrong one.

First, there is WordPress.com, which is a blog hosting platform. Then, there is WordPress.org which is also known as self-hosted WordPress.

For a detailed comparison, you can see our guide on the difference between WordPress.com and WordPress.org.

You need to use the self-hosted WordPress.org platform because it gives you full control over your website with complete freedom to sell any type of digital products.

We’ll show you how to easily setup your WordPress site with Easy Digital Downloads with just a few steps.

Step 1. Setting Up Your WordPress Website

To start selling digital downloads with WordPress, you’ll need a domain name, web hosting, and an SSL certificate

A domain name is your website’s address on the internet. This is what visitors will type into their browsers to reach your website, such as wpbeginner.com.

Web hosting is where your website lives online. You can think of hosting as your website’s house on the internet. To help you out, we’ve hand-picked some of the best WordPress hosting that you can buy. 

One of our top recommended hosting provider, SiteGround, offers managed WordPress hosting for Easy Digital Downloads. It comes with a free SSL certificate, EDD pre-installed, all the optimization features, and you get a huge 73% off.

Basically, you can create and run your website for less than $5 per month.

Let’s go ahead and walk through how to purchase your domain, web hosting, and SSL certificate.  

Go ahead and open the SiteGround website in a new tab so you can follow along here. The first thing you need to do is click on the Get Plan button.

SiteGround Managed EDD Hosting

After that, SiteGround will ask you to enter a domain name for your website. 

If you don’t already have a name in mind, then you can see our guide on how to choose the best domain name.

Lastly, you will need to add your account information. You will also be able to purchase some optional extras. 

You can always add these extras at a later date if you decide that you need them. If you’re unsure then we recommend skipping this step. 

After entering your payment details, SiteGround will send you an email with instructions on how to log into hosting account. This is a web hosting control panel where you can manage your new website. 

Simply log into your SiteGround account, and you’ll see that SiteGround has already installed WordPress for you, and it comes with Easy Digital Downloads (pre-installed as well).

SiteGroud Login to WordPress

You can then click on the ‘WordPress Admin’ button.

This will take you to your WordPress site’s dashboard where you’ll see Easy Digital Downloads pre-installed.

If for some reason, you don’t want to use SiteGround, then you can also install WordPress on other hosting companies like Bluehost, Hostinger, and WP Engine following a fairly similar process.

Step 2. Setting Up Easy Digital Downloads

By default WordPress doesn’t include an eCommerce functionalityout of the box, and that’s why you’ll need a plugin in order to sell your digital downloads.

Plugins for WordPress sites are like apps for your phone. They add all kinds of different features and functionality to your website.

Note: For this tutorial, we’ll be using the free version of Easy Digital Downloads. There’s also a premium version with more advanced features such as powerful email marketing service tools, additional payment gateways, email support, and much more.

Now if you used SiteGround, then Easy Digital Downloads comes pre-installed. But if you’re using other hosting provider, then you’d to manually install the Easy Digital Downloads plugin.

First, you need to install and activate the Easy Digital Downloads plugin. For more details, see our step by step guide on how to install a WordPress plugin.

Upon activation, you need to visit Downloads » Settings page in your WordPress admin area.

From here, first you need to set your store’s location.

You might wonder, why is your location needed if you’re not selling physical products? It’s because when a customer makes a purchase, Easy Digital Downloads will use the country and state information to auto-fill some fields. Also, your location may be used to calculate sales tax.

To add your location, open the ‘Base Country’ dropdown menu. You can now choose the location where your business is based.

Selling digital products with EDD

Next, find the ‘Base State / Province’ field. Here you can type the base state or province where your store operates from. 

After entering this information, scroll to the bottom of the screen and click on the Save Changes button.

Step 3. Setting up Your Payment Gateway 

If you want to sell downloads, then you’ll need a way to process payments from your customers.

Easy Digital Downloads supports PayPal, Stripe, and Amazon Payments. These are all popular payment gateways.

If you want to add more payment gateways, then you may want to take a look at the Easy Digital Download extensions which includes other solutions like Braintree, Authorize.net, and many more.

To choose your payment gateways, click on the Payments tab. Then make sure the Gateways tab is selected. 

Set up payment gateways

In the Payment Gateways section, select all of the gateways that you want to use on your new WordPress website.

The most common payment gateways are Stripe and PayPal, so we’ll show you how to set those up.

If you’re using multiple payment providers, then you’ll need to choose a default payment gateway. This is the option that will be selected automatically when the visitor loads your checkout page.

We recommend setting Stripe as the default since most people want to pay with credit cards.

Easy Digital Downloads' payment gateways

Now scroll to the bottom of this page and click on Save Changes. 

Once the page reloads, it will have some new tabs. You can use these tabs to configure your chosen payment gateways.

Easy Digital Downloads' default payment gateways

If you want to use PayPal, then click on the PayPal tab. You can now type your PayPal email address and password. 

To set up Stripe, click on the Stripe tab. Then click on the ‘Connect with Stripe’ button.

Connecting WordPress to your Stripe account

This opens a setup wizard, which will help you connect your website to Stripe.

Now, depending on your location, you may also want to customize the currency used on your website.

By default Easy Digital Downloads shows all of your prices in US dollars. It also places the dollar sign in front of the price, so five dollars is shown as ‘$5.’

To change the default currency settings, scroll to the top of the screen and click on the Currency tab.

The Easy Digital Downloads currency settings

Next, open the Currency dropdown. You can now choose a new currency. 

Just be aware that some payment gateways may not accept every currency. If you’re unsure, then it’s a good idea to check the website for your chosen payment gateway. Most payment gateways have a list of the currencies that they support. 

If you’ve made any changes on this page, then don’t forget to click on the Save Changes button.

Step 4. Creating Your First Digital Product

Now that your WordPress site is set up, you’re ready to start selling your digital goods!

To create your first digital product, go to Downloads » Add New

You can now type a name for your product into the ‘Enter download name here’ field. 

Adding a new digital download product

Next, type out a description for this product. WordPress will show this description to your visitors, so you’ll want to make sure it’s descriptive and convincing.

Many online stores and websites use product categories and tags. This can help shoppers find the product they’re looking for and can also encourage them to explore related products. 

You can create categories and tags in the Download Categories and Download Tags sections. 

Creating categories and tags for your digital downloads

After that, scroll to the Download Prices section. 

By default Easy Digital Downloads will offer your product as a free download. If you’re going to sell your digital downloads, then you’ll want to set a price. 

To add a price, scroll to the Download Prices section. You can then type the amount that visitors will need to pay in order to download this product.

Setting a price for your digital downloads

The next step is uploading your product. This might be an ebook, a recorded webinar, a PDF guide, photograph, or any other file that WordPress supports.

Pro Tip: If you want to sell a file type that WordPress doesn’t support, such as SVG images, PSD files, or others, then see our guide on how to allow additional file types in WordPress.

To add your downloadable file, simply scroll to the Download Files section. 

How to create a digital download

In the File Name field, type a name for your downloadable file. Then you can click on the ‘Upload a file’ button.

This will launch the WordPress media library. Here you can choose the file you want to offer for download.

The final step is adding a product image. 

When you’re selling digital downloads, you may need to get creative with your product images. For example, if you’re selling a recorded webinar, then you might use a screenshot from the video. 

You can easily create a professional-looking product image using web design software such as Canva.

To add a product image, you just need to scroll to the Download Image section.

Adding a product image

You can then click on the ‘Set Download Image’ link. This launches the WordPress media library where you can choose your product image. 

When you’re happy with the information you’ve entered, click on the Publish button. 

Your first digital product is live! You can now preview your product page in action.

Product preview

You can now create more digital downloads simply by repeating these steps.

Step 5. Selecting and Customizing Your WordPress Theme

Themes control how your WordPress website looks to the people when they visit it, including the layout, colors, and fonts.

There are thousands of WordPress themes, so it can be hard to decide which one to start with. You can check out our pick of the most popular WordPress themes for some great options.

Once you’ve chosen a theme, you can see our beginner’s guide on how to install a WordPress theme to get it live on your website.

After your theme is installed, you can use our guide on how to customize your WordPress theme to make it your own.

If you’re just starting out, you can use the Astra Theme or the Coaching Pro theme both are fully compatible with EDD.

Another option is to create your own custom theme from scratch.

To create a custom theme, you’ll need SeedProd.

It is the best website builder plugin in the market and is used by over 1 million websites. You can use it to create beautiful layouts that are professionally designed and optimized for conversions and sales.

SeedProd also comes with lots of ready-made templates. This includes designs that are perfect for promoting your digital downloads. 

The SeedProd page builder plugin

For more details, check out our guide on how to create a custom WordPress theme (no coding needed).

Step 6. Customizing Your Digital Download Emails 

Every time someone buys a digital download, Easy Digital Downloads will send an email to that person.

This email has a link that the customer can use to download the file they just purchased.

The Easy Digital Downloads purchase receipt email

You may want to customize this email to add your own text and branding. Strong branding can make your business look more professional and inspire loyalty.

To customize your emails, go to Downloads » Settings and click on the Emails tab. Then, make sure the General tab is selected.

How to brand your digital download emails

You can start by adding a logo to your emails.

This logo will be shown at the top of your purchase receipt emails. 

A branded digital download email

To add a logo to your emails, click on the Upload File button and upload or choose an existing image from your WordPress media library.

You can also add a ‘From Name.’ This name will be shown in the customer’s inbox. You’ll want to use something that immediately lets customers know who you are, such as the name of your website.

Configuring your digital download email

You’ll also need to add a ‘From Email.’

This email will act as the ‘from’ and ‘reply-to’ address. Since customers may reply to your messages, you’ll want to use a professional email address that you check frequently.

Once you’re happy with your email branding, click on the Purchase Receipts tab. In this tab you can write the email that customers will get every time they make a purchase. 

The Purchase Receipts email.

You may want to start by checking how this email currently looks. To do this, click on the ‘Preview Purchase Receipt’ button. This will show your email in a new tab. 

In the Purchase Receipts tab, you can add an email subject and heading. You can also change the email’s body text. 

Here dynamic text can be your secret weapon. Dynamic text is simply text that changes based on factors such as the buyer’s name and the date. 

Easy Digital Downloads supports dynamic text. If you scroll down, then you’ll find all of the different dynamic text that you can use. 

A list of supported dynamic text

You can copy and paste these different pieces of dynamic text into your emails. 

Every time it sends an email, Easy Digital Downloads will replace this placeholder dynamic text with real values such as the customer’s name.

As you’re working on your email, you may want to send a test email. Simply click on the Send Test button and Easy Digital Downloads will send an email to your admin email address.

The Send Test Email button

Have you clicked on the Send Test email button, but haven’t received an email? Then you can follow our guide on how to fix WordPress not sending email issue to make sure your emails reach your customers.

When you’re happy with your purchase receipt emails, scroll to the bottom of the screen and click on the Save Changes button.

Step 7. Promoting Your Digital Downloads 

Easy Digital Downloads publishes each product as a new page. If you’re going to sell your digital downloads, then you’ll need to drive traffic to these pages. 

This might mean adding these pages to your website’s menu. You can also link to your product pages from different areas of your website. This may include your blog posts, landing pages, or even an announcement bar.

To add these links, you’ll need to know the product page’s URL. You’ll find this information directly beneath the product’s title.

The product URL for a digital download

Another option is adding the product’s Purchase Shortcode to a page or post.

To create a Purchase button, scroll to the product’s Download Settings section. You can then copy the Purchase Shortcode.

An example purchase shortcode

You can then add the shortcode to any post or page, or even a widget area like your sidebar.

For more details, see our guide on how to use shortcodes in WordPress.

The shortcode will add a purchase button. Whenever a visitor clicks on this button, it will add the digital download to their shopping cart. 

Product preview

The purchase button will also turn into a checkout button. Clicking on this button will take the customer to the Easy Digital Downloads checkout, where they can enter their payment information and buy their download.

For more details on how to place the shortcode, you can see our guide on how to add a shortcode in WordPress.

BONUS – Tools to Sell More Digital Downloads

You’ve successfully added digital downloads to your site! Your next challenge is convincing visitors to buy those downloads. 

This is where WordPress plugins come in.

Here are some of our top picks for plugins that can help you sell more digital downloads. 

  • OptinMonster is the conversion optimization software on the market. You can use it to create optin forms to grow your email list and convert visitors into paying customers. It can also reduce shopping cart abandonment.
  • All in One SEO is the best SEO plugin for WordPress and can help you optimize your site for search engines to get more traffic and sales.
  • MonsterInsights is the best Analytics solution for WordPress. It helps you see where your visitors are coming from and what they do on your website, so you can make decisions and update your marketing strategy based on real data.
  • AffiliateWP can help you reach a whole new audience with affiliate marketing. AffiliateWP has everything you need to create your own affiliate program, so people can promote your products to their audience for a commission.
  • PushEngage is the best push notification software for WordPress. It allows you to send personalized web push notifications to let your customers know about everything from new digital downloads, to special offers, and even exclusive coupon codes. 

FAQs About Selling Digital Downloads

Many of our readers regularly reach out to us with questions about selling digital downloads. We have tried to answer some of the most frequently asked questions below.

1. Can I start selling digital downloads for free? 

The Easy Digital Downloads plugin is 100% free. It has everything you need to start selling digital downloads on your WordPress website. 

While Easy Digital Downloads is free, you’ll need a domain name and web hosting account to run it which will cost money. 

As your business grows, you may also want to upgrade to the pro version of Easy Digital Downloads. This advanced plugin includes powerful email marketing tools, more payment gateways, and support for selling digital subscriptions with WordPress.

2. How much does it cost to create a WordPress website? 

It depends on your business plan and budget. You can start with Bluehost for $2.75 per month and use free plugins and themes to limit your costs. We recommend a business model where you start small and then spend money as you start to sell more digital downloads. 

For more information, see our article on how much it costs to build a WordPress website.

3. Can I also sell physical products? 

Absolutely! It’s not unusual for a successful business to expand into new areas.

Despite the name, you can use Easy Digital Downloads to sell physical products. There’s even a Simple Shipping addon that adds shipping features to the Easy Digital Downloads plugin. 

4. Will my customers’ digital download links expire?

By default every digital download link will expire after 24 hours. This is designed to stop customers from sharing your links, or even posting them publicly.

You can change this 24 hour deadline by going to Downloads » Settings in your WordPress dashboard. You can then click on Misc » File Downloads

The download expiration settings

Now, find the Download Link Expiration field. Then simply type in the number of hours you’d like the download link to be available before it expires.

We hope that this tutorial helped you learn how to sell digital downloads. You may also want to see these easy ways to drive traffic to your new website, or see our expert comparison of the best live chat software for small businesses.

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 Sell Digital Downloads on WordPress (Beginner’s Guide) first appeared on WPBeginner.


May 11, 2022 at 04:00PM

Tuesday, May 10, 2022

How to Add Next / Previous Links in WordPress (Ultimate Guide)

Do you want to add next / previous links in WordPress?

Next and previous links are dynamic links that allow users to view the next or previous post.

In this article, we’ll show you how to easily add next/previous links in WordPress and how to make the most out of them.

Adding next and previous links in WordPress

What Are Next / Previous Links in WordPress?

Next / Previous links are dynamic links added by a WordPress theme that allow users to easily navigate to the next or the previous post. This can help to increase pageviews and reduce your bounce rate.

By default, WordPress blog posts are displayed in a reverse chronological order (newer posts first).

This means the next post is the one published after the current post a user is viewing, and the previous post is the one that was published before the current post.

Example of next previous links in a WordPress post

The next/previous links allow users to easily navigate individual articles and blog archive pages. It also helps you get more pageviews for your blog.

Most WordPress themes come with built-in next and previous posts links which are automatically displayed at the bottom of each post. However, some themes don’t display them, or you may want to customize where and how they appear on your WordPress website.

That being said, let’s take a look at how to easily add next and previous links in WordPress.

Following is the list of topics we’ll cover in this article.

Adding Next / Previous Links to WordPress by Using a Plugin

This method is easier and recommended for beginners who are not comfortable adding code to their websites.

First, you need to install and activate the CBX Next Previous Article plugin. For more details, see our step by step guide on how to install a WordPress plugin.

Upon activation, you need to visit the Settings » CBX Next Previous page. From here, you can choose where you want to show the next and previous links on your website.

Next and previous link plugin settings

The plugin allows you to show Next and Previous link arrows on single posts, pages, archive pages, and more.

To make your next and previous links more relevant, you can also choose to display the next and previous posts from the same category or tag.

The free version of the plugin only allows you to display arrows for next and previous articles. You can upgrade to pro version to unlock other display options such as slide-in popup.

Choose arrow color

If you choose to display next / previous posts from same taxonomy, then you need to switch to the Navigate by Taxonomy tab.

From here, you need to choose which taxonomy you want to use to select next and previous links.

Taxonomy select

Optionally, the plugin also allows you to track clicks using Google Analytics. To use this feature, you’ll need to first install Google Analytics in WordPress.

After that, switch to the Google Analytics tab in plugin settings and enable click tracking options.

Enable Google Analytics

Once you are finished, don’t forget to click on the Save Settings button to store your changes.

You can now visit your WordPress website to see the next/previous links in action.

Next / Previous links with arrows

This method is easier but it does not give you much flexibility. For instance, the free version doesn’t display the next or previous post title.

If you need more flexibility, then continue reading.

For this method, you’ll need to edit your WordPress theme files. If you haven’t done this before, then take a look at our guide on how to copy and paste code in WordPress.

Next, you’ll need to connect to your WordPress website using an FTP client or by using the File Manager app in your WordPress hosting control panel.

Once you are connected, you need to navigate to the /wp-content/themes/your-current-theme/ folder.

Editing single.php template

Now, you’ll need to locate the single.php file. This is the file responsible for displaying the single post items on your website.

Some WordPress themes may reference other files inside single.php file. These files are called template parts and are located inside the template-parts folder of your WordPress theme.

For more details, see our article on which files to edit in the WordPress theme.

After that, simply copy and paste the following code at the location in the template file where you want to display the next and previous links.

<?php the_post_navigation(); ?> 

You can now save your changes and visit your website to see Next / Previous links in action.

Simple next and previous links

The above template tag will simply show the link to next and previous posts with post title as the anchor text. It doesn’t say that these are the links to the next and previous articles.

Let’s change this a bit and provide users some context about these links. We’ll do this by adding the available parameters for the the_post_navigation template tag.

Simply replace the above code with the following:

<?php the_post_navigation( array(
 'prev_text'  => __( 'Previous Article: %title' ),
 'next_text'  => __( 'Next Article: %title' ),
 ) );
?>

You can now save your changes and preview your website.

Here is how it looked on our test site:

Next and previous links with context

You can also use special characters and arrows along with next and previous post titles.

Simply replace the code with the following:

<?php the_post_navigation( array(
 'prev_text'  => __( '← %title' ),
 'next_text'  => __( '%title →' ),
 ) );
?>

Here is how this code looked on our test website:

Next and previous links with arrow

Now let’s say you want to make the next and previous links more relevant to the article the user is currently viewing.

You can do that by showing the next and previous links from the same category or tags.

<?php the_post_navigation( array(
 'prev_text'  => __( '← %title' ),
 'next_text'  => __( '%title →' ),
 'in_same_term' => true, 
 'taxonomy'     => __( 'category' ),
 ) );
?>

This code tells WordPress to display next and previous posts in the same category. You can change taxonomy parameter to tags or any other custom taxonomy if needed.

Styling Next / Previous Links in WordPress

Now that we have learned how to add Next / Previous links in WordPress, let’s take a look at how to style them properly.

By default, WordPress automatically adds several default CSS classes to the post navigation links. You can use these CSS classes in your WordPress theme to style these links.

Here is some basic CSS that you can add to your theme.

.nav-links,
.posts-navigation .nav-links,
.post-navigation .nav-links {
        display: flex;
}

.nav-previous,
.posts-navigation .nav-previous,
.post-navigation .nav-previous {
        flex: 1 0 50%;
}

.nav-next,
.posts-navigation .nav-next,
.post-navigation .nav-next {
        text-align: end;
        flex: 1 0 50%;
}

This basic CSS simply displays next and previous links next to each other but on the different sides of the same line.

You can also make your navigation links standout by adding background color, hover effect, and more.

Here is some sample CSS code that you can use as an starting point.

.post-navigation {
background-color:#f3f9ff;
padding:0px;
}
.nav-previous, .nav-next{
padding:10px;
font-weight:bold
}
.nav-previous:hover,.nav-next:hover {
background-color:#0170b9;
}
.nav-previous:hover a:link ,.nav-next:hover a:link {
color:#fff;
}

This code styles the link text and adds some background color and hover effect to make next and previous links more prominent.

Next and previous link CSS style

Adding Next / Previous Links to WordPress Pages

Normally, the post navigation links are used for blog posts in WordPress. That’s because those items are published in reverse chronological order.

On the other hand, WordPress pages are not generally published in chronological order. For more details, see our guide on the difference between posts and pages in WordPress.

However, some users may need to display page navigation so that users can find the next page easily.

Luckily, you can use use the same code we used earlier for pages. However, you’ll need to add the code inside page.php template.

<?php the_post_navigation( array(
  'prev_text'   => __( '← %title' ),
  'next_text'   => __( '%title →' ),
   ) );
?>

Here is how it looked on our demo site:

Next and previous links for a WordPress paage

Adding Next / Previous links in WordPress with Thumbnails

Want to make your next and previous links more noticeable? Images are the easiest way to attract user attention and make these links more engaging.

Let’s add next and previous links with post thumbnail or featured image next to them.

First, you need to add the following code to theme’s functions.php file or a site-specific plugin.

function wpb_posts_nav(){
    $next_post = get_next_post();
    $prev_post = get_previous_post();
     
    if ( $next_post || $prev_post ) : ?>
     
        <div class="wpb-posts-nav">
            <div>
                <?php if ( ! empty( $prev_post ) ) : ?>
                    <a href="<?php echo get_permalink( $prev_post ); ?>">
                        <div>
                            <div class="wpb-posts-nav__thumbnail wpb-posts-nav__prev">
                                <?php echo get_the_post_thumbnail( $prev_post, [ 100, 100 ] ); ?>
                            </div>
                        </div>
                        <div>
                            <strong>
                                <svg viewBox="0 0 24 24" width="24" height="24"><path d="M13.775,18.707,8.482,13.414a2,2,0,0,1,0-2.828l5.293-5.293,1.414,1.414L9.9,12l5.293,5.293Z"/></svg>
                                <?php _e( 'Previous article', 'textdomain' ) ?>
                            </strong>
                            <h4><?php echo get_the_title( $prev_post ); ?></h4>
                        </div>
                    </a>
                <?php endif; ?>
            </div>
            <div>
                <?php if ( ! empty( $next_post ) ) : ?>
                    <a href="<?php echo get_permalink( $next_post ); ?>">
                        <div>
                            <strong>
                                <?php _e( 'Next article', 'textdomain' ) ?>
                                <svg viewBox="0 0 24 24" width="24" height="24"><path d="M10.811,18.707,9.4,17.293,14.689,12,9.4,6.707l1.415-1.414L16.1,10.586a2,2,0,0,1,0,2.828Z"/></svg>
                            </strong>
                            <h4><?php echo get_the_title( $next_post ); ?></h4>
                        </div>
                        <div>
                            <div class="wpb-posts-nav__thumbnail wpb-posts-nav__next">
                                <?php echo get_the_post_thumbnail( $next_post, [ 100, 100 ] ); ?>
                            </div>
                        </div>
                    </a>
                <?php endif; ?>
            </div>
        </div> <!-- .wpb-posts-nav -->
     
    <?php endif;
}

This code simply creates a function that displays the next and previous posts with featured images or post thumbnails.

Next, you need to add the wpb_posts_nav() function to your theme’s single.php file where you want to display the links.

If your theme already has next and previous links, then you may want to find the line that contains the_post_navigation() function and delete it.

Remove existing post navigation code

Now add the following code to display your custom next and previous links.

<?php wpb_posts_nav(); ?>

After adding the code, don’t forget to save your changes and visit your website to see the links in action.

Next and previous links without styling

Now, you may notice that these links don’t look very clean.

Let’s change that by adding some custom CSS to style them.

.wpb-posts-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-gap: 50px;
    align-items: center;
    max-width: 1200px;
    margin: 100px auto;
}
 
.wpb-posts-nav a {
    display: grid;
    grid-gap: 20px;
    align-items: center;
}
 
.wpb-posts-nav h4,
.wpb-posts-nav strong {
    margin: 0;
}
 
.wpb-posts-nav a svg {
    display: inline-block;
    margin: 0;
    vertical-align: middle;
}
 
.wpb-posts-nav > div:nth-child(1) a {
    grid-template-columns: 100px 1fr;
    text-align: left;
}
 
.wpb-posts-nav > div:nth-child(2) a {
    grid-template-columns: 1fr 100px;
    text-align: right;
}
 
.wpb-posts-nav__thumbnail {
    display: block;
    margin: 0;
}
 
.wpb-posts-nav__thumbnail img {
    border-radius: 10px;
}

You can now save your changes and visit your website to view next and previous links with thumbnails.

Here is how it looked on our test site:

Next and previous links with thumbnails

For more details, you can see our guide on how to add thumbnails to previous and next post links.

Bonus: Remove Next and Previous Links in WordPress

Some users may want to remove next and previous links in WordPress.

For instance, some users may find that these links are less helpful. Some may want to display related posts or popular posts instead.

There are two ways you can remove the next and previous links in WordPress.

Method 1. Delete The Code in Your WordPress Theme

To remove the next and previous links in WordPress, you’ll need to remove the code responsible for displaying the links in your WordPress theme.

The problem with this approach is that as soon as you update your theme, the deleted code will come back.

To avoid this, you’ll need to create a child theme.

Next, you need to find the code responsible for displaying the next and previous links in your parent theme.

Usually, it is found inside single.php or content-single.php templates.

Basically, you’ll be looking for the code that includes the following function.

<?php the_post_navigation() ?> 

This code may have a slightly different format and parameters to it. For instance, on our test site the theme used this code to display the links:

the_post_navigation(
                                array(
                                        'prev_text' => '<span class="nav-subtitle">' . esc_html__( 'Previous:', 'mytheme' ) . '</span> <span class="nav-title">%title</span>',
                                        'next_text' => '<span class="nav-subtitle">' . esc_html__( 'Next:', 'mytheme' ) . '</span> <span class="nav-title">%title</span>',
                                )
                        );

If you are using a child theme, then you need to duplicate this particular template in your child theme and then delete the lines used to display next or previous links.

If you would rather just delete it in your parent theme, then you can do that as well.

Deleting the code will stop WordPress from displaying next and previous links.

Method 2. Hide The Next and Previous Posts Links

This method doesn’t really remove the next and previous links. Instead, it just makes them invisible to human readers.

Simply add the following Custom CSS to your WordPress theme.

nav.navigation.post-navigation {
    display: none;
}

Don’t forget to save your changes and visit your website to see the navigation links disappear.

Remove next previous links in WordPress using CSS

We hope this article helped you learn how to easily add next and previous links in WordPress. You may also want to see our guide on how to choose the best web design software, or our expert comparison of the best domain registrars.

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 Add Next / Previous Links in WordPress (Ultimate Guide) first appeared on WPBeginner.


May 10, 2022 at 04:00PM

Monday, May 9, 2022

How to Accept ACH Payments in WordPress

Do you want to accept ACH payments on your WordPress website?

ACH (Automated Clearing House) payments are a bank-to-bank payment method in the United States. ACH payments help save transaction fees for business owners since they are a lot lower than a credit card or digital wallet transaction fees.

In this article, we’ll show you how to accept ACH payments in WordPress.

How to accept ACH payments in WordPress

Why Accept ACH Payments in WordPress?

If your business is located in the United States, then you can lower your transaction fees by a lot when you accept ACH payments on your WordPress site. It’s a perfect payment method if you regularly accept large amounts of money from customers.

For example, the Stripe fee for accepting ACH payments is just 0.8% per transaction, with a maximum cap of $5.

On the other hand, a typical credit card or digital wallet payment fee is 2.9% + USD 0.30 per transaction. Even newer methods like Apple Pay charge a 1.5% fee, nearly double ACH.

Keeping these fees in mind, let’s say a customer pays $100. Through ACH payments, the transaction fee would be roughly $0.80. At the same time, the transaction fee for the same amount through a credit card or digital wallet would be $3.20.

Similarly, on an $800 payment amount, the transaction fee through ACH would be $6.40, and through cards or digital wallets would be $23.50. What this means is that the higher the transaction amount, the more you’ll save in transaction costs.

Another advantage of using ACH payments is getting higher customer retention and reducing the churn rate. Credit and debit cards expire after a certain period, which means that customers will stop doing business until their cards are renewed. With ACH payments, you can overcome this issue and reduce involuntary churn.

That said, let’s look at how you can accept ACH payments in WordPress.

Accepting ACH Payments in WordPress

The best way to allow ACH payments in WordPress is by using the WP Simple Pay plugin. It’s the best Stripe plugin for WordPress and will let you set up one-time payments or recurring payments without setting up a shopping cart.

We’ll use the WP Simple Pay Pro version for this tutorial because it includes ACH payments, on-site payment forms, and other features. There is also a free version of the plugin, but it doesn’t have an ACH payment option.

First, you’ll need to install and activate the WP Simple Pay plugin. If you need help, then please see our detailed guide on how to install a WordPress plugin.

Once the plugin is active, it will automatically launch the setup wizard. Go ahead and click the ‘Let’s Get Started’ button.

The WP Simple Pay Setup Wizard Will Start Automatically

On the next screen, you’ll need to enter the license key. You can easily find the license key in your WP Simple Pay account area.

After entering the key, you can click the ‘Activate and Continue’ button.

You’ll Be Asked to Enter Your WP Simple Pay License Key

Next, you’ll need to connect WP Simple Pay with Stripe.

Stripe is a popular payment gateway that allows you to collect ACH payments on your WordPress site.

Go ahead and click the ‘Connect with Stripe’ button.

Connecting WP Simple Pay to Stripe

After that, you can log in to your Stripe account and connect it with WP Simple Pay.

Just a note that Stripe requires websites to have HTTPS encryption. If you don’t already have an SSL certificate for your website, then please see our step-by-step guide on how to get a free SSL certificate for WordPress.

Once your Stripe account is connected, WP Simple Pay will show different email options to configure. You can enable emails for payment receipts, upcoming invoices, and payment notifications.

Configure Your WP Simple Pay Emails

Next, enter your business email address where you’d like to receive these emails, and then click the ‘Save and Continue’ button.

After that, you’ll arrive at the last step in the setup wizard, where you’ll need to create a payment form. Simply click on the ‘Create a Payment Form’ button.

WP Simple Pay Setup Is Complete

Setting Up a WP Simple Pay Payment Form

You can also create a payment form in WP Simple Pay by going to WP Simple Pay » Add New from your WordPress dashboard.

You will see a number of payment form templates. You need to hover over the ‘ACH Direct Debit Form’ template and then click the ‘Use Template’ button that appears.

Select the ACH Direct Debit Form Template

You’ll find yourself on the ‘General’ tab of the payment form editor. If you like, you can rename the form and give it a description.

We’ll leave the other settings with their default values.

If You Like, Rename Your Form and Give It a Description

Next, go to the ‘Payment’ tab in the payment form and enter the price amount and label.

You should also set up whether it is a one-time payment or a recurring subscription.

Enter payment details

After that, head down to the ‘Form Field’ tab.

Under the Payment Method section, you’ll notice that the ‘ACH Direct Debit’ and ‘Card’ payment options have already been selected for you. If you like, you can also select any other payment methods that you’d like to use.

ACH and Credit Card Payment Options Have Already Been Set Up for You

Next, you can preview your ACH payment form and then publish it.

To do that, simply click the ‘Publish’ button in WP Simple Pay.

Publish your ACH form

You can now add your ACH payment form anywhere on your WordPress website.

To start, go ahead and add a new page or edit an existing one. Once you’re in the content editor, simply add a WP Simple Pay block. After that, you should select your ACH form from the dropdown menu.

Add WP Simple Pay Block

Once that’s done, you can preview your page and publish it.

Now you can visit your website to see the ACH payment form in action. Here’s a preview of what it looks like on our demo site.

ACH Payment Form Preview

Final Thoughts on Adding ACH Payments in WordPress

The above method is the simplest way to accept ACH payment in WordPress without using a shopping cart.

However, if you’re using WordPress for your online store or to sell digital downloads, then most of those eCommerce plugins also support ACH payments.

For example, you can use Easy Digital Downloads to sell digital downloads like eBooks, software, music, etc, and it lets you accept ACH payments.

Alternatively, WooCommerce will allow you to sell physical goods and accept ACH payments.

We hope that this article helped you learn how to accept ACH payments in WordPress. You can also see our guide on how much it costs to build a website and the best WordPress plugins.

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 Accept ACH Payments in WordPress first appeared on WPBeginner.


May 09, 2022 at 02:30PM