How to Create an Online Marketplace using WordPress

Create an Online Marketplace

In this article, we will show you how to easily create an online marketplace using WordPress.

 

What Do You Need to Start an Online Marketplace using WordPress?

First you need to make sure that you are using the right website platform, and since you’re reading this article, you’re in the right place.

There are two types of WordPress available: WordPress.com vs WordPress.org. One is a limited blog hosting service while the other is known as the self-hosted WordPress which you’ve likely heard tons about. See the full comparison between WordPress.com vs WordPress.org.

We recommend using WordPress.org because it gives you the freedom and access to all WordPress features out of the box.

To start an online marketplace using self-hosted WordPress you will need the following:

  • A domain name (For example, wpcademy.com)
  • Web hosting account (This is where your website’s files are stored)
  • SSL Certificate (To securely accept online payments)
  • WooCommerce (best WordPress eCommerce addon)
  • Online marketplace addon

The entire setup can take up to 40 minutes, and we will walk you through every step one by one.

Ready? Let’s get started.

Step 1. Setting up Your Ecommerce Platform

First step is to buy a domain name and a web hosting account. You don’t just need a web hosting, but you will need a service that specializes in WooCommerce hosting because this is the software that we will be using as our eCommerce platform.

Typically a domain name costs $14.99/year, web hosting 7.99/month, and SSL certificate 69.99/year.

Now this seems like a lot of money if you are just starting out.

Fortunately, Bluehost an officially recommended WordPress and WooCommerce hosting provider has agreed to offer our users free domain + SSL and discount on their cloud WordPress hosting.

Basically, you can get started for $6.95 / month.

→ Click Here to Claim This Exclusive Bluehost Offer ←

Once you have purchased hosting, then follow our step by step tutorial on how to start an online store for complete setup instructions.

You would now have a WordPress website with WooCommerce installed on it. However, by default WooCommerce assumes that your website is a single vendor website, so it is not possible for other users to add their own products to your website.

Let’s change this.

Step 2. Turn Your WooCommerce Site into an Online Marketplace

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

Upon activation, head over to WooCommerce » WC Vendors page to configure marketplace settings.

On this screen, you need to set a commission rate that you will pay to each vendor. This rate could also be overridden for individual products or vendors.

The default settings on the page will work for most sites, but you can review and change them as needed.

Don’t forget to click on the ‘Save General changes’ button to store your settings.

Next, you need to switch to the products page. On this screen, you can choose which items to hide from vendors when they are adding a product.

WC Vendors allows you to setup vendor capabilities and permissions. Head over to the Capabilities tab on the WC Vendors settings page.

Next item on the WC Vendors settings page is to setup pages.

The plugin will automatically create pages to use for vendor dashboard, shop settings, and orders page. You can use a different page if you would like by using the shortcodes shown below each page.

One page that is not automatically created by the plugin is the terms page. These are the terms that a vendor has to agree to when submitting their application.

To create a terms page, you can simply create a new page in WordPress and add the terms and conditions in plain text describing what vendors can sell, how they will get paid, how to settle disputes, etc.

Once you have created a terms page, you can return back to this section and select your newly created page here.

The final item on WC Vendors settings page is the most important one, the Payments. By default, WC Vendors uses PayPal Adaptive Payments to pay vendors.

You will see a link to setup PayPal adaptive payments. After you have set it up, you can choose when you want to pay the vendors.

Now that WC Vendors is all set up, let’s setup WooCommerce for a multi-vendor environment.

Step 3. Enable Account Management in WooCommerce

First you need to visit WooCommerce » Settings page and click on the ‘Accounts’ tab. From here you need to check the boxes next to customer registration option.

Don’t forget to save your changes.

Step 4. Setting Up Navigation Menus

Now that your multi-vendor marketplace setup is finished. It is time to make it easy for your users to find their way around your website.

To do that, you need to visit Appearance » Menus page. You will need to add your user account and checkout pages to the navigation menu.

adding-menu-items

Don’t forget to click on the ‘Save Menu’ button to store your changes. For more detailed instructions, see our guide on how to add navigation menus in WordPress.

If you don’t have a My Account page, then simply create a new page in WordPress and add the following shortcode in the post editor.

[woocommerce_my_account]

Step 5. Testing Your Marketplace Website

