Presslabs development guidelines

Developing on our Presslabs platform is no different than developing on a regular WordPress website if you keep an eye on a few caveats. Make sure you are familiar with software development good practices on distributed systems.

We consider software version control to be the central point of good software development. For this reason, we use the Presslabs-provided Git repository as the source of truth when it comes to a website’s code.

Find out more about Git-driven development, development – stage – production environments basics and benefits of dev sites on our blog .

For more information on how to access your site’s source code, database and media files, check our Access section .

Feature Development and Deploying

From the WordPress perspective, it’s recommended to develop features as separate plugins and to keep ONLY the things which are related to formatting and displaying content inside the theme.

From the git perspective, it’s recommended that you keep each feature as a separate branch.

There are many articles around the web about git workflows, but there is one we’d like to mention in particular. Briefly, you should have branches for each feature, and after you ended testing you merge that branch with master.

Debugging

You can debug and look for errors using the error log console in the Logs section of our Managed Hosting Dashboard. Fatal errors give you a request_id which you can look up in the error log. Also, the PHP function error_log logs directly to the console.

For debugging purposes, we recommend the following plugins:

  • Query Monitor - monitors any queries that your pages generate, load times and resources;
  • Rewrite Rules Inspector - for inspecting your rewrite rules
  • What The File - adds an option to your toolbar showing you which files and template parts are used to display the page you’re currently viewing
  • Crontrol - allows you to create new cron jobs, as well as edit, delete and immediately run any cron events.

Since social media sites are today’s go-to channels for sharing content, make sure you check out our tips and tricks for using the Facebook Debugger .

How to install or update a plugin or a theme

Installing a plugin is a task as easy as it can be. Simply install it from your WordPress dashboard and activate it. However, things don’t always go so smooth and plugin installs can lead to significant site slowness, conflicts with another plugins, even put your site down. Being so many plugins out there, there are also not so well coded plugins that can lead to security exploits, so installing a plugin is a serious matter. To avoid such vulnerabilities, you should keep your plugins up-to-date.

For these reasons we suggest you to follow this workflow when installing or updating plugins and themes. You will need a development site to test the plugins first, if you don’t have one, contact our support team at support@presslabs.com and we will set up one for you in no time.

Step 1: Sync you dev site

To properly test the plugins on your dev site, it need to be a replica of your live site. We offer the possibility to sync your dev site with the live site form the Managed Hosting Dashboard with a simple click.

Step 2: Install or update plugins/themes on the dev site

Now you can proceed and install or update your desired plugin or theme. Test how it behaves on your site and that it does not affect your site’s functionalities: from WordPress core features like updating a post to other plugin’s functionalities and also the design of your site.

When you try to install a plugin you might see a Presslabs notice that does not allow you to install the respective plugin. This is because we have in place a list of banned plugins on our platform for various reasons, from caching plugins (we have our own cache system) to plugins that affect you site’s peformance or have security risks.

Step3: Install or update plugins/themes on the live site

If everything goes right, you can install or update the plugin/theme on the live site as well.

In case there are problems, you will need to identify and fix them. You may need to get in touch with the creators of the plugin or drop us an email at support@presslabs.com if the problems seem related to our dashboard.

Useful Plugins

Regarding image optimizations plugins, check our blog articles: WordPress Image Optimization Plugins that Actually Work and Hottest WordPress Image Optimization Services Compared .

We also debate the Pros and Cons of Comment Systems for WordPress Sites .