What Are The Disadvantages of Using WordPress for a Programming Blog?

Question
What are the drawbacks of using WordPress when you want syntax highlighting for code in your blog?

Answer

1. When you paste PHP code, it will disappear. In Weebly for example, you can paste PHP code and there will be no automatic elimination of it. In Weebly, the PHP code remains as text. You have to get used to this. WordPress is clearly more flexible and mature than Weebly, but some of your drafted posts need to be cut and paste into a "code" block rather than a default text or "Paragraph" block in WordPress. It is easy to specify a "Paragraph" block, you just have to remember to do this. This text below is an example of what it looks like when you use the "code" block option (which is built in and not a plugin, so it is natively supported):

<?php
exec('bash /var/www/html/testScript.sh');
?>

The three lines above would be eliminated in a "Paragraph" block without any warning to the person creating a new post.

2. The syntax highlighters usually (or always) require the Gutenberg plugin. This plugin can be slow and have other drawbacks.

Here are two external blog postings which discuss the negative aspects of Gutenberg:
https://nachtimwald.com/2019/01/01/wordpress-gutenberg-editor-is-garbage-if-you-need-to-post-code/

Leave a comment

Your email address will not be published. Required fields are marked *