Your online marketplace website is now ready for testing. You can visit your website in a new browser window and create a new account by clicking on the My Account link at the top.

testsite

From here, both customers and vendors can login to their accounts as well as create a new account.

Once users create a new account, you will recieve an email notification. If you are unable to recieve email notifications, then take a look at our guide on how to fix WordPress not sending email issue.

You can also view new vendor applications by visiting Users » All Users page. You will see all new vendor requests as ‘pending vendor’, and you can approve or deny applications by clicking the link under their username.

Approve vending vendors

Once approved, these vendors can log in to their accounts and add their products by visiting their vendor dashboard. They can also view their orders and sales reports.

Vendor dashboard

The first thing your vendors need to do is to setup their shop settings by clicking on ‘Store Settings’ link.

Shop settings

They will need to provide their PayPal email address to recieve payments. After that they can enter their shop name and description.

Once a vendor adds a new product, you will get a notification email and see an icon next to the products menu. You can then edit a product, approve it, or delete it.

Pending products

Your shop page will clearly show the products sold by vendor’s shop name.

Sold by vendor

We hope this article helped you learn how to create an online marketplace using WordPress. You may also want to see our pick of the best WooCommerce themes, best WooCommerce plugins, and the ultimate WordPress SEO guide for beginners.

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.

Easy Guide to Add YouTube Subscribe Button in WordPress

In this article, we will show you how to add a YouTube subscribe button in WordPress.

 

Method 1: Manually Adding YouTube Subscribe Button Code

The first thing you need to do is visit the YouTube subscribe button page on the Google Developer’s website.

 

On this page, you will need to enter your YouTube channel’s name, select a layout, theme, and subscriber count option. It will display a live preview of how your button will look on the website. Once you are satisfied, simply scroll down to copy the embed code.

Next, you need to login to the WordPress admin area of your site and go to Appearance » Widgets. There you will need to drag and drop a text widget to your widget area, and paste the YouTube subscribe button code inside the widget.

Once you are done, don’t forget to save your changes and visit your website to see the YouTube subscribe button in action.

 

Method 2: Using Plugin to Add a YouTube Subscribe Bar

Another way to add a YouTube subscribe button on your website is by adding it below every YouTube video on your site. This offers additional exposure and can help you significantly increase your subscribers.

First you need to install and activate the YouTube Subscribe Bar plugin.

Upon activating the plugin, you need to go to Settings » YouTube Subscribe Bar to add your YouTube channel ID. You will also need to style the button layout, choose a button theme, and show subscribers count.

The YouTube subscribe bar plugin allows you to add some text before the button and edit its styling. You can use this area to add a call to action like “Subscribe to My Channel”.

Once you are done, make sure to click on the Save Changes button to save your settings.

This plugin will automatically display your YouTube Subscribe bar below every YouTube video on your site. The YouTube Subscribe bar will appear on the videos from your channel and third-party channels, so you can share useful video content on your site and get more subscribers on your YouTube channel.

 

Note: The YouTube subscribe bar plugin only works with oEmbed videos. It will not work with videos embedded via iFrame.

We hope this article helped you add the YouTube subscribe button in WordPress. You may also want to check out our guide on how to track user engagement on your WordPress site.

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.

Easy Guide to Modify the Help Dropdown Text in WordPress Admin Area

Modify the Help Dropdown Text in WordPress Admin Area

Each WordPress admin screen has a Help button. This area drop downs and contains text that helps the user understand the features of the specific page. When creating a custom site for your clients or a plugin, then you may find a need to modify the Help Dropdown text. In this article, we will show you how to modify the help dropdown text in WordPress admin area.

First open your theme’s functions.php file and paste the following code:

1
2
3
4
5
6
7
8
9
10
add_action('load-page-new.php','custom_help_page');
add_action('load-page.php','custom_help_page');
function custom_help_page() {
  add_filter('contextual_help','custom_page_help');
}
function custom_page_help($help) {
  // echo $help; // Uncomment if you just want to append your custom Help text to the default Help text
  echo "<h5>Custom Help text</h5>";
  echo "<p> HTML goes here.</p>";
}

This code above will add custom help text on every Add New Page screen. You can do this for your posts page, or any other screen. This is something that we will be utilizing for our plugins that we have intentions of creating.

Source: Sixrevisions Blog

