4 Most Common WordPress Issues and Their Solutions

Common wordpress issues with solutions

When working with WordPress sites, one may find errors made in the early stages of creating.

It turns out that the sites initially have a flimsy foundation, leading at the most unfortunate moment – when traffic is high.

Due to the lack of thoughtfulness of the architecture, some visitors, instead of content, will receive error 500, 502, 503 (there are many of them) or will start to suffer because of slow page loading.

The same thing with writing essays.

Far from everyone is a professional writer and this is where you are stuck but there are custom essays academic writing companies such as shinyessays.com to order essays online.

Liquid Web Managed Word Press

You as a student apply for help from academic writers working for an essay agency providing services on writing papers and even if you are not an english native speaker, there are professionals ready to accomplish your college assignment.

It does not matter what type of a paper you need, such an expert company is ready to provide a great essay and other kinds of service such as editing and proofreading as well.

Blog, store, catalog, forum or photo album – it doesn’t matter, the problem with the speed of opening pages is common.

Therefore, in order not to give a puzzled look and not beat your head against the wall when the pages start opening with a delay of half a minute, or even longer, you need to understand the inner workings of this CMS.

Without understanding, you cannot squeeze all the possibilities out of any product.

SEMrush

WordPress, we have a problem: common WordPress issues

WordPress is one of the best tools for creating websites of any level: from simple blogs to complex online stores and services.

This CMS has many useful functions that, if necessary, can be easily extended with plugins or your own code.

Anyone who is not too lazy to study WordPress Codex will be able to create a website that solves the set business problem with minimal money and time.

It should be understood that WordPress is designed for creating blogs.

The existence of plugins such as WooCommerce for stores and bbPress for forums does not mean that you can create a perfect online store or community using them.

Alas, no plugin changes the core of the CMS, that is, any WP site is still a blog.

Problems are not discovered immediately, but after a while, when the site is filled with content and visitors come.

The exact properties of the critical mass depend on many factors, it is difficult to predict them. It can be 10,000 users per day and 2,000 posts, 20,000 visitors and 100 posts – it depends on the performance of the server, content, program code and much more.

Symptoms: pages start to open with a delay, or some visitors see errors from the 50th series.

So why is the slowdown happening?

Why are WP sites so dependent on the amount of content?

After all, this is an old system, the first version of which was released already in 2003, so it is obvious that some ideas are implemented archaically.

It so happened that the most problematic component is storing content in a database.

There are no problems with photos, styles, fonts and other files stored on disk, but everything related to the database in WordPress works so-so.

Truth be told, there are no truly universal solutions, so you should not scold WP.

Four technical problems with CMS that you will encounter along the way of project development:

  1. Using a small number of tables for completely different content.
  2. Using data serialization where you don’t need it.
  3. Lack of indexes.
  4. Low quality plugins and templates.

The symptom is always the same: slow loading or, as was mentioned above, the spontaneous appearance of errors with codes of the five hundredth series.

If you understand where it is coming from, problems can be dealt with.

1. Content – a lot, tables – few

Sites with a large number of posts (goods, comments – is unimportant) and/or complex headings slow down so that no caching can help.

Page generation is slow due to one weirdness inherent in the core of the CMS.

WordPress has several global variables, functions, and classes that are recommended to be used instead of directly interacting with the database.

You don’t need to know the SQL query language to interact with the database, the CMS takes over the task.

For example, templates often use WP_Query (), an abstraction that makes it easier to work with tables.

Those who need to manipulate the database as they please can always use the wpdb {} class, again without getting into the jungle of the SQL query language.

Databases are good because you can send a specially formulated question to them and the answer will contain only what you need, nothing more.

This saves a lot of CPU time and server RAM. However, not all commands in the query language are fast. And those that work out quickly can always be slowed down by slipping a large amount of data.

The sampling speed depends on the correct structure. In WordPress, the storage structure is quite unfortunate.

Here is the simplest example to explain the essence of the problem. In the WP project database, you will always find two tables:

  1. wp_posts – headers, text, creation and modification dates, ID (unique number) and post type are stored here.
  2. wp_postmeta – post-related metadata is stored here. For example, view counter plugins create lines with the number of pages viewed. Plugins can create dozens of entries, that is, the total number of rows in this table is sometimes many times greater than the number of rows in wp_posts.

