Archive

How to Install WordPress with OpenLiteSpeed

Do you know How to Install WordPress with OpenLiteSpeed?

OpenLiteSpeed is a high performant web-server especially for WordPress sites because of LSCache plugin.

A great deal of people are opting for OpenLiteSpeed stack to power and speed up their WordPress site, in this article we will see how you can do exactly that.

Install OpenLiteSpeed:

First of all, we have to know how to install OpenLiteSpeed. To do so we are going to mention all the installation steps here. OpenLiteSpeed installation is very easy. Installation for different Operating systems is different but I will add here installation for Centos and Ubuntu.

Here in this article, we will install OLS from CentOs repositories. The difference in the installation process is just the commands steps and the sequence of steps remains the same throughout the process.

  1. You have to add the repositories in order to install OpenLiteSpeed. Here the commands to add repositories to the centos and Ubuntu.

Centos:

rpm -ivh http://rpms.litespeedtech.com/centos/litespeed-repo-1.1-1.el7.noarch.rpm

Ubuntu:

wget -O - http://rpms.litespeedtech.com/debian/enable_lst_debain_repo.sh | bash

Adding repository is the first step to install OpenLiteSpeed.

2. After adding repositories to the machine now its time to install OpenLiteSpeed. OpenLiteSpeed is just one command install. Here is the Command.

Centos:

yum install openlitespeed

Ubuntu:

apt-get install openlitespeed

By default, this command installs the latest stable version of the OLS. if you want to install any specific version then the command will be

yum install openlitespeed-x.x.x

Replace x.x.x with any version you are required like 1.2.2 or any you need to install. Once OLS has been installed successfully. You OpenLiteSpeed directory is /usr/local/lsws.

3. To start OpenLiteSpeed server use the command

/usr/local/lsws/bin/lswsctrl start

4. To stop OpenLiteSpeed server use the command

/usr/local/lsws/bin/lswsctrl stop
image 35

Configuring OpenLiteSpeed:

In order to set up WordPress on the LiteSpeed server, you have to do some configurations on your server.

For the configuration, we have to access the LiteSpeed Web Server to access the webserver. You can use the port 7080 with your IP address. You can reach the webserver from the following link https://<your_server_ip>:7080. Once you reach this you can see this screen

OpenLiteSpeed

Provide credentials to log in to the webserver. Usually username=”admin” and if you don’t know the password you can change it by running this simple command

/usr/local/lsws/admin/misc/admpass.sh
image 17

After providing the details you can see the dashboard of LightSpeed Web Server.

image 18

Now it time to do some configurations on the webserver. First of all, from this OpenLiteSpeed dashboard find Server configuration on the menu.

image 19

Go to the External App section present in the Server configuration. And you see LightSpeed SAPI App click Edit.

image 20

After getting to the next page by clicking the Edit button. Now you have to do some configuration according to the PHP version that you have. This is important because OpenLiteSpeed installation won’t be able to correctly execute PHP Scripts. So we have 7.3 We will do configurations according to our version. By default there is lsphp but we have to make it lsphp73. 73 is for my PHP version you can do it for your own version.

We have to correct three things Name, Address and Command according to our version.

image 21

Once you edit these go and save these settings.

Now its time to edits some Virtual Hosts settings. To do so go to the Virtual Hosts section from the left menu.

image 22

You can see an Example Virtual host on the screen view this for some configurations.

image 23

In the Example virtual Host go to the General Tab. And click the edit button. These are some Configurations that are important for WordPress.

image 24

In order to install and setup WordPress, we are going to create a directory WordPress in the next steps so in Document Root we add this. OpenLiteSpeed looks at the contents of the Document Root field for content to serve.

image 42

Once you done click save.

In LightSpeed by default, there is only index.html file as index file but for WordPress, we will need index.php also because its core file for WordPress and This will allow the main logic of WordPress to function correctly.

To do so in General tab go to the index files and click to the edit.

image 26

Add the index.php file also in index file with index.html. and save

image 27

Now we have to do some setting on rewrite rules for this go to the Rewrite tab in the Virtual Host window.

image 28

In Rewrite Enable Rewrite and Auto Load from .htaccess. Make these option yes. And click to save.

image 29

Now we are going to take a look on some security options. As OprnLiteSpeed installation includes some Password protected areas for the authentication features. And we know that WordPress uses its own authentication mechanisms and we will not going to use file-based authentication by Openlitespeed. So we have to remove these so WordPress works properly on its own.

To do so got to the Security tab in the Virtual Hosts option.

image 30

At the end of this screen, you can see a Realm List which has a SampleProtectedArea. Click on the Delete button to remove it.

image 32

It will ask you for confirmation click the Delete button and go on.

Now you have to delete the protectd from context. Go to the Context tab. Here you find /protected/ click delete and delete it.

image 33

Once all done now its time for  Graceful Restart in order to configure all changes we made. To do so click the restart button on the top of screen.

image 34

Now your OpenLiteSpeed is fully configured and good to go.

Installing MySQL

As we know that WordPress uses MySQL. WordPress needs MySQL to store and manage its data. So in order to install WordPress On OpenLiteSpeed, we must have the MySQL installed on the server. Go to the terminal and check the installation of MySQL to check this type of command

mysql -v

This will show you the version of MySQL. If MySQL is not installed there then it will give you MySQL command not found. You have to follow the process.

  1. Download and add the repository
wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm
sudo rpm -ivh mysql-community-release-el7-5.noarch.rpm

2. Install MySQL as usual.

sudo yum install mysql-server

3. Start the service

systemctl start mysqld

Now you have to log in to the MySQL root account. to login to the root access type the command:

sudo mysql
image 36

Now we are going to create a database using this command:

CREATE DATABASE webssite DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;

The name of the database is whatever you want to use but here we used “website”. Now we have to create a user how has all rights for this database. You can specify a username and password according to your choice.

GRANT ALL PRIVILEGES ON webssite.* TO 'user'@'localhost' IDENTIFIED BY 'password'; 

Now FLUSH PRIVILEGES which tells the server to reload the grant tables and put your new changes.

FLUSH PRIVILEGES;

Now exit from mysql.

exit;
image 37

Installing PHP Extensions:

We need to install different PHP extensions and modules in order to run and fulfill the required result for our WordPress Site. Here we mention some of the modules and will install them for PHP 7.3 Installation is the same for every PHP version jus the change of version in command.

Centos:

yum install lsphp73-common lsphp73-curl lsphp73-imagick lsphp73-imap lsphp73-json lsphp73-memcached lsphp73-mysql lsphp73-opcache lsphp73-redis

Ubuntu:

apt install lsphp73-common lsphp73-curl lsphp73-imagick lsphp73-imap lsphp73-json lsphp73-memcached lsphp73-mysql lsphp73-opcache lsphp73-redis

LiteSpeed Repository installs PHP unber /usr/local/lsws/lsphpxx

These are some extensions like redis, mysql, imagick, etc you can also install any other if you wan to.

image 38

Installing and Configuring WordPress:

Now we have to discuss the installation and configuration process of WordPress with the OpenLiteSpeed. We are done with Server configuration and now we are on the installation. You can download the latest version of WordPress from the there official site. You can download WordPress and any directory. I created a directory “mywebsite“. Create the directory using the following command:

mkdir mywebsite
image 39

Go to that specific directory that you created to download WordPress. Use the command cd “your_directory”.

Now its time to download WordPress. You can do it using a command and the command is stated here:

curl -O https://wordpress.org/latest.tar.gz

If you want to download any specific version. Go and get the proper link for that proper version. Now extract the compressed file that you downloaded.

tar xzvf latest.tar.gz

Now your directory look like this:

image 40

Now for the OpenLiteSpeed we have to create a file before going to further process. OpenLiteSpeed Support .htaccess files. this is so important for us to create this file to go for the next steps because WordPress managed and create permalinks using this file. for this purpose, we will use touch command. Here is the whole command to create the .htaccess.

touch /root/mywebsite/wordpress/.htaccess

You can add the path where your WordPress is on the server.

One more important file for the WordPress Installation is the wp-config.php file. All the configuration of WordPress depends upon this file. Whenever we download this file from there official website this there will be a sample file like wp-config-sample.php. for this setup, we are going to copy that sample file into the wp-config .php file to use it. And will configure it. We are going to do it using a command you can do to with any other method too.

 cp /root/mywebsite/wordpress/wp-config-sample.php /root/mywebsite/wordpress/wp-config.php

