Integrating Disqus Comments in WordPress Plugin

Posted on 16th June 2023

What is Disqus?

Disqus is a commenting system that allows users to leave comments on websites and blog posts. It is a popular option for many website and blog owners because it is easy to use and can be customized to fit the look and feel of the site. Disqus also allows users to login with their social media accounts, which makes it easier for people to leave comments.

Why Use Disqus in a WordPress Plugin?

There are a few reasons why you might want to use Disqus comments in your WordPress plugin. First, Disqus is a popular commenting system that many website and blog owners are already using. This means that if your plugin integrates with Disqus, it will be easier for users to leave comments on your plugin’s pages.

Second, Disqus offers a lot of features that you can take advantage of in your plugin. For example, Disqus allows you to moderate comments, track comment activity, and even generate revenue with Disqus Ads.

Finally, Disqus is easy to use and can be customized to match the look and feel of your plugin. In this tutorial, we will show you how to easily integrate Disqus comments into your WordPress plugin.

How to Integrate Disqus Comments in WordPress Plugin

  1. First, you need to sign up for a free Disqus account. You can do that by going to the Disqus website and clicking on the “Sign Up” button.
  2. Once you have created your account, you will be asked to choose a website platform. Select “Other” from the list of options and then enter your WordPress plugin’s URL in the “Website Address” field.

  3. Disqus will now ask you to choose a Disqus subdomain. This is the prefix that will be used for your comments URL. For example, if you choose the subdomain “myplugin”, your comments URL will be “myplugin.disqus.com”.

  4. After choosing your subdomain, you will be asked to select a category for your website. Select the “WordPress” category from the list of options.

  5. Disqus will now generate a shortcode for your plugin. This shortcode will be used to insert the Disqus comments into your WordPress plugin. Copy this shortcode and save it for later.

  6. Next, you need to install and activate the Disqus Comment System plugin. For more information, see our step by step guide on how to install a WordPress plugin.

  7. Once the plugin is activated, go to Settings » Disqus to configure the plugin settings.

  8. On the plugin settings page, enter your Disqus shortcode in the “Shortcode” field and then click on the “Save Changes” button to store your settings.

  9. That’s it. You have successfully integrated Disqus comments into your WordPress plugin.

There are two ways to integrate Disqus comments in your WordPress plugin. The first method is to use the Disqus Comments WordPress plugin. The second method is to use the Disqus Conditional Load plugin.

Disqus Comments Plugin

The Disqus Comments plugin is the easiest way to integrate Disqus comments into your WordPress plugin. All you need to do is install and activate the plugin, and then enter your Disqus shortname in the plugin settings.

Once you have entered your Disqus shortname, the plugin will automatically add Disqus comments to all of your WordPress plugin pages.

Disqus Conditional Load Plugin

The Disqus Conditional Load plugin is a bit more complex to setup, but it provides more control over when Disqus comments are loaded.

With this plugin, you can specify exactly which plugin pages you want Disqus comments to appear on. This can be useful if you want to disable Disqus comments on certain pages, or if you only want Disqus comments to appear on certain post types.

To use this plugin, you first need to install and activate it. After that, you need to edit the plugin settings and specify the post types and pages where you want Disqus comments to appear.

Disqus Integration in WordPress Plugin

Once you have installed and activated either of the two plugins mentioned above, you will need to do a few more things to complete the integration.

First, you need to go to the Disqus website and create a new account. Once you have created an account, you need to create a new site.

After you have created a new site, you will be given a Disqus shortname. This is the name you need to enter in the plugin settings.

Once you have entered your Disqus shortname, you need to go to the Disqus website and login. After you have logged in, you need to go to the Admin section and click on the “Add Site” button.

Enter the URL of your WordPress plugin in the “Site URL” field and then click on the “Add Site” button.

Once you have added your WordPress plugin to Disqus, you need to go to the Disqus website and login. After you have logged in, you need to go to the Admin section and click on the “Appearance” tab.

In the “Appearance” tab, you need to scroll down to the “Embed Code” section and click on the “Enable JavaScript” checkbox.

After you have enabled JavaScript, you need to copy the Disqus embed code and paste it into the WordPress plugin code.

You can find the Disqus embed code by going to the Disqus website and login. After you have logged in, you need to go to the Admin section and click on the “Appearance” tab.

In the “Appearance” tab, you need to scroll down to the “Embed Code” section and click on the “Copy Code” button.

After you have copied the Disqus embed code, you need to paste it into the WordPress plugin code.

You need to paste the Disqus embed code into the WordPress plugin code at the location where you want the Disqus comments to appear.

Once you have added the Disqus embed code to the WordPress plugin code, you need to save the code and then upload it to your WordPress plugin directory.

After you have uploaded the WordPress plugin code, you need to go to the WordPress plugin page and activate the plugin.

Once the plugin is activated, the Disqus comments will appear on your WordPress plugin pages.