By itself, storing text in table cells is the norm. The downside to WP is that additional information is pushed too far.

Belonging to categories and authors, access rights, color and size of goods – everything is stored almost anyhow. This is the fault of both the kernel developers and third-party plugins.

Now let’s look at the task closer to reality. Let’s say your blog’s sidebar displays the Top 5 Popular Articles widget.

Alas, the complexity of the database query increases by an order of magnitude:

“Show me 5 lines from wp_posts, but only so that they are sorted by the” Value “column from wp_postmeta, where the” Post ID “column in wp_posts will match the” Post ID “column in wp_postmeta and the” Property “column will be equal to” Visits ” …

Must Read-  6 Simple Steps To Make A File Upload Form In WordPress

With cross-conditions, the query logic becomes more complicated, and much more.

The database will have to rush back and forth, fetching rows from both tables, sorting them, fetching them again, and so on.

It is not hard to guess that in time it can take seconds or even minutes if the query contains many conditions, and the amount of data is not 10 lines, but hundreds of thousands.

But the reality is much harsher than my primitive examples:

  1. The selection involves additional tables containing the names of categories, tags and their metadata.
  2. New plugins tend to populate the wp_ * meta tables with new rows.
  3. Products, photos, in general, any objects in WordPress are the same posts, they just have a different type. This means that the wp_posts table grows very quickly. And even if they do not participate in the request, their actual presence degrades performance.

The inability to go beyond strictly specified tables prevents the development of the site when it enters the stage of active filling with content.

All design templates can mimic the look of news, message boards and forums, but they will not remove WP restrictions.

One size fits all

The most obvious advice is to tweak the MySQL database server settings (MariaDB, Percona … it doesn’t matter), which will indirectly speed up work with large tables. The MySQLTuner utility will greatly help in selecting the settings.

You can also add indexes, but more on that later (indexes in the database are not a panacea, because when reading is accelerated, writing slows down).

From the side of the code, alas, it is difficult to fix something. In theory, the solution is simple: store different types of posts in different tables.

Since all objects in WP are essentially posts, division into tables based on the type of object will significantly reduce the overhead when fetching data.

Indeed, why are all forum posts, logs, product properties, and billing data stored together?

Why can’t it be done for wp_tovar and wp_tovarmeta products?

The proposal to introduce support for individual tables # 14558 into the WP core was brought up for discussion back in 2010… and immediately closed by the lead developer with the wording:

This is not something we could discuss.

We are happy with keeping custom post types in existing table structures.

We do not recommend adding additional tables – in some installation scenarios this is not even possible.

Peter Westwood, one of the WordPress developers

The disclaimer is understandable: in WordPress, DB-level partitioning is difficult to predict in terms of performance and compatibility with existing sites, plugins and templates.

But, in my opinion, such conservatism is akin to regression, because other CMS do not stand still.

There is another way. Around the same time, there was a discussion # 14513 about a way of linking post relationships on the principle of “many to many”.

As a result, the Posts 2 Posts plugin was born, which, using intermediate tables, made it possible to quickly select posts according to several criteria.

Despite the enthusiasm of the community members, the case stalled, the plugin is incompatible with modern PHP 7.2 and 7.3, work on modern versions of WordPress is not guaranteed.

If you have sufficient knowledge, you can adapt the plugin to modern realities. I’m too lazy to do this.

At the moment, progress in this area does not inspire optimism, because there is none.

Yes, you can work directly with the database, manually create separate tables, but all the “goodies” of WP_Query – convenient sorting and selection, saving and writing metadata – are not available without writing your own WP_Query implementation.

If you have to process millions of entities, perhaps this discussion will push the development of the site in the right direction.

Serialization does not allow data manipulation

Serialization is the conversion of an array of values ​​to one string.

This allows you to push arrays of any size into one cell of the database table.

However, the database does not see the data inside such cells, and accordingly, it cannot select rows by them.