You can see we have .htaccess and also wp-config.php on our server now.

image 41

For the safe side, we are going to create an upgraded directory so WordPress will not run into permission issues while updating. A very simple command is used for this:

mkdir /root/mywebsite/wordpress/wp-content/upgrade

Always check you changes that you made. Now its time to move the WordPress content to the place from where we can access this. As you remember that we added the path for our WordPress site in the OpenLiteSpeed in the virtual host-> Example -> root document.

We have to move this in /usr/local/lsws/Example/html/mywordpresssite

Now here I mention the command to move my WordPress content to that specific.

cp -a /root/mywebsite/wordpress/. /usr/local/lsws/Example/html/mywordpresssite

This is the command for specific my setup. And also note the “.” in the command. This will copy all the hidden files also.

Now its time to do some critical configuration for your WordPress to be working. We have to do some permission configurations and wp-config.php configuration the most important. First of all, we will go for the permissions of files. We are going to set nobody user and nogroup to the group. OpenLiteSpeed web server runs these as default and gives the ability to read and write these.

Use these command to do so. incase of centos this one will work:

sudo chown -R nobody:nobody /usr/local/lsws/Example/html/mywordpresssite

In case of ubuntu this will work

sudo chown -R nobody:nobody /usr/local/lsws/Example/html/mywordpresssite

Now in the next step, we have to find two more permission sets. We have to specify the permissions for files and directories. First, we are going to set permission for the directories for that we will use

sudo find /usr/local/lsws/Example/html/mywordpresssite/ -type d -exec chmod 750 {} \;

Set permissions to 750 And for files permissons we use:

 sudo find /usr/local/lsws/Example/html/mywordpresssite/ -type f -exec chmod 640 {} \;

These permissions are required and suitable for the process and the proper functionalities properly.

Now we all done with the permissions part now we have to set set up wp-config.php. We copied the content of the sample file in the wp-config file. So we have to add some real value in order to word the wp-config properly. In the default file, you can see that they ask you for real value now we have to generate these values.

image 43

We can do so from the official API of WordPress for these use this command:

curl -s https://api.wordpress.org/secret-key/1.1/salt/
image 44

Once you run this command you will receive value like these. Copy the value from the terminal and replace these values in the wp-config.php file I am going to do this from the terminal using vi editors.

You can use this command to do so on your end:

vi /usr/local/lsws/Example/html/mywordpresssite/wp-config.php

this one is default one and have to replace with real values.

image 45

After updating with real values it look like.

image 46

The configurations for keys are now set up and now we have to set up database configurations in the wp-config.php file.

You remember the Database you created and the user for that. Now we have to add these in this file.

image 47

Now in this default configuration now we will add out real values in it.

image 48

All done for the wp setup. Its time to open and launch the final site.

Install WordPress with OpenLiteSpeed

Setup WordPress

Now we will go to the last WordPress Setup. First of all, you have to know how you can access your WordPress to setup. Be careful in this process. You can open your WordPress installation through your IP or server domain but check the firewall may in my case I was able to open the site on port 8088

http://<ip_address>:8088
WordPress

Here the process is started for installation. You have to select your language and click Continue.

Here you have to provide the required information. Username, Password, Site tile, and Email after providing all these clicks to the Install WordPress button.

Install WordPress with OpenLiteSpeed

You will receive the confirmation screen for the process.

image 51

Click to the login button and provide the detail to login.

image 52

After login, you can visit the admin dashboard and do whatever you want to.

image 53

Now you can do any operation regarding your site from here. Add any plugin, posting, and anything you want to do.

Benchmark of WordPress Site with LS Cache:

At the last, we are also going to check the benchmark for the WordPress Site with and without ls cache. In this way, we can evaluate how LS Cache effects the site. First, we will see the results without LS Cache and then we enable LS Cache and see the results. we are going to use h2load for performing benchmarks. You can visit here to check how to install it.

For the benchmark, we chose a fixed value which we are going to use after and before the LS Cache installation.

h2load -n10000 -c100 -m10 https://mydomain.com/

We are going to use this command that means we have three parameters here:

-n The number of total requests. we are going with 10000

-c The number of concurrent clients. we are going with 100

-m The max concurrent streams to issue per client. we are going with 10

Benchmark without enabling LS Cache

image 54
starting benchmark…
spawning thread #0: 100 total client(s). 10000 total requests
TLS Protocol: TLSv1.2
Cipher: ECDHE-RSA-AES128-GCM-SHA256
Server Temp Key: ECDH P-256 256 bits
Application protocol: h2
progress: 10% done
progress: 20% done
progress: 30% done
progress: 40% done
progress: 50% done
progress: 60% done
progress: 70% done
progress: 80% done
progress: 90% done
progress: 100% done
finished in 1.61s, 6195.49 req/s, 154.30MB/s
requests: 10000 total, 10000 started, 10000 done, 10000 succeeded, 0 failed, 0 errored, 0 timeout
status codes: 10000 2xx, 0 3xx, 0 4xx, 0 5xx
traffic: 249.06MB (261158611) total, 120.81KB (123711) headers (space savings 96.91%), 248.42MB (260490000) data
min max mean sd +/- sd
time for request: 27.77ms 287.59ms 113.67ms 56.38ms 77.80%
time for connect: 175.54ms 317.87ms 206.94ms 43.20ms 83.00%
time to 1st byte: 205.29ms 438.45ms 287.47ms 71.38ms 66.00%
req/s : 62.07 106.24 77.41 16.47 76.00%

Benchmark after enabling LS Cache

image 55
[root@cyberpanelubuntu ~]# h2load -n10000 -c100 -m10 https://shoaibkhankhattak.tk/
starting benchmark…
spawning thread #0: 100 total client(s). 10000 total requests
TLS Protocol: TLSv1.2
Cipher: ECDHE-RSA-AES128-GCM-SHA256
Server Temp Key: ECDH P-256 256 bits
Application protocol: h2
progress: 10% done
progress: 20% done
progress: 30% done
progress: 40% done
progress: 50% done
progress: 60% done
progress: 70% done
progress: 80% done
progress: 90% done
progress: 100% done
finished in 1.40s, 7117.72 req/s, 177.27MB/s
requests: 10000 total, 10000 started, 10000 done, 10000 succeeded, 0 failed, 0 errored, 0 timeout
status codes: 10000 2xx, 0 3xx, 0 4xx, 0 5xx
traffic: 249.06MB (261156355) total, 118.61KB (121455) headers (space savings 96.97%), 248.42MB (260490000) data
min max mean sd +/- sd
time for request: 22.52ms 190.04ms 94.97ms 32.20ms 66.87%
time for connect: 146.85ms 303.13ms 194.98ms 47.78ms 77.00%
time to 1st byte: 192.92ms 410.21ms 272.01ms 68.73ms 67.00%
req/s : 71.36 132.70 91.69 21.77 77.00%

Now you can see the difference between the both results.

Read More: HOW TO CHANGE TIMEZONE ON LINUX SERVER

Follow US on Facebook / Twitter  for update.

How to enable full/advanced WordFence protection on OpenLiteSpeed

Website security is always a fundamental and important part of any website especially WordPress. Today we will see how to enable full/advanced Wordfence protection on OpenLiteSpeed.

If you are using LiteSpeed Enterprise you don’t need to do anything as it is fully Apache compatible so Wordfence full protection will work out of the box. So you can stop now and enjoy your coffee.

However, if you are using OpenLiteSpeed then go ahead, make sure to use OpenLiteSpeed with CyberPanel, and ease your life.

What is WordFence?

Wordfence is one of the most popular WordPress scanner and firewalls. Wordfence comes in both free and premium versions. Wordfence has enough features to secure your websites like endpoint firewall, malware scanner, malicious IP addresses detection, 2FA, and all. In short, Wordfence is the most comprehensive WordPress security solution available. Wordfence is enough to secure your site.

Why do we need to configure OpenLiteSpeed for full Wordfence protection?

Setting up WordFence is a bit tricky in the case of OpenliteSpeed. With OpenLiteSpeed, you have to do some manual settings. In this article, we will discuss how to configure Wordfence with OpenliteSpeed to enable advanced firewall options.

Enable full Wordfence protection on OpenLiteSpeed:

  1. Install Wordfence on your WordPress site.
  2. Edit Vhost Configuration for Wordfence.
  3. Enable full Wordfence protection with CyberPanel.

