Change left image alignment right in WordPress

Some time ago I noticed a certain disorder in the alignment of images from one of my blogs, so some images were adjusted or aligned to the right, and others to the left. This, of course, in most cases does not have any incidence. However, if we want to have a pattern on our blog, a definite style criterion can help us. Sometimes, at the time of making a change of subject, we also sold a change in the alignment of images, but how to do it?

An infallible method

Changing the alignment of images one by one would be too tedious and even delayed, especially if we have hundreds or even thousands of entries, so the manual method is discarded. What we have to do is write directly on the database in bulk.

However, calm down. Surely many of us do not fully master the commands, or we do not have access or we just do not want to get in hand directly for prevention or fear of spoiling something.

So we can do it (at least that’s what I did) with the help of a plugin. It’s Search & Replace, and its function, as its name says, is to search and replace text strings (including html) from our WordPress blog.

We download and install it and, once this is done, we find several possibilities that it offers us. For what we need we must go to the Search in section and, there, select the Content option.

Then we go down and in the Search for box we introduce some of these criteria:

img class = »alignright»



img class = »alignnone»

Right is right, left is left and center is center. If we want our images to be all left, then we must enter the first option and then in the Replaced with box:

img class = »

And then we also rewrite the images that are in the center and those that do not have any alignment.

As you can see, the question is rather a bit of logic, but above all DE MUCHO CARE. You must bear in mind that, even if you are not in PhpMyadmin, the changes anyway apply directly to the sql database. Even, if you wish, you can make a backup copy of it as a precaution.

NOTE: The quotes should be straight, so it is better to type them in a blog of notes so that they are not altered.

Change left image alignment right in WordPress
Image by WorldSpectrum from Pixabay Are you torn between which kind of...

Sometimes you have a web page and to complement it, you create a presence ...

Google is the world's most famous Internet products and services, software...

Take a look at the network to review how our website always suits us to se...

Bibliography ► (June 26, 2019). Change left image alignment right in WordPress. Bogotá: E-Cultura Group. Recovered from