Easy Guide to Remove Menu Item in WordPress Admin Panel

Remove Menu Item in WordPress Admin Panel
WordPress admin panel comes with a lot of options in the menu, but you can get rid of them fairly easily if necessary. With one of our clients, we needed to get rid of few menu items, so it is easier for her to understand things. In this article, we will show you how easy it is to remove a menu item in the WordPress Admin Panel.

For WordPress 3.1 or above, just paste the following code in your theme’s functions.php file:

1
2
3
4
add_action( 'admin_menu', 'my_remove_menu_pages' );
function my_remove_menu_pages() {
    remove_menu_page('link-manager.php');  
}

In version prior to WordPress 3.1, you would need to paste the following code in your theme’s functions.php file:

1
2
3
4
5
6
7
8
9
10
function remove_menus () {
global $menu;
    $restricted = array(__('Links'));
    end ($menu);
    while (prev($menu)){
        $value = explode(' ',$menu[key($menu)][0]);
        if(in_array($value[0] != NULL?$value[0]:"" , $restricted)){unset($menu[key($menu)]);}
    }
}
add_action('admin_menu', 'remove_menus');

The code above will get rid of the Links option for all users (including administrators). Only two user roles are allowed to see the Link tab (Administrators and Editors). Now if this is for a multi-author site (where there are many editors), and you as an administrator still want access to the Links menu, then you can add parameters to do so.

You would need to utilize the function current_user_can(), and with a simple if statement, you can get rid of the link menu or other items for specific user role.

This is a very handy trick for consultants and developers who work on larger sites.

Additional Sources

Remove Menu Page
Current User Can Function Reference
User Roles and Capabilities Chart

How To Install SquirrelMail on CentOS 7

SquirrelMail on CentOS 7

Squirrelmail is one of the most popular Web-based email clients written in PHP. It has built-in pure PHP support for IMAP and SMTP, and it is designed to render all pages in pure HTML 4.0 with no JavaScript required, for maximum compatibility across browsers.

Prerequisites

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation SquirrelMail email clients on a CentOS 7 server.
Install SquirrelMail on CentOS 7

Step 1. First, let’s start by ensuring your system is up-to-date.

yum clean all
yum install epel-release
yum -y update

Step 2. Installing SquirrelMail on CentOS 7.

Install SquirrelMail using the yum default package manager:

yum install squirrelmail

Step 3. Configure SquirrelMail.

Once the webmail client is installed, you can configure it according to your needs by running the configuration script:

cd /usr/share/squirrelmail/config/
./conf.pl

SquirrelMail Configuration : Read: config.php (1.4.0)
---------------------------------------------------------
Main Menu --
1. Organization Preferences
2. Server Settings
3. Folder Defaults
4. General Options
5. Themes
6. Address Books
7. Message of the Day (MOTD)
8. Plugins
9. Database
10. Languages

D. Set pre-defined settings for specific IMAP servers
C Turn color off
S Save data
Q Quit

Command >>

There are different settings in the configuration file, but the main things that should be checked and configured are:

Set your default domain name (2. Server settings > 1. Domain)
Addresses of IMAP and SMTP servers.
Type of IMAP server.

Step 4. Accessing SquirrelMail.

SquirrelMail will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/squirrelmail or http://server-ip/squirrelmail and complete the required the steps to finish the installation.

Congratulations! You have successfully installed SquirrelMail. Thanks for using this tutorial for installing SquirrelMail email clients in CentOS 7 systems. For additional help or useful information, we recommend you to check the official SquirrelMail web site.

How To Install Mantis Bug Tracker on CentOS 7

Mantis Bug Tracker on CentOS 7

Mantis is a free and popular open source bug tracking system. It is written in PHP and supports all types of database server. It provides a professional dashboard to manage bugs assigned to the user. It supports powerful access control which provides per project base user access. It is very flexible, you can customize the issue fields, notifications, and workflow.

Prerequisites

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Mantis Bug Tracker on a CentOS 7 server.
Install Mantis Bug Tracker on CentOS 7

Step 1. First let’s start by ensuring your system is up-to-date.

yum clean all
yum -y update

Step 2. Install LAMP server.

A CentOS 7 LAMP stack server is required. If you do not have LAMP installed, you can follow our guide here. Also install required PHP modules:

yum -y install php-gd php-imap php-xml php-xmlrpc php-mbstring php-mcrypt php-mssql php-snmp curl curl-devel

Step 3. Installing Mantis Bug Tracker.

First thing to do is to go to Mantis Bug Tracker’s download page and download the latest stable version of Mantis, At the moment of writing this article it is version 2.5.0:

wget https://ncu.dl.sourceforge.net/project/mantisbt/mantis-stable/2.5.0/mantisbt-2.5.0.zip

Unpack the Nextcloud archive to the document root directory on your server:

tar -xpf mantisbt-2.5.0.tar.gz
mv mantisbt-2.4.1 /var/www/html/mantis

We will need to change some folders permissions:

chown apache:apache -R /var/www/html/mantis/

Step 4. Configuring MariaDB for Mantis Bug Tracker.

By default, MariaDB is not hardened. You can secure MariaDB using the mysql_secure_installation script. You should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MariaDB.

mysql_secure_installation

Configure it like this:

- Set root password? [Y/n] y
- Remove anonymous users? [Y/n] y
- Disallow root login remotely? [Y/n] y
- Remove test database and access to it? [Y/n] y
- Reload privilege tables now? [Y/n] y

Next we will need to log in to the MariaDB console and create a database for the Mantis Bug Tracker. Run the following command:

mysql -u root -p

This will prompt you for a password, so enter your MariaDB root password and hit Enter. Once you are logged in to your database server you need to create a database for Mantis Bug Tracker installation:

MariaDB [(none)]> CREATE DATABASE mantisdb;
MariaDB [(none)]> GRANT ALL PRIVILEGES ON mantisdb.* TO 'mantis'@'localhost' IDENTIFIED BY 'mantispassword';
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> \q

Step 5. Configuring Apache web server for Mantis Bug Tracker.

We will create Apache virtual host for your Nextcloud website. First create ‘/etc/httpd/conf.d/vhosts.conf’ file with using a text editor of your choice:

nano /etc/httpd/conf.d/vhosts.conf
IncludeOptional vhosts.d/*.conf

Next, create the virtual host:

mkdir /etc/httpd/vhosts.d/
nano /etc/httpd/vhosts.d/yourdomain.com.conf

Add the following lines:

ServerAdmin [email protected]
DocumentRoot "/var/www/html/mantis/"
ServerName yourdomain.com
ServerAlias www.yourdomain.com
ErrorLog "/var/log/httpd/yourdomain.com-error_log"
CustomLog "/var/log/httpd/yourdomain.com-access_log" combined

<Directory "/var/www/html/mantis/">
DirectoryIndex index.html index.php
Options FollowSymLinks
AllowOverride All
Require all granted

Save and close the file. Restart the apache service for the changes to take effects:

systemctl restart httpd.service
systemctl enable httpd.service

Step 6. Accessing Mantis Bug Tracker.

Mantis Bug Tracker will be available on HTTP port 80 by default. Open your favorite browser and navigate to http://yourdomain.com/mantis/admin/install.php or http://server-ip/mantis/admin/install.php and complete the required the steps to finish the installation. If you are using a firewall, please open port 80 to enable access to the control panel.

Congratulation’s! You have successfully installed Mantis. Thanks for using this tutorial for installing Mantis free open source bug tracking system on your CentOS 7 system. For additional help or useful information, we recommend you to check the official Mantis Bug Tracker web site.

How To Install Let’s Encrypt SSL With Nginx on CentOS 7

Let’s Encrypt SSL With Nginx on CentOS 7

LetsEncrypt is a free open certificate authority (CA) that provides free certificates for websites and other services. The service, which is backed by the Electronic Frontier Foundation, Mozilla, Cisco Systems, and Akamai. Unfortunately, LetsEncrypt.org certificates currently have a 3 month lifetime. This means you’ll need to renew your certificate quarterly for now.

Prerequisites

This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation Let’s Encrypt SSL with Nginx on a CentOS 7 server.
Install Let’s Encrypt SSL With Nginx on CentOS 7

Step 1. First let’s start by ensuring your system is up-to-date.

yum clean all
yum -y update
Step 2. Installing Let’s Encrypt SSL on CentOS 7.

In CentOS 7, you can find Certbot on the EPEL repository; if you enable it, just install what you need:
yum install epel-release
yum install certbot

You will also need to have nginx installed and running. Of course, if you are adding certificates onto a previously configured web host this would already be installed:

yum install nginx
systemctl start nginx

The first step to install let’s encrypt ssl on CentOS Linux is to add a simple configuration inside your nginx virtual host configuration. Add this line to your vhost configuration:

location ~ /.well-known {
allow all;
}

Save and exit to apply changes:

nginx -t
systemctl restart nginx

Obtaining a certificate with Certbot:

Run the command as you see below, replace “wpcademy.com” with your real domain name and /var/www/wpcademy.com with your real webroot path:

certbot certonly -a webroot --webroot-path=/var/www/wpcademy.com -d wpcademy.com -d www.wpcademy.com

Result:

[[email protected]:~]certbot certonly -a webroot --webroot-path=/var/www/wpcademy.com -d wpcademy.com -d www.wpcademy.com
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for wpcademy.com
Using the webroot path /var/www/html for all unmatched domains.
Waiting for verification...
Cleaning up challenges
Generating key (2048 bits): /etc/letsencrypt/keys/0001_key-certbot.pem
Creating CSR: /etc/letsencrypt/csr/0001_csr-certbot.pem
IMPORTANT NOTES:
- Congratulations! Your certificate and chain have been saved at
/etc/letsencrypt/live/idroot.us/fullchain.pem. Your cert
will expire on 2017-07-16. To obtain a new or tweaked version of
this certificate in the future, simply run certbot again. To
non-interactively renew *all* of your certificates, run "certbot
renew"
- If you like Certbot, please consider supporting our work by:

Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate
Donating to EFF: https://eff.org/donate-le
[[email protected]:~]

Step 3. Configure Let’s Encrypt TLS/SSL on Nginx Web Server.

First, edit the Virtual Host file you specified during configuration through Certbot and add this three directives:

listen 443 ssl http2;
ssl_certificate /etc/letsencrypt/live/idroot.us/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/idroot.us/privkey.pem;

The full nginx vhost configuration may look like this:

server {
listen 80;
server_name wpcademy.com www.wpcademy.com;
rewrite ^(.*) https://wpcademy.com$1 permanent;
}

server {
access_log off;
log_not_found off;
error_log logs/idroot.us-error_log warn;

server_name wpcademy.com;
root /var/www/wpcademy.com;
index index.php index.html index.htm;

listen 443 ssl http2;
ssl_certificate /etc/letsencrypt/live/wpcademy.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/wpcademy.com/privkey.pem;

## Stuff required by certbot
location ~ /.well-known {
allow all;
}

## SSL
ssl_session_cache shared:SSL:20m;
ssl_session_timeout 10m;

ssl_prefer_server_ciphers On;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!aNULL:!MD5:!DSS;

ssl_stapling on;
ssl_stapling_verify on;
resolver 8.8.8.8 8.8.4.4 valid=300s;
resolver_timeout 10s;

access_log /var/www/wpcademy.com/logs/access.log;
error_log /var/www/wpcademy.com/logs/error.log;

# php-script handler
location ~ \.php$ {
fastcgi_index index.php;
fastcgi_pass 127.0.0.1:9000; fastcgi_read_timeout 150;
root /var/www/wpcademy.com/public_html;
fastcgi_param SCRIPT_FILENAME /var/www/idroot.us$fastcgi_script_name;
include /etc/nginx/fastcgi_params;
}
location ~ /\.ht {
deny all;
}
}

Step 5. Set Up Let’s Encrypt SSL Auto Renewal.

We will add a cronjob to run the renewal command every week, run this command:

export VISUAL=nano; crontab -e

Paste the following lines:

01 1 * * 0 /usr/bin/certbot renew >> /var/log/ssl-renew.log
06 1 * * 0 /usr/bin/systemctl nginx reload

Save and Exit from the crontab table.

This will create a new cronjob that will be executed every Sunday at 01 AM, and then it will reload Nginx web server to apply the changes. The output will be logged into /var/log/ssl-renew.log file for further analysis if needed.

Congratulation’s! You have successfully installed Let’s Encrypt. Thanks for using this tutorial for installing Let’s Encrypt SSL on CentOS 7 system. For additional help or useful information, we recommend you to check the official Let’s Encrypt web site.