Install Wordfence on your WordPress site:

The installation of Wordfence on your WordPress site is just like the installation on any plugin. Follow along the steps to install Wordfence.

Setp 1: Install Wordfence Plugin:

To install WordFence on your WordPress site first log in to your admin dashboard:

Go Plugins->add New

advanced wordfence protection on openlitespeed

Now search Wordfence in the search bar, You will receive the results for Wordfence select the first one (The one with the Wordfence logo) and Click install.

image 64

Setp 2: Setup Wordfence Plugin:

Once installation is done click Activate to activate the plugin:

image 65

After activation, they will ask you for an email address where they sent you emails regarding your website. Provide your email, click yes if you want to receive emails, check the box for agreement and press continue.

image 67

If you have a premium version enter the key here otherwise click on thanks and use the free version.

image 68

Now your Wordfence is installed and good to go. You can see the Wordfence on the left menu. When you click that you will see a notice to configure full/extended Wordfence protection.

image 69

Once you click the configuration a prompt appears that asks to download the .htaccess file. Click on download and press continue.

image 70

In the case of LiteSpeed Ent. configuration is done out of the box but in the case of OpenLiteSpeed, we’ve to perform some additional steps that we will discuss below. I found an official video guide for you to install Wordfence you can check that also.

Edit Vhost Configuration for Wordfence:

For OpenLiteSpeed you have to configure the Wordfence to enable Advanced WordPress Protection. Without setting these configurations to OpenLiteSpeed you can see that there is the Basic WordPress Protection.

image 71

To enable the advanced protection you have to access the OpenliteSpeed web server dashboard by navigating https://<your_ip>:7080. In the OpenLiteSpeed web, server Dashboard go to the VHost -> General

image 72

Go the end of page you will find the php.ini overwrite click the edit button.

image 73

add this to php.ini overwrite

php_value auto_prepend_file /path/to/wordfence-waf.php

Most Common path if you created site from cyberpanel

php_value auto_prepend_file /home/example.com/public_html/wordfence-waf.php

If you added the domain with CyberPanel then first you have to find the path of the wordfence-waf.php file. After adding this graceful restart the OpenLiteSpeed with this server did not get the changes.

image 74

Once done go back to your WordPress site and check the firewall you can see the Extended Protection level there.

image 75

Instead of doing this from the OpenLiteSpeed, you can install CyberPanel on your OpenLiteSpeed server, and then there is an easy way to do this. I will describe that in the next step.

Enable advanced firewall with CyberPanel.

When you have the CyberPanel installed on your server to manage your site you can follow the guide stated above but in this part of the article, I will tell you a simple way to do this using CyberPanel. To enable an extended or advanced level of protection using CyberPanel, you have to log in to CyberPanel using your credentials.

From you CyberPanel Dashboard go to the Websites ->list websites

image 76

You can see all of your websites there Click on the Manage button. To open the website dashboard.

image 77

Once the manage Dashboard for the web site is opened go to the configuration part and click the VHost

image 78

Go to the php.ini section

image 79

Add the following line to enable the extended protection.

php_value auto_prepend_file /home/example.com/public_html/wordfence-waf.php 

Now your extended protection is enabled .

image 81

Follow US on Facebook / Twitter  for update.

How to Speed up Your Site via Cloudflare Page Rules for HTML

HTML is one of the most important aspects with regard to the speed of your webpages. If we cache HTML it will reduce the usage of resources and improve the performance of the site. Caching HTML is very useful in a site performance perspective. You know that Cloudflare usually caches all static resources which has also a great impact on site performance. Like CSS, Javascript, images, and all. But what about HTML?, so in this article, we are going to explain how to make HTML caching work with WordPress and Cloudflare Page Rules

HTML caching is called full page cache it is not a default cached code from the Cloudflare we have to create rules for this. So what we need to do so let see.

Required Features for HTML full page caching

Page Rules

As I already stated above that by default, Cloudflare is not caching HTML. to do so we need to use page rules and have to enable the cache everything setting. This means you enable the caching of HTML by making a rule that cache everything. But to do this there is a problem and you have to take care of these two factors while making page rule for HTML.

  1. The HTML content for which you are creating the rules has to be static. In simple words, it does not change over time. Like a dynamic front page.
  2. The second thing the content is anonymous. This means that it is the same piece of content that is intended for any visitor to this resource.

These all thing shows that Caching everything is not engough for the setup.

Cache Everything

Cache Everything means you cached everything even the content not needed to cache. When you cache everything this will be a risk. Maybe you cache those content that is not intended for the next visitor. Let me explain with an example if you are login as an admin in WordPress dashboard and visit your front page and you cached everything, literally everything. Then the next visitor who is a normal visitor who accesses the site will see the admin edit bar that only was intended for you. So to not get stuck in this type of stuff you need to do and other things and that is to Bypass Cache on the Cookie setting.

Bypass Cache on Cookie

A cookie is a small piece of data stored on the user’s computer by the web browser while browsing a website. To login to a website, cookies are needed to maintain a link between your local computer and server. A cookie from your local computer, it is sent with every request you make to the server. This means that you can tell the server to pass the request through to the origin server, given the user has a certain cookie. With this enabled, you can deliver cached responses to Anonymous visitors, while you as an Administrator, or a logged-in customer in your WooCommerce, are getting served a tailored HTML page that will not be cached. In this way you have to do so you will not face the everything cache problem.

Always chose a best and correct plan to do this.

Configure Cloudflare for HTML caching for WordPress

Caching HTML is one of the important and critical issues. Keep in mind that when you are going to leverage Cloudflare for the HTML caching, always reduce the number of plugins you are using for caching, Optimization, aggregation, and all that. The use of more plugins makes it complex and complicated. Made the thing harder to resolve and understand. maybe they also cause a conflict. And I honestly tell you that caching with Cloudflare is more efficient and worthy. There’s nothing more annoying than trying to debug cache issues on a CDN. A visitor would report some error, and when you test this hitting another CDN node the results could be entirely different.

Now its time to setup page rules for html. To do so follow the steps.

Setting up the Cloudflare Page Rules

In order to process the different requests from Cloudflare, you need to set up different rules for it. The first-page rule that matches the incoming request is the one that will be applied. 

To add Page rule go to Page Rule

image

Here is some configuration, These are some basic configurations for a WordPress site.

Cloudflare Page Rules

Explanation for these Cloudflare Page Rules:

Now let’s explain these rules we provided above. These three rules are different and have there own importance according to there values.

1: Enable Cache for all requests going to anything in the folder wp-content. And this rule includes all the themes and plugins all.