As a rule, serialization occurs when trying to write an array of values ​​to the database.

It can often be seen how plugin and template authors for some reason dump additional post properties like SEO attributes and additional headings into one common variable.

Then it is extracted into a variable to be displayed in the template, and it seems like there is no problem here, but … try to select posts by this property!

The solution – take it easy

When writing your own plugin, always consider easy data extraction. One table cell must store one value.

It is better to create hundreds of product properties via add_post_meta () than to stuff the entire array into one cell.

You should always remember that filtering posts by serialized properties is 5-20 times longer than classic queries.

The exception is storing settings via update_option (). As a rule, they do not participate in any selection, so you can store plugin and template options in a serialized form, if you wish.

But even with the storage of settings, you should not go too far. For example, the WP Memberships plugin, designed to restrict content depending on what product the user has bought, stores content access rules in a single array.

This nuance – that instead of product properties, sets of rules are used – confused the logic of access restrictions too, so working with WP Memberships is difficult.

If you work with other people’s plugins … Well, I’m sorry. Rewriting other people’s plugins is a thankless job.

Usually, in such cases, isolate the key plugin function and implement it yourself to get rid of the original solution.

As a rule, in this case, the site starts to work a little faster, because it gets rid of unnecessary appendages.

No indexes in the database

In an attempt to bypass the limitations of WP_Query (), developers create separate tables for their own needs, but they often do it clumsily. Decisions are extremely unfortunate.

Consider perhaps the worst example ever: the paid ad management plugin AdsPlacer Pro. For his needs, he produces as many as 23 tables:

The largest one – wp_adsplacer_pro_reference_country_ip – stores a list of IP addresses linked to a country and a city. This is necessary to recognize the location of the person who viewed the ad.

Indexes in the database are special structures that allow you to speed up search and sorting by a specific field or set of fields in a table. Indexes are the same as tables of contents in books.

Must Read-  How these 4 Wordpress Plugins Helps you to rank better in Search Engines

If it is not in the book, you will have to read the entire book from the beginning to the right place. With a table of contents, searches are much faster.

And all would be nothing, if only:

  1. There were no indexes in the table (as in some others). That is, the authors did not even think about optimization.
  2. Search in the table worked when loading any page, even if the GeoIP option was disabled.

In fact, the AdsPlace’r Pro plugin, whose reviews are for some reason entirely laudable, actually slowed down page opening by ~ 0.8 seconds on the site where the problem was noticed.

This is a significant delay that negatively affects traffic, as search engines don’t like this slowdown.

The addition of the index helped to reduce the server time to send the page to 0.09 seconds, but the residue remained.

Let’s add the incompatibility with PHP 7.3 due to the use of the PHP library Simple HTML DOM Parser version 1.5 (2008!) And we will get a solution that seems to solve the problem, but does it badly, making it difficult to squeeze the maximum performance out of the site.

In response to my ticket about problems, the authors of AdsPlace’r Pro promised to fix the bugs at the end of 2019 by linking the new version to the release of WordPress without support for old PHP versions.

This is strange, because to solve the indexing issue and thus speed up customer sites at once could be a tiny change in the code.

In general, until version 3.0 is released with the expected fixes, I do not recommend AdsPlace’r Pro for purchase.

How to detect the problem and add the correct index

Hopefully, you read the text above, and did not skip right to this chapter.

You need to understand what exactly slows down, because roughly it is difficult to determine where to create an index. Install and activate the Query Monitor plugin.

Then open the problem page and take a look at the WP admin panel. If the item with the timings is yellow, it means that slow queries to the database are executed during the opening.

If red, PHP errors are present. Errors are a conversation for a separate article, they do not affect the speed. We are interested in slow queries.

Click on the item “Slow queries“. The Query Monitor plugin panel with the “Slow Queries” tab will appear at the bottom of the page. There it will be seen what the slow request prevents from fast opening.

In my case, it was like this for 0.6 seconds:

That is, before giving the page to the visitor, the MySQL database server, in addition to processing fast queries for a few milliseconds, stumbled for one as much as 0.6 seconds.