2: Now I think you got it for which contains the second rule is. Yes, it is for all requests from the wp-. This rule bypass the cookie. This makes it possible for you to log in wp-login.php, and work in the admin wp-admin/* without running into caching issues. When you log in to the Control Panel, you will get the no-cache cookie

3: This third rule is for the whole website. All the rest requests. I didn’t set the bypass cache on it you can set for this.

This is for a stranded WordPress site but for a woocomerce site you need some other rules as well.

Additional required Cloudflare Page Rules for WooCommerce:

As you know the woocomerce site is very different from the normal site and there is a huge difference between the caching of woocomerce and a normal blog site. Although the basic rules for woocomerce are the same it need some additional rules for this purpose. These rules are specified for specific paths of sites. Like checkout, cart, etc. I will show you some rules.

Cloudflare Page Rules

With the rule mentioned above, you can also use these two rules for your woocomerce site. The checkout often involves multiple steps, therefore the checkout wildcard rule is used to bypass the cache. and also the cart.

In this article, we will go for some other details but first, we have to know how we can purge cache in cloudflare.

Purge cache in Cloudflare

Purge meaning clearing cache in Cloudflare. Sometimes you need to clear the cache in order to visible changes and getting some new content. Purging cache is different in Free and Enterprise plans. I will discuss here the method. For the free version, we have Purge by single-file (by URL).

Purge by single-file (by URL):
  1. Login to Cloudflare
  2. Select the site you need to purge
  3. Go to the Caching from the top menu.
  4. In the Purge Cache pane, click Custom Purge.
Cloudflare Page Rules
  1. Select URL in the Purge by field.
  2. Enter the appropriate value(s) in the text box
  3. Perform any additional instructions to complete the form.
  4. Review your entries.
  5. Click Purge.
Cloudflare Page Rules

The purging for Enterprized is different from the free plan. Follow the guide to do so.

You can do more customization of Cloudflare Page Rules

Different sites need a different type of setup because they have a different type of requests. All sites are different, and there are usually certain paths and requests you’d like to exclude from caching. Both plugins and themes sometimes require customization. Also, API requests are generally not something you’d like to cache.

Including and excluding the content is specific for every site and you have to do it according to that specific site. there are some extra settings like Edge cache TTL, Browser cache TTL, Origin cache TTL you have to take care of these for caching.

Edge Cache TTL:

Edge Cache TTL is used to tell the Cloudflare how long to keep the asset in the cache. We can say that this is an edge of time to keep the data in the cache. Let say we want to keep the cache for a month or more then we set that limit for the cache. Usually, it depends upon you I mean the user. How long you are using the same content and when you want to change it. Read more about this here.

Browser Cache TTL:

Browser cache is special. You can set these using page rules. Unless specifically set in a Page rule, Cloudflare does not override or insert Cache-Control headers if you set Browser Cache TTL to Respect Existing Headers. It cannot be cleared by clicking a button. The only way to bypass the browser cache is to force-reload a page (which will make the browser reload the page from the server) or let it expire. The upside of the browser cache is that it is the cache closest to the users – so it will make HTML load in just fractions of a second because it doesn’t require any network traffic.

If you want to know more about it and want to know how to set up click here.

Origin Cache Control:
These are used for CND. These Cache-Control headers are one way for web administrators to tell Cloudflare how to handle content from the origin. This is a very nice feature for advanced users, that know how to manipulate headers and instruct the Edge cache using headers.

Read more about Origin Cache Control here.

How To Solve The Redirection Error Of Your Hacked Website And, How To Get Back Your Hacked Website

Follow US on Facebook / Twitter  for update.

How to solve the redirection error of your hacked website and, how to get back your hacked website

Are you facing a redirection error? Your site is redirecting to some spam URLs? When you want to access your site and suddenly you see that your site is navigating to somewhere else. Do you want to solve the redirection error? Honestly, I can tell you that it’s a very hard and time-consuming process to find where the issue is. It does not happen automatically its often happens when some hacker gains access to your site and adds spam URLs in parts of your website. In this article, I am going to explain the solution to this redirection issue from my personal experience. After following this guide you will be able to solve your issue but I will share my experience so maybe you can solve your error by following this guide. I will tell you the whole of the situations I faced and how I solved it.

A new client who wanted to shift his sites to Cyberhosting told us that one of his sites is facing redirection issues and he is not even able to gain access to the WordPress admin dashboard. Before telling you the whole store I will state some points which are maybe the cause of the redirection issues.

  1. Outdated Plugins
  2. Change URLs in the Databases
  3. Default themes files
  4. WordPress Files
  5. General settings URLs

I would like to start one by one the problems encountered and tell you how I solved the problems that I faced. Honestly, speaking that the main part is to find where is the problem. Once you get that 80% of the problem is solved (From my point of view may be in your case your view is different). Now I am going to tell you the whole story of problems and solutions with intervals 🙂 .

Infected Database Problem:

When i face this problem for the first time. It was very complicated at that point I was unable even to gain access to the WordPress admin dashborad. Its very tough to know the reason if your first problem is accessing the WP_ADMIN. In this case I decided on a brief check before going into deep analysis of files and searching for the problem there. One of our team members suggested to me to check the database and it was here in the WordPress setting that I discovered the URLS have been changed. So, your first question is where are the URLs in the database? I am going to tell you the way to check and solve the issue.

How to check and solve the Database issue:

First of all, you have to know where to access your database. If you are familiar with the PHPMyadmin in your control panel and know how to access then you can leave this part and access the database of your WordPress which you need to fix. Otherwise, stay with me and follow the guide. Here I will tell you how to access the database in CyberPanel. if you have any other panel go and search for the access process.

How to access database using PHPMyadmin in CyberPanel

Its very easy to access PHPMyadmin in CyberPanel. (Easy for me may be hard for you ). First of all go to the Database->PHPMyadmin.

solve the redirection error

You will see this screen which asks you to provide the credentials to login provide.

image 4

But what if you don’t have the credentials to log in. Actually, when I was investigating I also didn’t have the credentials to log in. But wait don’t worry I will tell you from where you can get the credentials to log in. Go to the file manager and edit the wp-config.php file here you can find the username and password to log in.
Once you logged into the PHPmyadmin go and find the table wp-options tables.

image 8

And check the home URL and site URL if they are not the same as your site and showing some else like me you have to replace these to your original site. I followed this process to solve the issue for the first time. I found it there and solved it using this process. Maybe in your case, the issue is different and you have to follow this guide to the end.

image 9

Default Theme files Issue

Again on that site after few days this issue happened again. First thing I did was to go back to the database and check the link but, surprise, everything is fine there. Now it’s a big task again to find the issue. I try to access the Admin dashboard of that WordPress site. and happy to know that it’s working. I logged in to the Dashboard and now begin to check other settings for or features, now you want to know-how.

How to check infected files through admin dashboard and resolve

I have the wordfence plugin installed on that site and I scan for intrusions. This scan took a long time to complete but the scan showed some high risk files in the default theme. I proceeded to remove the files from the scan and replaced these files with the default files for the theme. This resolved the issue and it is a solution that worked for me. But maybe in your case both solutions mentioned above do not work in which case go to next steps.

General Settings URL problem:

I found that after solving the problem with the database, as mentioned above, I was able to access the WordPress admin dashboard but after scanning the site using wordfence I was still unable to access the site. After checking the general setting of the website I found the URL of site had also been changed there.

I changed the URL of sites and after that it works. But I must say it is an extreme case. When your security is too low only then it will happen otherwise it is unlikely.

Unknown Problem (Plugins + database + files everything is changed)

I shared my experiences above about the problems that I faced on the site of client and how I solved this. But this is not it. After all these problems I still faced a final problem which took 2 days to resolve. The same client came back to us informing that his site had been hacked again. I wonder why his site had been breached yet again? But the first thing to do is to recover the site back to normal. I start working on his site I go for the database and check link links have again been changed so I use the method above to fix that, then I visited the site it’s still not working with the same redirect issue. Then I will do toward admin dashboard and start a scan, check the general settings and all that but the result is still different from the past. After doing all these I am still not able to get the site operating as normal. Then I decide first to know the reason of hacking site.

How to find the reason of hack:

There are some points that I followed to check site and maybe you cannot find the reason this way. But this is one method that you can try.

First of all I go to the plugins section of the client site and check. I discover that he has a lot of outdated plugins and most of them have available updates. I realise I have found the reason for the continued breach but what to do? how can I find the exact plugin which is insecure, changed or which is helping the hackers to breach the site. Wordfence was also not able to scan these files. May be there are a lot of infected files, too many for wordfence to report? I decide to go for a wpscan from my terminal.

Scan with wpscan

First I installed wpscan on my server and then go for the scan. I found that there are many infected files. His outdated plugins are infected. When I receive a result from terminal I go for those files and replace them with original one I got from the official sites of plugins. Or the files I already have for those plugins.

After the scan I replaced those file but not done with that I also replaced the wordpress file with original files. Let me explain exactly how to do this.

How to replace WordPress files with original files?

This is a tricky point and will be difficult for a beginner. First thing is to find you WordPress version.

Go to the file manager then public_html folder then wp-includes folder. Here you found a file name version.php. Open this file and you can see the version of WordPress that is installed.

Download the WordPress for this specific version from there official site click here to download. Download the version which is installed on your site.

image 7

After downloading upload this to your public_html folder of your site and replace it with your old files.

After doing all these i go to the site and check site is working.

Finally the problem has been resolved and I am happy to share my personal experiences on this with you guys. May be this will be helpful for you in order to solve your problem. Please let me know if you are able to solve your problem in comments. If this article didn’t help or you are unable to understand anything thing ask me.

Read More: HOW TO CHANGE TIMEZONE ON LINUX SERVER

Follow US on Facebook / Twitter  for update.

Migrate WordPress Site using Migrate Guru complete guide

Moving a website from one place to another place can be a difficult process. The main difficulty during this task is the risk of losing data. this article is about Migrate WordPress Site using Migrate Guru. WordPress is one of the most used CMS and the process of migrating a WordPress site from one place to another is now made easy with the use of different plugins and techniques. A WordPress website consists of files and a database, both of which need to be set up to talk to each other in the correct way.

Migrate Guru is a plugin that makes the migration of the site from one server to another very easy. Migrate Guru will transfer a site quickly, requires minimal knowledge. You did not need to worry about any database, data, and files loss. In this article, we mention Migrate WordPress Site using Migrate Guru

Table of Contents

  1. Installation Of Migrate Guru
  2. Migrate Guru Features
  3. Setup on Remote Server
  4. Move Website using Migrate Guru

Installation Of Migrate Guru

You can install Migrate Guru from the WordPress admin Dashboard, Plugin section. And also you can install it manually. We mention both methods below.

Install Automatically:

  1. Go to the Plugin section on WordPress admin Dashboard.
  2. Search the Migrate Guru in search box.
  3. Click the install button and activate to use.

Install Manually:

  1. Search Migrate Guru in any search engine or click here.
  2. On this page click Download button and download the zip of plugin
  3. Upload this plugin in plugins and active it.

Migrate Guru Features:

Fast One-click Migration

Using Migrate Guru you can move your site quickly and with one click. Let you have a 1GB of the site you can clone or migrate it less than 30 minutes. Just enter host details and click ‘Migrate’. If you entered the details right it will be done in just a few minutes.

Compatible with almost every Web Host

Migrate Guru has a large number of web Host option. Move your site from and to any web host.

Migrate WordPress Site using Migrate Guru

No Overload On Site

When you start the migration of your website the plugin will monitor the server resources ensuring that it does not overload until the site migration is completed.

Built For Large Sites

Migration Guru works for large sites. Move or clone sites as large as 200 GB in a breeze. Large site migrations usually fail because of live-site server import limits.

No Space Required

You do not need any extra space for migration. Migrate Guru automatically copies your site to our servers. After the migration is complete, the copy is erased.

Fully Automatic, Built-in Search

Comfortably handle serialised data with accurate Search & Replace.

Timely Alerts

Sit back. Relax. Our real-time & email alerts will keep you up to date with the website migrate status.

Setup On Remote Server

There are some steps to do on the remote server before doing migration.

Create your Site:

Before transferring the site first create the site on required server with the same name and credentials. Once your site is created move to next step.

Install WordPress

Install WordPress on the newly created website. Complete the setup of WordPress installation. Fellow the video guide to complete the setup.

Move Website using Migrate Guru:

Fellow the steps to move your site:

After installing Migration Guru plugin click on the migration guru in the left menu you can see dashboard

image 50

Provide Email and agree the agreement. After providing all information click on the Migrate button.

image 51

Select your host from all these host listed on the screen.

image 52

For this tutorial we are using FTP to transfer site. Provide the required information in the from.

image 54

After providing all this information click the migrate button.

image 55

if all information is true you can see the migration process.

image 56

After successful migration of site you can see the screen showing success massage. and also you will receive a email regarding the completion.

image 57

Wonderful And Creative Uses of PHP

PHP is one of the most popular programming languages that is used for web development. Mostly used for dynamic programming and server development. PHP was originally created by Danish-Canadian Canadian programmer Rasmus Lerdorf in 1994. There are many wonderful and creative uses of PHP for its users.

Php Stand for Hypertext Preprocessor. In this article, we will discuss some wonderfully uses of PHP That make your site more useful.

Table Of Contents:

  1. WordPress Theme Development
  2. Image Processing And Generations
  3. Content Management Systems
  4. Server-Side Backend Code
  5. Write Your Own Script Code
  6. WordPress plugin development
  7. Integrate AMP
  8. E-commerce Development
  9. Cyber Security and Authentication
  10. Real Time Applications

WordPress Theme Development

Uses of PHP

WordPress is a free and open-source CMS written in PHP. WordPress is one of the most used CMS. Over 1.3 billion websites are using WordPress. This popular CMS use themes and plugins to manage the users’ data.

With the popularity of WordPress Demand for WordPress themes also increased. There are a large number of WordPress themes on different platform of WordPress like Theme Forest.

PHP plays an important role in the development of the WordPress theme. All files with .php extension in WordPress theme code are PHP code files.

WordPress theme development do not need any expert level PHP understanding you can start with a basic knowledge.

Server-Side Backend Code

Server-Side Backend Code

Web development is often divided into two parts like front-end and back-end. Front end is basically the users interface. What a user can see.

Basically front end is practice to convert the data in visuals. Using different programming languages and techniques. Like HTML, CSS, JavaScript, React, Angular etc.

Backed is the part which is not accessible for the user, typically responsible for storing and manipulating data. But it enable a website to function properly.

There are many tools, techniques and languages that are use to develop server side back-end.

PHP is one of the most popular among them. PHP is used to develop and build server-side back-end systems. PHP performs very well in back-end techniques and processing.

Content Management Systems

Content Management Systems

A content management system is a system that is used to manage digital content, allowing multiple contributors to create, edit and publish.

PHP is the most popular platform to create CMS. There are many CMS built using PHP. Like WordPress, Drupal, etc. There are many online resources with them you can start building CMS from scratch.

WordPress plugin development

WordPress plugin development

If you are working with WordPress you must know about the WordPress Plugins. There are large number of WordPress plugins present in WordPress plugin repository and on plugins site. These plugins are free and pro versions.

Like theme development if you have basic knowledge of PHP you can develop plugins.

There are verity of WordPress plugins like plugins for Woocomerace, Page builders, Cache Plugins, etc.

Image Processing And Generations

Image Processing And Generations

There is a library called GD. Using this library with PHP, you can output images in different file types like jpeg, png and gif. This feature is very useful. You can create thumbnails, crop pictures, resize pictures, and if you want to create a photo gallery you can do it.

You can create different formats of images with just few lines of code.This thing is very useful and helpful for front-end.

Write Your Own Script Code

Write Your Own Script Code

PHP scripts are usually use for back-end. But you can use script for other cases too like make a script for email list. you can send a notification by using PHP script. These are some wonderful uses of PHP scripts.

You can also run PHP scripts using command line interface (CLI).

Integrate AMP

Integrate AMP

Accelerated Mobile Pages (AMP) is basically use to optimized for mobile web browsing and intended to load web pages faster. AMP reduce website load time on mobile.

In this Amazing technique PHP helps to improve the loading speed. And this load speed helps site to improve ranking. It also effects the SEO.

E-commerce Development

E-commerce Development

One of the most important role of PHP is its use in e-commerce. Design and develop a e-commerce website from scratch is very tough and time-taking process. Even integration of an existing e-commerce system with new system is also a tough process.

But if you are an expert of PHP you can easily find a solution for this problem, Creating from scratch or integrating existing one.

There are many existing PHP Frameworks for e-commerce. By using that you can easily done your work. There is no need to write code from scratch instead use a PHP framework.

PHP frameworks such as Cake PHP, Symphony, Laravel, Code-igniter are of great help to developers.

Cyber Security and Authentication

Cyber Security and Authentication

Now the most important thing for any site is its security. According to a survey On average 30,000 new websites are hacked every day. An other report say that “Above 60% companies faced web-based attacks”.

Hacker are always try to find some way to hack any site and get data access. PHP is very useful for this. it is a great language that helps you to combine cyber security on your website.

The setup of Cyber security mechanism with PHP development tools helps to prevent ongoing frequent cyber attacks.

User authentication is one of the most important aspect of web security. Almost every site need to implement user authentication. there are a large number of techniques which are used for the implementation of user authentication.

Using PHP for this propose is very common and preferred way. PHP can easily store and retrieve username and password pairs on a database, using top-level encryption. You can also use different encryption techniques.

Real Time Applications

Real Time Applications

Now there are huge amount of real time applications. We can see the real time web application like chat, web games, monitoring systems, social media applications, networks, etc.

Developers develop real-time applications using different tools, techniques and technologies, Like React js, HTML, Node js, Angular, Express, CSS, and others.

PHP is also one of the most used platform in real time application. Some very popular real time application are developed in PHP.

Basically PHP is used to develop back end for real time applications. Now a days Node js is one of the popular technology for back-end but in some case it can not useful as PHP is.

Read More: HOW TO CHANGE TIMEZONE ON LINUX SERVER

Follow US on Facebook / Twitter  for update.

Top WordPress Page Builder Plugins

WordPress is one of the most popular content management system (CMS). Now more than 60 million websites are using it. WordPress offers many themes and plugins to manage their websites. WordPress Page Builder plugins are also available for WordPress which makes the designing of a website easy.

Using a WordPress page builder anyone can make and edit their website according to their choice. Even a non-technical person can do it without any programming or designing skills.

There are many page builder plugins for WordPress. Here we discuss the most popular, user-friendly, and easy-to-use plugins. Which are also available for free.

Table of Contents

  1. Elementor
  2. Divi
  3. Beaver Builder
  4. Page Builder by SiteOrigin
  5. WP Page Builder
  6. WPBakery Page Builder
  7. Nimble Page Builder

Elementor:

Elementor is one of the best WordPress Website Builder powered by Elementor.com. Elementor is available in Free and Premium versions, with over 5 million active installs. You can create beautiful sites and pages using a drag and drop interface.

Elementor has a large list of powerful features that enable you to build your website quickly and easily.

WordPress Page Builder plugins

Elementor Features:

Drag and Drop Editor

Elementor plugin allows simple drag, Drop, and customize editing. This has one of the fastest and easy editors in WordPress.

300+ Designer Made Templates

Elementor has more than 300 built-in templets. You can choose from them and use them. It has almost a templet for a very kind of industry.

90+ Widgets

There are more than 90 Widgets for users. Buttons, headings, froms, and other like them. Youc can easily choose and use them.

Responsive Editing

Responsiveness is the backbone of your site. Elementor plugin allows responsive editing ti its users. Switch to mobile view, and tweak every element to make it look perfect on any device.

Popup Builder – Pro

The popup builder feature is only available in the pro version of the Elementor plugin. It allows users to create perfect popups. It also includes many advanced targeting options.

Theme Builder – Pro

This feature is also for the Pro version only. By using this feature you can edit each and every part of your site without code. Its like making your own theme.

WooCommerce Builder – Pro

This paid feature take control over your WooCommerce online store by utilizing the power of Elementor.

More Features of Elementor

Click More Elementor Features

Pricing Plans

image 38

Divi

Divi is one of the best WordPress Website Builder. According to the Divi website, Divi takes WordPress to a whole new level with its incredibly advanced Visual Builder Technology. Divi makes building websites for your clients so much easier, faster, and more enjoyable.  You can create beautiful sites and pages using a drag and drop interface.

Divi has a large list of powerful features that enable you to build your website quickly and easily.

image 44

Divi Features:

Drag and Drop Editor

Like Elementor plugin Divi also allows simple drag, Drop, and customize editing. It allows you to add, delete, and move elements around on the front end of your website.

True Visual Editing

Divi allows visual editing to its users. You can design your page in real-time and see the results instantly. Create and customize your pages using intuitive visual controls.

Inline Text Editing

Inline text editing is one of the important features for any site and Divi provides it for its customers. Just click and start typing! Editing your page has never been this easy. Draft pages on the front end and see the results instantly as you type.

Responsive Editing

Divi plugin allows responsive editing ti its users. Building beautiful responsive websites is easy. Divi is responsive by nature and also gives you full control over how your website looks on mobile devices.

Undo, Redo, & Revisions

Nowadays Undo, Redo is the basic functionality that almost every new program provides. Divi works like a modern software application. Easily undo, redo, and travel through your entire editing history. If you make a mistake, Divi has your back.

Custom CSS Control

Divi allows custom CSS for its user. So developers easily combine and modify CSS. Divi’s visual design controls with their own custom CSS. Divi’s interface is simple yet not limiting.

Design Options Galore

Enjoy dozens of unique page elements and thousands of design options. Divi gives you full design control over your website.

More Features of Divi

Click for more features

Pricing Plans

1 License. Complete Access. Unlimited Websites. Unlimited Users.

image 39

Beaver Builder

Beaver Builder is a drag and drop builder for WordPress. Beaver Builder has about 1,000,000 websites. Beaver Builder is a flexible WordPress plugin that uses for the frontend editing of websites without any code.

Use Beaver Builder and Make a stunning website  Whether you’re a beginner or a professional.

image 45

Beaver Features:

Live, Front End Editing

Beaver Builder provides live editing on the front end of your page. Live work gives you real-time output on the front end. What you see is what you get! No more guesswork.

Shortcode and Widget Support

Sometimes we need to add shortcodes and widgets to our pages. Beaver Builder supports shortcodes and widgets so you can use your other favorite plugins. Want to use Ninja Forms or an Easy Pricing Table? We’ve got you covered!

Reusable Templates

Every layout you create can be saved and reused an unlimited number of times to quickly build new pages.

Responsive Editing

Responsiveness is the backbone of your site. As long as you’re using a responsive theme, any page built with Beaver Builder will be totally responsive.

Theme Builder – Pro

This feature is also for the Pro version only. By using this feature you can edit each and every part of your site without code. It’s like making your own theme.

WooCommerce Support

Beaver Builder also provides woocommerce support. Beaver Builder plays great with WooCommerce. It’s never been easier to design a storefront.

More Features of Elementor

Pricing Plans

image 40

Page Builder by SiteOrigin

SiteOrigin Page Builder is a popular page creation plugin for WordPress. It allows page building using many widgets, Content, Button, and other things.

A large number of WordPress users are using this for page creation on their site.

image 46

Page Builder by SiteOrigin Features:

Compatible with Theme:

This plugin is compatible with every WordPress theme. It’s not a commitment to a single theme or theme developer. The advantage is that you’re free to change themes as often as you like. Your content will always come along with you.

No Coding Just drag and drop

Like all other, this plugin also allows drag and drop. Page Builder’s simple drag and drop interface means you’ll never need to write a single line of code. Page Builder generates all the highly efficient code for you.

Live Editing

Page Builder supports live editing. This tool lets you see your content and edit widgets in real-time. It’s the fastest way to adjust your content quickly and easily.

Row and widget styles

Styling is also an important factor for any site design. Row and widget styles give you all the control you need to make your content uniquely your own. Change attributes like paddings, background colors, and column spacing. You can also enter custom CSS and CSS classes if you need even finer-grained control.

More Features

Pricing Plans

This plugin is free and always be free. Just install activate and use it.

WP Page Builder

WP Page Builder is a free WordPress Website Builder powered by  Themeum.com. You can easily design, and use your site using this plugin on WordPress. WP Page Builder is a free and completely front-end based tool with plenty of design options.

image 47

WP Page Builder Features:

Drag and Drop Editor

WP Page Builder enables you to edit your website on the frontend and see the output in real-time. You can use the ready-to-use elements, create simple to complex layouts, and bring different styles to a website in minutes. It’s superbly easy to create and design pages or edit existing ones with this WordPress page builder’s drag and drop system.

Undo and Redo Option

Like all modern applications, this plugin also allows undo and redo options. The best thing about this feature of plugin that you can undo and redo as many times as you want there is no limit for this.

Font styling and colors

This plugin also helps in typography and colors for the website.  Plenty of IcoFont and Font Awesome font icons are available to use with this WordPress page composer plugin. You can utilize any of the 340+ IcoFont line icons and 670+ Font Awesome icons on your site.

Responsive Editing

No matter how many rows and columns you take on a single page, it will have no issues with responsiveness. WP Page Builder ensures 100% responsive layouts and eye-catching look at the same time. Using the device-specific responsiveness controls, you can render the pages as on different devices (computers, tablets, mobile phones) while editing, and make necessary changes for the perfect responsiveness.

Built-in Blicks

With this plugin, you will get many blocks for your page. These blocks are already present in the plugin. There’s a wide variety of readymade section elements in this web page builder to accelerate your site-building process. Save time in designing sections just by dragging and dropping the readymade section elements of your choice!

More Features of Elementor

Pricing Plans

This Plugin is free and it is free for a lifetime. it has also some paid versions which have extra features.

These are the Annual plans

image 41

These are lifetime Plans

image 42

Nimble Page Builder

Nimble Page Builder is a fast and agile page builder plugin for WordPress powered by Press Customizr. This plugin allows live customization, darg and drop, widgets and all these thing. Nimble Builder uses native WordPress action hooks, which makes it compatible with all WordPress themes.

image 48

Nimble Page Builder Features:

Drag and Drop Editor

This plugin allows simple drag, Drop, and customize editing. This has one of the fastest and easy editors in WordPress. Drag and drop neatly pre-designed sections and customize them in a real-time preview.

Compatible with any WordPress contexts

The plugin works for home, Pages, Posts, custom posts, types, archives, and every other context of WordPress.

Embed Shortcodes 

Nimble page builder allows you yo add shortcodes and use them for your side anywhere.and see the result in a real-time preview.

Responsive Editing

Responsiveness is the backbone of your site. The plugin allows responsive editing ti its users. Switch to mobile view, and tweak every element to make it look perfect on any device.

More Features

Pricing Plans

it is a Free plugin available on plugin section of wp-Admin.

Move a WordPress Site with the Duplicator Plugin

The process of moving a site from one server to another is a very important and difficult task. The main risk during site migration is Downtime. Which can happen with the possibility of data loss? In this article, we will explain how to move a WordPress site with the Duplicator plugin.

This will allow you to move your site from any other platform directly to CyberPanel or other control panels.

Table Of Contents

  1. Duplicator Plugin Setup
  2. Export site using Duplicator Plugin
  3. Setup site on the new server

Duplicator Plugin Setup:

Duplicator Plugin gives WordPress users the ability to copy, move, migrate, or clone any WordPress site. You can easily copy, move, and transfer your website from one server to another. You can also move your site from local to live server direct. First, we need to know how to install and set up the Duplicator plugin on our site.

Install Duplicator Plugin:

Duplicator Plugin is a free WordPress plugin. And available to install in the Plugins section of the WordPress Admin Dashboard. There are many ways to install WordPress plugins. Follow these steps to install the Duplicator plugin.

Install from Plugin section:

To install the plugin directly from the WordPress plugin directory. You have to visit the WordPress admin Dashboard then ‘Plugin’->Add New.

move a WordPress site with the Duplicator plugin

After clicking the Add New button. Here you have to find the duplicator in the search box. And you will get the first result of your desired plugin. Click Install Now to install this plugin.

image 26

Once the plugin is installed, it is time to activate the Duplicator plugin. Press the Activate button to activate.

image 28

Once you activate the plugin you can see Duplicator option in the menu section of Admin Dashboard.

image 30

Export site using Duplicator Plugin:

Once you’ve installed the Duplicator plugin, it’s time to prepare your site for migration. Follow these steps to move your site using the plugin.

You can see the Duplicator plugin in the left-side menu.

Now click on “Duplicator > Packages”. You can see this screen.

image 31

Its time to start the process. Click the ‘Create New‘ button.

image 32

After clicking Create New, you will be given 3 options:

  1. Setup
  2. Scan
  3. Build

1-Setup

You have four options during set up phase.

  1. Name: (Give the Name to make a file).
  2. Storage: (You can select where to save the file).
  3. Archive: (Check Archive files).
  4. Installer: (See the settings for installer file).
image 33

After checking them all, click on the Next button for the next step.

2-Scan

In the next step, you can see the scanning for export.

image 34

After the scan is complete, you will need to check its status and click Yes to build.

image 35

3-Build

After completing the build phase, you can see this screen.

image 36

From here you can get one-click download or archive and installer two files.

Setup site on the new server:

After the successful download of the installer and archive or .zip file. Now it’s time to move the site to another server. Follow the steps to do so.

Upload Installer and Archive File:

Upload both installer and archive files to your server. Always upload your file to the public_html folder of your site. You can upload using an FTP account. In the case of CyberPanel, you can also upload files from the File Manager in Website Manager. Follow the tutorial below to upload using FTP.

http://help.dugeo.com/m/faq/l/175136-how-to-upload-to-our-ftp-server

Install WordPress Website Using Installer

Now, it’s time to run the installer setup on your server. To do this, you need to go to your website address /installer.php at the end. Like www.abc.com/installer.php

If everything is fine up to this step, the next step is the extraction of the Archive file.

Extract the Archive

After visiting the installer page, you will see a screen like this:

extra archive

Click the Next button to proceed after checking the options.

Database Setup

Now create a database to transfer your site. Follow the database creation process.

Run the Installer

The Duplicator plugin works best with empty databases. Hence, before moving forward, you need to remove all previous data.

Next, the database window will open. You need to check the checkbox named tables to select all the tables in the database. Next, click the Drop button to remove the selected tables.

cloudways database

Click the Yes button.

install database

Data Replacement

Once you reached the 4th step click the YES button, you will be given a URL, Path, and Title automatically.

image 37

Now, click the Next button.

Test the Live Site

If it all works, you’ll see “Step 4 of 4: Test Site”. There you’ll want to click the “Site Login” button, and log in to your WordPress site using the same username and password as you have on the remote site.

step 4: download

Join our Affiliate Program and get bonus.

Read More: HOW TO CHANGE TIMEZONE ON LINUX SERVER

Follow US on Facebook / Twitter  for update.

How to Setup Rank Math SEO Plugin On a new site?

Rank Math is an SEO (Search Engine Optimization) Plugin. Rank Math is one of the most powerful and popular SEO plugins for WordPress sites. In this article, we will discuss how to setup Rank Math SEO Plugin on a new site? We will briefly discuss the method for installing and configuration of Rank Math SEO Plugin. Read all steps carefully.

Table Of Contents:

  1. About Rank Math SEO Plugin
  2. How to Install Rank Math
  3. Configuration For Rank Math

About Rank Math SEO Plugin:

Rank math is one most used SEO plugin for WordPress. Rank Math helps your content to reach the top position in Search Engines. Rank Math SEO has some exclusive features like:

  1. Easy to Follow Setup.
  2. Clean, & Simple User Interface.
  3. Google Crawl Errors
  4. Automated Image SEO
  5. XML Sitemap

TO read more Rank Math features click Here.

How to install Rank Math:

Installation of Rank Math Plugin is very easy. Like all other WordPress plugins, there are several methods to install Rank Math Plugin on your Website.

  1. Install Directly From the plugins Section.
  2. Upload on-site from local computer
  3. Upload from FTP.

Install Directly From the plugins Section:

You can directly install Rank Math plugin by visiting ‘Plugins’->Add New from the WordPress Admin Dashboard.

Setup Rank Math SEO Plugin

Once you click the ‘Add New‘ button you can see the screen present below. Search Rank Math in the Search box.

image 1

When you search for Rank Math you can see the result. the first result of your search is the required one. (Remember the logo and By sections may be searching ranking will be different in future).

image 2

Click the ‘Install Now‘ button After installation Click the ‘Activate’ Button.

image 3

Once you Press activate button its time to configure your Rank Math SEO plugin.

Upload on-site from local computer:

Download Rank Math SEO plugin from its official site click here. In this Link, you find a Download button as shown in the screen below.

image 4

After completion of the download. Now you have to visit your WordPress admin dashboard. And go to the Plugins section and then ‘Add New‘.

image 5

Click on Add New and you can see the Upload Plugin button on the top of the screen.

image 6

Press this upload button and choose the file you downloaded from the Rank Math official site.

image 7

Once you select the file you can see the Install Now option. Install and Activate.

image 9

Upload from FTP:

You can also upload this File using your FTP account. follow the Guide.

Configuration For Rank Math:

Once you successfully installed Rank Math SEO plugin after activation you can see this screen. Here the Configuration begins.

image 10

Here you ‘Connect Your Account‘ click that to processed.

Connect Your Account

In the next screen see the Login option you can log in using your Google Account, Facebook Account, and your Email. (No preference on this login with the method of your chose )

image 11

After login, you can see the activation massage on your screen press the OK button to reach the next step.

image 12

All done for activation its time to ‘Start Wizard‘.

Run Wizard:

The actual configuration and setup of Rank Math starting from this Part. Wizard has serval steps:

Getting Started:

Rank Math has three types to start with Easy, Advance, and the custom.

image 13

If you have a pro version you must go with custom but for Free version, we will go with Advance option. Select the Advance one and Start Wizard.

image 14

Your Site:

In this step, you have to define what really your site is a Personal Blog, Community Blog, News Site, Personal Portfolio, etc. Select according to your site description.

Add a logo for Google AND Default Image for Social media(If any post didn’t have a featured image that will automatically appear in the post).

image 15

Save and Continue for next step.

Search Console:

Get Authorization code using this tutorial

image 16

Save and continue to next step.

SiteMaps:

In this step check all option turned them all.

image 17

Save and continue to next step.

Optimization:

Turn on the features according to your requirements.

image 18

Noindex Empty Category and Tag Archives

Setting empty archives to noindex is useful for avoiding indexation of thin content pages and dilution of page rank. As soon as a post is added, the page is updated to index.

Nofollow External Links

Automatically add rel="nofollow" attribute for external links appearing in your posts, pages, and other post types. The attribute is dynamically applied when the content is displayed, and the stored content is not changed.

Open External Links in New Tab/Window

Automatically add a target="_blank" attribute to external links appearing in your posts, pages, and other post types. The attributes are applied when the content is displayed, which does not change the stored content.

Almost done with settings of Rank Math. Click on the Advanced Options button to see the last setting.

image 20

Role Manager:

The Role Manager allows you to use WordPress roles to control which of your site users can have edit or view access to Rank Math’s settings. Turn it on if you want this feature for your website and press save and continue for the next step.

image 21

404 and Redirections:

The 404 monitor will let you see if visitors or search engines bump into any 404 Not Found error while browsing your site.

Redirection Set up temporary or permanent redirections. Combined with the 404 monitors, you can easily redirect faulty URLs on your site, or add custom redirections.

Turn them on so if any page is not found it will redirect Automatically.

image 22

Schema Markup

Here you have to set your schema for the website. You can choose schema type for the post, schema type for a page, Article type, etc.

image 23

Your setup completed. Now you can see the Rank Math Dashboard.

image 24

If you want to make any changes or add any module you can do it from Rank Math Dashboard.

Join our Affiliate Program and get bonus.

Read More: HOW TO CHANGE TIMEZONE ON LINUX SERVER

Follow US on Facebook / Twitter  for update.

How to setup WordPress Multi-Site on CyberPanel

A multi-site setup for WordPress enables the end-user to create multiple WordPress sites from the WordPress dashboard. Each site with-in a WordPress network acts as a separate WordPress installation and can be managed from a single dashboard.

This feature is provided by WordPress to ensure that its users can easily create a network of sites without digging too much into server-side problems.

In this article, we will describe how to setup WordPress multi-site network using CyberPanel and then issue Wildcard SSL for multi-site operations.

Table of Contents:

  1. Setup Catch all vHost
  2. Things to do before enabling Multi-Site on WordPress
  3. Configuring WordPress to allow Multi-Site
  4. Create/Install a Multi-site Network
  5. Configuration of Multi-site setup
  6. Create a new site on Network
  7. Setup wildcard SSL on multi-site

1. Setup catch All vHost:

The first thing to do before setting up multi-site is the setup of Catch all vHost. Catch all vHost is the must thing to do before enabling the multi-site configuration in WordPress. A multi-site setup is not possible without the setup of Catch all vHost.

The method for catch-all vHost is different for LiteSpeed Ent and OpenLitespeed.

Setup catch all vHost for LiteSpeed Ent:

Open your vHost file from the website manager and edit this line

ServerAlias www.abc.com
wildcard SSL

Change this to

ServerAlias *.abc.com

Setup Catch all vHost for OpenLiteSpeed:

The setup for OpenLightSpeed is very different from LightSpeed. Follow the steps to do this:

Open “/usr/local/lsws/conf/httpd_config.conf” via command line or using an SFTP software.

image 25

Once you open this file find the Listener Default portion for port 80 (HTTP). It look like:

listener Default{
map example.com example.com
address *:80
secure 0
}

Now if you want to set up catch-all vHost for example.com, change the map line to following:

listener Default {
map example.com example.com, *.example.com
address *:80
secure 0
}

After this portion similarly you have to edit the listener SSL by default it looks like:

listener SSL {
map example.com example.com
address *:443
secure 1
keyFile /etc/letsencrypt/live/example.com/privkey.pem
certFile /etc/letsencrypt/live/example.com/fullchain.pem
............
............
enableStapling 1
ocspRespMaxAge 86400
}

Edit this file add *.example.com on the last of this portion:

listener SSL {
map example.com example.com,*.example.com
address *:443
secure 1
keyFile /etc/letsencrypt/live/example.com/privkey.pem
certFile /etc/letsencrypt/live/example.com/fullchain.pem
.........
.........
enableSpdy 15
enableStapling 1
ocspRespMaxAge 86400
}

vHost Configuration for OpenLiteSpeed:

After editing httpd_config.conf file (/usr/local/lsws/conf/httpd_config.conf) you need to open vHost option from Website Manager and edit vHost.

Default vhAliases

vhAliases www.$VH_NAME
image 26

Edit vhAliases to:

vhAliases *.$VH_NAME
image 27

2. Things to do before enabling Multi-site on WordPress

There are a few things you need to do before enabling and using Multi-Site on WordPress. Here are some key points:

Backup your full single website:

Always make a backup of your whole site (files and databases) before creating a network. this is an important step so you don’t lose your data and files.

Pretty Permalinks

Check and verify the pretty permalinks work on your single WordPress site.

like: https://wordpress.org/?p=1

image 11

Deactivate Plugins

Deactivate all WordPress plugin before the creation of the network. And activate again after creation.

Go to Plugins->Active and then click on the deactivate button present below every plugin name as shown below in the picture.

image 12

3. Configure Allow multi-site setup

To allow the multi-site setup or network setup you have to check your wp-config.php file on your file manager of the website and add this code to that file.

define( 'WP_ALLOW_MULTISITE', true );

wp-config.php file is present in public_html folder of site.

image 13

4. Create/Install a multi-site Network

After enabling multi-site mode from wp-config.php file now you can see a new option under the tools tab in wp-admin.

Before enabling multi-site network from wp-config.php file.

image 14

After enabling the mode.

Multisite On WordPress

Now go to this new option Network setup in the tool menu. You can see this screen.

image 16

In this screen the first note is for the pretty permalink.

You can select the option. Your sites will be subdomains or subdirectories in the network.

Sub Domian:

subdomain is a domain that is part of a larger domain. A domain-based network in which on-demand sites use subdomains. Like if our domain is “www.abc.com” then “site1.abc.com” or “site2.abc.com” are your subdomains.

Sub Directories:

Note: This does not require setting up catch-all vhost.

A path-based network in which on-demand sites use paths. Like “www.abc.com/site1” or “www.abc.com/site1” are subdirectories.

Use can set network titles according to your choice also provide the network admin email. and after that click on the install, button to process.

5. Configuration of Multi-site setup

Once the network installation is complete. Setup shows a screen which has code for the configuration of wp-config.php and .htaccess files. Copy these lines of code and paste into wp-config.php and .htaccess files accordingly.

image 17

Copy the lines of code and add these to the wp-config.php and replace the second lines of code and replace all these with .htaccess file present in the public_html folder.

After editing these files must log in again to the wp-admin. So you can see the changes on the dashboard. You can see these two new options on your dashboard.

image 18

6. Create new sites on Network

To create new sites Go to the My sites->Network admin->Dashboard option from the top bar of wp-admin.

image 19

When you visit this option you can see a different type of dashboard on your screen.

image 21

To create a new site visit Sites->add new option.

image 20

After clicking the add new button. A screen appears that requires information about your subdomain or subdirectory. As I selected subdirectory its look like:

image 22

In the case of sub domain it look little different.

Once you click the add site button you can see the Dashboard and edit site button on the top of the page.

image 23

You can access the site Dashboard or edit newly create site from here.

7. Setup wildcard SSL on multisite.

For a multi-site setup, we can use the wildcard SSL. Once you create a wild card SSL you have no need to create SSL for every sub domain as WildCard SSL will cover all subdomains.

Create wildcard SSL

Create a wild card SSL for your network using this command on the server terminal.

/root/.acme.sh/acme.sh --issue -d <youdomain.com> -d '*.<youdomain.com>' --dns dns_cf --cert-file /etc/letsencrypt/live/<youdomain.com>/cert.pem --key-file /etc/letsencrypt/live/<youdomain.com>/privkey.pem --fullchain-file /etc/letsencrypt/live/<youdomain.com>/fullchain.pem

CloudFlare File configuration

After creating that wildcard ssl its time to edit information in dns_cf.sh file present in “/root/.acme.sh/dnsapi” directory.

Replace the CF_Key and CF_Email by your key and email. Also, remove # Singh to active them.

CF_Key="sdfsdfsdfljlbjkljlkjsdfoiwje"
CF_Email="[email protected]"

You can also Use CF_token for this process.

Fellow this guide to check CF_Key or generate CF_token.

https://support.cloudflare.com/hc/en-us/articles/200167836-Managing-API-Tokens-and-Keys

Read More: HOW TO CHANGE TIMEZONE ON LINUX SERVER

Follow US on Facebook / Twitter  for update.