In the “Component” column, you can see that the similar-posts plugin is to blame. It is responsible for displaying a list of related posts at the bottom of the page, including the one you are currently reading.

The easiest way to get rid of a slow SQL query is when you figure out which plugin or template function is interfering with, disable it / her and enjoy speeding up your WordPress site.

But losing features isn’t always acceptable. Therefore, let’s figure out why the query takes a long time and optimize it.

Open phpMyAdmin or any similar database manager. I like PMA because it’s easy to get to the SQL entry console.

Open it (click on the name of the site database, then on the “SQL” tab) and paste the query copied from the Query Monitor panel, adding the “EXPLAIN” command at the very beginning:

After clicking “Next”, thanks to the EXPLAIN command, you will see the decryption of the request:

In the “table” column – tables participating in the query. If only wp_posts and wp_postmeta are present there, then, alas, you may not read the text in this chapter – you are faced with the slowest kind of complex query, which I described above in problem # 1.

To optimize this, you need to rewrite the plugin / template program code and, perhaps, change the database structure, which is not easy at all.

Fortunately, in practice, a banal lack of a suitable index is to blame for slow page opening.

In the example case, you need to do something with the indexes in the wp_similar_posts table, which is created by the Similar Posts plugin.

The database is a smart system, it independently searches for the fastest way to complete the task.

The column “possible_keys” contains a list of columns and indexes that could be used, in “key” is the column actually used in the query.

In my case, NULL is everywhere – this means that something is wrong with the table, all values ​​are iterated over.

This is indirectly confirmed by the number in “rows” – 2400 – about the number of rows in the table. Scanning each line is a long task.

It is not surprising that the database query turned out to be slow.

To save time, the table should have a column with unique values, preferably an index. By analogy with a book, the column with unique values ​​will be the page numbers, and the index will be the table of contents. Together, they greatly facilitate the search for information.

Poor quality plugins and templates

WordPress is the most popular CMS with an extremely low entry threshold. The system offers customization of behavior through hooks and filters.

Hooks allow you to respond to events like adding an item to the cart, and filters modify objects on the fly.

It’s simple, it’s convenient, but it leaves a lot of room for imagination. It’s easy to shoot in the leg when redesigning a site in such conditions.

Statistically, most WordPress plugins and templates are garbage. Nevertheless, if this garbage solves some problem, then it is popular.

For example, the Ultimate Member plugin is used by over 100,000 sites, although it is a collection of crutches, bugs and vulnerabilities.

Even if the developers made a lot of strange and frankly bad decisions, the plugin will be used.

The low quality of the code is primarily to blame for non-novice developers, who create their own crutch plugins for every sneeze (there is nothing wrong with trying to write code), and the WordPress curators responsible for filling the catalogs of templates and plugins are Automatic employees and volunteers.

In pursuit of quantity, quality has gone somewhere beyond the background.

Universal templates deserve a separate word.

Yes, yes, I’m talking about Divi and other similar templates! Authors, in pursuit of functions, pile up huge script files in which two or three functions are useful for a particular site.

Must Read-  8 Best URL Shortener WordPress Plugins to Shorten Affiliate Links

As a result, such templates quickly and easily create unwieldy pages of tens of megabytes. This is unacceptable even in the era of ubiquitous development of 4G networks – traffic is still not rubbery, and mobile devices tend to burst faster due to excessive computing.

Therefore, be sure to pay attention to the technical optimization of the site. At least press the pictures harder with some script.

How to estimate the number of problems on the site

It is impossible to consider all possible problems. Plugin sets are different, templates are not the same for all. Instead, I will tell you how to estimate the number of existing problems through the debug mode.

To enable debugging in wp-config.php at the root of the site before the line “/ * That’s all, stop editing! Happy publishing. * / “Add:

After that, a debug.log file will be created in the / wp-content directory, in which errors in PHP scripts that occur during the operation of the site will be recorded.

Debug mode slows down the site, so don’t keep it running for long. After evaluating the situation, delete the lines and the file.Then you can act in different ways. If the site does not behave as it should, and during an incorrect reaction, some error is recorded in the debug.log, it is worth fixing it – look at the code, understand the essence of the problem and rewrite the problematic section of the code.

It also happens that there are errors, but visual problems do not appear in any way. This is a common occurrence.

Sometimes the number of errors can go off scale, but the site will continue to work no matter what.

Slower than it could have been, but nonetheless. It all depends on your decision – whether to spend resources on fixing problems or to score.

Leaving the site without maintenance and development

Not that it’s a problem, but it’s necessary to know.

Any site requires periodic investments. Spending is not necessarily monetary: sometimes it is enough to devote an hour a week to correctly update all plugins and check the statistics of visits.

By the way, the increase in the number of visitors is one of the reasons that makes the owners start to worry, because at some point, under load, the pages begin to be given too slowly, which is not pleasant to either visitors or search engines.

So, what are the costs of website owners?

Mandatory, regular:

  • Hosting payment. It can be a super-cheap virtual server for less than a dollar per month from Hostinger, a server for $ 15 per month from Liquid Web, or some kind of shared hosting from Hostgator. There are a lot of options, they have one thing in common – no one will host your site on WordPress for free, you have to pay money. I talked about what kind of hosting can be called good in a separate article “How to choose VPS hosting – a few tips“.
  • Domain name payment. The site needs a name that people will remember and type in the address bar. It is also not a free service, but you can save a lot if you know where to look (“Buying a domain: how to come up with a name, where to buy it cheaper and what to set up”).
  • Service. If the site is hosted on a VPS, then someone will have to update the software. Because vulnerabilities and errors are regularly found in software, you need to switch to more secure, perfect versions. It is easier for shared hosting owners: the server software is updated by the engineers of the company that provides the site for them. In both cases, you need to update WordPress itself, and the plugins for it – there are nuances here, more on them later.

Optional, sometimes one-time:

  • Site installation, design and functionality work. You can download the software yourself, choose a design template from the free ones, install plugins, somehow customize them, and now the site is ready. Budget but workable – that’s the strength of WordPress! However, if you see a site as a source of income, you will not be able to create a site in the “blunder” mode, you need investments.
  • SEO optimization and content filling. Do you want your site to stay on the first lines for search queries? Permit me to regularly fill the site with high-quality texts that are interesting to visitors. SEO is a vast, complex and controversial issue. Its costs are difficult to estimate. If you want to do it yourself, you should at least know about 101 ways to make your website better.
  • Behavioral analytics and UX improvement. Optimization of the so-called UX (User Experience), user experience in our way. No matter how many billions of dollars you have spent on design and functionality, visitors will always do something differently than you expected. And they will always miss something. To smooth out such corners and need continuous work on the site. Most of all, this is required by online stores and sites selling services, where the visitor needs to be brought to a certain action.
  • Advertising costs. Those for whom the site is part of the business may not wait for years until their project gets the first places in the search results, but start advertising their site (or service) on social networks, the same search engines, on other sites with banner advertising, and so on. … A well-tuned advertising campaign can provide the right number of customers, thus reducing the importance of traffic from search engines.

Costs tend to rise over time rather than decline, but if the project is on track, profits will grow faster than costs. It is important not to abandon the site, but to constantly support it with content, increasing functions, advertising and other useful activities.

There`s good news.

In fact, WordPress is awesome. The project has lived for many years, the documentation is detailed, all problems have been discussed and solved a million times (except for organizing data in a database).

The source codes of the CMS and plug-ins are open, you can analyze other people’s solutions and invent the right approach to solving problems.

With the right skill, you can create really cool things with any tool.

All problems are in the heads of those who do not know how to properly dispose of opportunities.

Suggested –

Don't miss out!
Learn How to 10X Your Blog Traffic
Invalid email address
Give it a try. You can unsubscribe at any time.

Rahul Setia was born and raised in the Kaithal, Haryana. He worked at brands like Jabong, ProProfs etc. He was also in the List of Top 100 Social Media Influencer's 2019 by Status Brew. He lives in Delhi/NCR and is a Digital Gig & Founder of Websites i.e TechBlogCorner.com, ViralMasalla.com, DealorCoupons.com. Follow me on: LinkedIn, @rahulsetia007 and Facebook.

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.