<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:media="http://search.yahoo.com/mrss/"
>

<channel>
	<title>Wordpress &#8211; Wade Tregaskis</title>
	<atom:link href="https://wadetregaskis.com/tags/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>https://wadetregaskis.com</link>
	<description></description>
	<lastBuildDate>Fri, 21 Jun 2024 17:50:13 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	

<image>
	<url>https://wadetregaskis.com/wp-content/uploads/2016/03/Stitch-512x512-1-256x256.png</url>
	<title>Wordpress &#8211; Wade Tregaskis</title>
	<link>https://wadetregaskis.com</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">226351702</site>	<item>
		<title>cloudinit breaks connections from localhost to Plesk-operated web servers</title>
		<link>https://wadetregaskis.com/cloudinit-breaks-connections-from-localhost-to-plesk-operated-web-servers/</link>
					<comments>https://wadetregaskis.com/cloudinit-breaks-connections-from-localhost-to-plesk-operated-web-servers/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Tue, 23 Jan 2024 01:03:08 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Meta]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Broken Link Checker]]></category>
		<category><![CDATA[CDN]]></category>
		<category><![CDATA[cloud-init]]></category>
		<category><![CDATA[curl]]></category>
		<category><![CDATA[Nginx]]></category>
		<category><![CDATA[Plesk]]></category>
		<category><![CDATA[Plesk Obsidian]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://wadetregaskis.com/?p=7491</guid>

					<description><![CDATA[I don&#8217;t know how or why it is even installed &#8211; perhaps part of the provided Ubuntu image from my VPS host &#8211; but cloud-init (a.k.a &#8220;cloud-config&#8221;) is a bit obnoxious. At [re]boot time (best I can tell), it resets /etc/hosts based on some random template it has (/etc/cloud/templates/hosts.debian.tmpl in my case, even though that&#8230; <a class="read-more-link" href="https://wadetregaskis.com/cloudinit-breaks-connections-from-localhost-to-plesk-operated-web-servers/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[
<p>I don&#8217;t know how or why it is even installed &#8211; perhaps part of the provided Ubuntu image from my VPS host &#8211; but <a href="https://github.com/canonical/cloud-init" data-wpel-link="external" target="_blank" rel="external noopener">cloud-init</a> (a.k.a &#8220;cloud-config&#8221;) is a bit obnoxious.  At [re]boot time (best I can tell), it resets <code>/etc/hosts</code> based on some random template it has (<code>/etc/cloud/templates/hosts.debian.tmpl</code> in my case, even though that makes no sense as I&#8217;m not using Debian).  That template has a very weird entry:</p>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow">
<p><code>127.0.1.1 {{fqdn}} {{hostname}}</code></p>
</blockquote>



<p>I have no idea what it&#8217;s even trying to do with that.</p>



<p>What it <em>does</em> do is break a lot of things, because while 127.0.1.1 is a valid address (albeit weird to use instead of the canonical 127.0.0.1), in a standard <a href="https://www.plesk.com" data-wpel-link="external" target="_blank" rel="external noopener">Plesk</a> system <a href="https://nginx.org" data-wpel-link="external" target="_blank" rel="external noopener">Nginx</a> (that sits in front of <a href="https://httpd.apache.org" data-wpel-link="external" target="_blank" rel="external noopener">Apache</a> typically) is configured to listen only on the network interface(s) associated with your web server&#8217;s public IP address(es), not localhost<sup data-fn="f02da440-1755-49a0-b849-7989472e1805" class="fn"><a href="#f02da440-1755-49a0-b849-7989472e1805" id="f02da440-1755-49a0-b849-7989472e1805-link">1</a></sup>.  So if you try e.g. <code>curl mydomain.com</code> from inside your server hosting that very domain, you get a connection refused error (or it just times out with no response, depending on firewall settings).</p>



<p>The way <a href="https://talk.plesk.com/threads/can-no-longer-connect-to-nginx-from-localhost.372659/" data-wpel-link="external" target="_blank" rel="external noopener">I found out about this</a> was when WordPress&#8217;s &#8220;cron&#8221; system silently stopped running tasks (because I use a real cron job to trigger it periodically, rather than relying on WordPress&#8217;s flaky built-in system).  I subsequently also noticed that <a href="https://wordpress.org/plugins/broken-link-checker/" data-wpel-link="external" target="_blank" rel="external noopener">Broken Link Checker</a> mistakenly reported <em>every</em> link within my own site as broken.</p>



<h2 class="wp-block-heading">The solution</h2>



<p>…is fairly simple &#8211; modify the template to remove the offending line.  You then have to either reboot or similarly manually modify <code>/etc/hosts</code> to actually apply the fix.</p>



<p>If for some reason you cannot do that, there are potentially workarounds.  For example, for <code>curl</code> commands you can make <code>curl</code> navigate around the problem this like:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>curl --header 'Host: mydomain.com' https://&lt;your server's external IP></code></p></blockquote></figure>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<p>☝️ If you have a CDN or similar in front of your server, e.g. <a href="https://www.cloudflare.com/" data-wpel-link="external" target="_blank" rel="external noopener">Cloudflare</a>, this will potentially behave differently to connecting from another host; it&#8217;ll bypass the CDN and connect directly to your web server (effectively the same as if you did connect to 127.0.0.1).</p>



<p>Depending on your needs, this could be desirable (e.g. no need to send WordPress cron invocations through a CDN) or undesirable (broken link checking probably should go through the CDN, just like all real traffic, to test that the CDN doesn&#8217;t cause a problem).</p>
</div></div>



<p>In a non-Plesk environment you might also be able to just change the Nginx configuration (somewhere under <code>/etc/nginx</code>).  That&#8217;s ill-advised for Plesk-operated servers as Plesk will inevitably revert your changes (and as far as I can tell there is no configuration option, or workaround otherwise, to make Plesk configure Nginx to listen on localhost as well 😕).</p>


<ol class="wp-block-footnotes"><li id="f02da440-1755-49a0-b849-7989472e1805">I suspect this is more a side-effect than intentional.  Plesk chooses the interface only implicitly, when it specifies that it listens on specific addresses &#8211; those assigned to the website in question (Nginx can host multiple otherwise unrelated websites, and each is configured independently within its settings).  Since Plesk supports hosting multiple websites, each with potentially <em>different</em> IP addresses, it makes sense that it would want to keep them separate.  Otherwise, in a shared hosting situation you could connect to the IP address for somehost.com yet issue a HTTP request for unrelatedhost.com and actually get a response, which is weird, at least. <a href="#f02da440-1755-49a0-b849-7989472e1805-link" aria-label="Jump to footnote reference 1">↩︎</a></li></ol>]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/cloudinit-breaks-connections-from-localhost-to-plesk-operated-web-servers/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">7491</post-id>	</item>
		<item>
		<title>How to install ImageMagick 7 for WordPress under Plesk Obsidian on Ubuntu 22.04</title>
		<link>https://wadetregaskis.com/how-to-install-imagemagick-7-for-wordpress-under-plesk-obsidian-on-ubuntu-22-04/</link>
					<comments>https://wadetregaskis.com/how-to-install-imagemagick-7-for-wordpress-under-plesk-obsidian-on-ubuntu-22-04/#comments</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Mon, 22 Jan 2024 02:29:08 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Meta]]></category>
		<category><![CDATA[AVIF]]></category>
		<category><![CDATA[ImageMagick]]></category>
		<category><![CDATA[Imagick]]></category>
		<category><![CDATA[JXL]]></category>
		<category><![CDATA[Plesk]]></category>
		<category><![CDATA[Plesk Obsidian]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://wadetregaskis.com/?p=7457</guid>

					<description><![CDATA[Why should I do this? WordPress relies on either ImageMagick or GD for its ability to read &#38; write images. It prefers ImageMagick, as ImageMagick supports a much wider range of files, tends to be faster, and some assert that it produces higher quality files. ImageMagick 6 was superseded by ImageMagick 7 nearly a decade&#8230; <a class="read-more-link" href="https://wadetregaskis.com/how-to-install-imagemagick-7-for-wordpress-under-plesk-obsidian-on-ubuntu-22-04/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[
<h2 class="wp-block-heading no-clear-thanks">Why should I do this?</h2>



<p><a href="https://wordpress.org" data-wpel-link="external" target="_blank" rel="external noopener">WordPress</a> relies on either <a href="https://imagemagick.org" data-wpel-link="external" target="_blank" rel="external noopener">ImageMagick</a> or <a href="https://libgd.github.io" data-wpel-link="external" target="_blank" rel="external noopener">GD</a> for its ability to read &amp; write images.  It prefers ImageMagick, as ImageMagick supports a much wider range of files, tends to be faster, and some assert that it produces higher quality files.</p>



<p>ImageMagick 6 was superseded by ImageMagick 7 nearly a decade ago.  <a href="https://legacy.imagemagick.org" data-wpel-link="external" target="_blank" rel="external noopener">Version 6 is officially in legacy mode</a> and while still technically supported (in a <a href="https://en.wikipedia.org/wiki/Long-term_support" data-wpel-link="external" target="_blank" rel="external noopener">long term support</a> sense) it generally receives only bug fixes &#8211; it fundamentally lacks many features, and most crucially it doesn&#8217;t support modern image formats correctly, such as AVIF<sup data-fn="39baf781-8a25-40c7-8128-a093b1008184" class="fn"><a href="#39baf781-8a25-40c7-8128-a093b1008184" id="39baf781-8a25-40c7-8128-a093b1008184-link">1</a></sup>.</p>



<p>Additionally, <a href="https://www.cvedetails.com/vulnerability-list/vendor_id-1749/Imagemagick.html?page=1&amp;cvssscoremin=9&amp;order=7&amp;trc=646&amp;sha=65fdcf32523abd445121e3eeede4072f9b2e0164" data-wpel-link="external" target="_blank" rel="external noopener">ImageMagick is a common source of serious security exploits</a>.  It&#8217;s very important to run the latest version (or very close to) at all times, to have as many critical bug fixes as possible.</p>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<p>I recall when I was at Google there was &#8211; very begrudging &#8211; use of ImageMagick &#8211; it <em>is</em> the premier library for converting images when you really need to accept just about anything &#8211; but there were heroic efforts taken to isolate it and compartmentalise it, because it was taken as a given that it would be successfully exploited all the time<sup data-fn="dd7bbb45-83b3-427f-b78e-2e7899711d0f" class="fn"><a href="#dd7bbb45-83b3-427f-b78e-2e7899711d0f" id="dd7bbb45-83b3-427f-b78e-2e7899711d0f-link">2</a></sup>.  Buffer overflows, memory corruption, etc &#8211; ImageMagick is written in plain old C &amp; C++, and as such is inherently very prone to these kinds of problems.</p>
</div></div>



<p>Note that, depending on how you operate your WordPress site(s), you may or may not be seriously exposed to ImageMagick security problems.  For simple single-author sites, where only the admin can upload anything to the site (images or otherwise), it&#8217;s arguably not a huge concern.  But for more complex sites with multiple contributors &#8211; or worse, sites which accept images from general users or the public &#8211; using an outdated ImageMagick release is a serious risk.</p>



<h2 class="wp-block-heading">Why isn&#8217;t this easy?</h2>



<p>On some Linux distros, and when Plesk isn&#8217;t involved, it <em>is</em> easy &#8211; you just <code>apt install imagemagick</code> or <code>yum install ImageMagick</code> or at worst <a href="https://imagemagick.org/script/download.php" data-wpel-link="external" target="_blank" rel="external noopener">download the RPM</a> and install that.  Generally that installs ImageMagick 7 (and if not the very latest release, at least a recent one).  You subsequently just run <code>update</code> on your package manager periodically and ImageMagick is kept reasonably up to date.</p>



<p>Ubuntu does not like ImageMagick 7, for some reason.  No version of Ubuntu supports it officially, in the sense that it is not in any of the official package repos.  If you <code>apt install imagemagick</code>, you&#8217;ll get version 6 &#8211; and not even a recent version 6, but 6.9.11-60 which is over three years old!  That&#8217;s <em>three years</em> of well-known bugs &#8211; some of them potential security exploits.</p>



<p>So, unfortunately, the only way to install a modern version of ImageMagick on Ubuntu is manually.</p>



<p>Consequently, you have to manually install a suitable version of <a href="https://github.com/Imagick/imagick" data-wpel-link="external" target="_blank" rel="external noopener">Imagick</a> as well, and you have to do it into Plesk&#8217;s special PHP installation(s).</p>



<p>It took me several hours to figure all of this out, which is why I&#8217;ve written this post &#8211; so that nobody else ever has to.</p>



<h2 class="wp-block-heading">The procedure</h2>



<p>If you run into any issues, please let me know in the comments section at the bottom of the page.  I endeavour to correct any mistakes, oversights, or confusion.</p>



<p>Note that most of these commands must be run as <em>root</em>.  Either run them inside a root shell (e.g. <code>su</code>, or <code>sudo bash</code>) or prefix them with <code>sudo</code>.</p>



<h3 class="wp-block-heading">Install ImageMagick 7</h3>



<p>Fortunately, <a href="https://github.com/SoftCreatR/imei" data-wpel-link="external" target="_blank" rel="external noopener">ImageMagick Easy Install (IMEI)</a> exists to greatly simplify this step.</p>



<p>First, as a precaution IMEI insists you remove any existing ImageMagick installation(s).  Manually installing a build of ImageMagick over the formally-packaged Ubuntu version could cause problems.</p>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<div class="wp-block-group warning is-horizontal is-content-justification-center is-layout-flex wp-container-core-group-is-layout-00ace616 wp-block-group-is-layout-flex">
<p style="font-size:100px">⚠️</p>



<p class="wp-container-content-9cfa9a5a">Be mindful that as soon as you run this command, things on your server that rely on ImageMagick will no longer work!  Fortunately this whole process takes less than half an hour, so it might go unnoticed (WordPress itself will continue working fine, serving up all existing media, but you probably won&#8217;t be able to upload new images until you finish this procedure).<br><br>If you do not finish the installation successfully, your server will likely be left in a bad, partly-broken state.  In principle you can revert back to the standard system versions of things, with e.g. <code>apt install imagemagick</code> or perhaps through Plesk, but I haven&#8217;t tested it and I make no promises.</p>
</div>
</div></div>



<figure class="wp-block-pullquote"><blockquote><p><code>apt remove "*imagemagick*" --purge -y &amp;&amp; apt autoremove --purge -y</code></p></blockquote></figure>



<p>Next, download and install ImageMagick:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>pushd /tmp &amp;&amp; git clone https://github.com/SoftCreatR/imei &amp;&amp; cd imei &amp;&amp; chmod +x imei.sh &amp;&amp; ./imei.sh</code></p></blockquote></figure>



<p>By default it&#8217;ll install a very recent version &#8211; usually the very latest release &#8211; but you can customise it if you wish with the <code>--imagemagick-version</code> argument to <code>imei.sh</code>.</p>



<p>Note: I had to use the <code>--force</code> argument to get <code>imei.sh</code> to actually build &amp; install <em>all</em> the components &#8211; for some reason it skipped the dependent libraries (for AVIF &amp; JXL support) and just installed ImageMagick, <em>without</em> AVIF and JXL support.  Try it without first, since that&#8217;s supposed to be the happy path, but check that it says <code>[<span style="color: green">OK</span>]</code> for every item; that nothing is <code>[<span style="color: green">SKIPPED</span>]</code>.</p>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<p>Building libaom (for AVIF support) requires CMake 3.6 or later.  Ubuntu 22.04 comes with a suitable version, so you shouldn&#8217;t have any issues.  But if you&#8217;re installing on an older Ubuntu, a different distro, or you&#8217;ve messed with CMake otherwise, check that you have a suitable version with <code>cmake --version</code>.</p>
</div></div>



<p>Once it&#8217;s completed successfully &#8211; which can take tens of minutes if you have a wimpy server such as is often used for WordPress hosting &#8211; double-check that you have a good version installed:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>identify --version</code></p></blockquote></figure>



<p>At time of writing that says 7.1.1-26 for me, but of course for you it&#8217;ll probably be something newer.  You can consult <a href="https://imagemagick.org/script/download.php" data-wpel-link="external" target="_blank" rel="external noopener">ImageMagick&#8217;s download page</a> to find out what the newest version is.</p>



<h3 class="wp-block-heading">Install Imagick</h3>



<p>First, download Imagick:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>pushd /tmp &amp;&amp; git clone https://github.com/Imagick/imagick &amp;&amp; cd imagick</code></p></blockquote></figure>



<p>Next, you need to set the version string to the actual version &#8211; otherwise, at the very end of this process, you&#8217;ll find that WordPress quietly refuses to use ImageMagick / Imagick!  Do that by editing the <code>php_imagick.h</code> file.  You should see, somewhere near the top of the file, something like:</p>



<div class="wp-block-kevinbatdorf-code-block-pro padding-disabled" data-code-block-pro-font-family="" style="font-size:.875rem;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><pre class="shiki light-plus" style="background-color: #FFFFFF" tabindex="0"><code><span class="line"><span style="color: #AF00DB">#define</span><span style="color: #0000FF"> PHP_IMAGICK_VERSION    </span><span style="color: #A31515">&quot;@PACKAGE_VERSION@&quot;</span></span>
<span class="line"><span style="color: #AF00DB">#define</span><span style="color: #0000FF"> PHP_IMAGICK_EXTNUM     </span><span style="color: #098658">30700</span></span></code></pre></div>



<p>You need to change that first string to the version declared on that second line.  30700 means version 3.7.0.  So in my case I replaced <code>"@PACKAGE_VERSION@"</code> with <code>"3.7.0"</code>.</p>



<p>Now you need to determine where the relevant PHP installation is &#8211; the version that Plesk is using to run WordPress for your website(s).  You can find that out in various ways, perhaps the simplest being to log in to your Plesk dashboard, open the &#8220;Websites &amp; Domains&#8221; section, and look at the PHP version listed for each website of interest.</p>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<p>☝️If you have multiple sites and they&#8217;re not all running the same version of PHP, you&#8217;ll need to repeat all the following steps for each PHP version.</p>
</div></div>



<p>In my case I&#8217;m using PHP 8.2. So now I know that the PHP install of interest is located at <code>/opt/plesk/php/8.2/</code> (Plesk installs all its versions of PHP in <code>/opt/plesk/php</code>). I&#8217;ll use that in the subsequent commands shown here, but make sure to adjust that to suit whatever version of PHP you&#8217;re using.</p>



<p>To build Imagick, you need the PHP developer tools &#8211; for your particular Plesk PHP installation(s).  e.g. in my case I&#8217;m using PHP 8.2, so I need to run:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>apt install plesk-php82-dev</code></p></blockquote></figure>



<p>Now you need to configure the Imagick build:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>/opt/plesk/php/8.2/bin/phpize &amp;&amp; ./configure --prefix=/opt/plesk/php/8.2/ --exec-prefix=/opt/plesk/php/8.2/ --datadir=/opt/plesk/php/8.2/ --with-php-config=/opt/plesk/php/8.2/bin/php-config &amp;&amp; make -j `nproc --all` install</code></p></blockquote></figure>



<p>Don&#8217;t forget to change &#8220;8.2&#8221; to your version of PHP, if it&#8217;s different!</p>



<p>It should only take ten seconds or so to configure, build, &amp; install Imagick.</p>



<p>Now, rename the built library so that Plesk updates won&#8217;t clobber it:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>mv /opt/plesk/php/8.2/lib/php/modules/imagick{,_custom}.so</code></p></blockquote></figure>



<p>Lastly, although it&#8217;s technically optional, it&#8217;s nice to fix the permissions of the installed library:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>chmod 644 /opt/plesk/php/8.2/lib/php/modules/imagick_custom.so</code></p></blockquote></figure>



<h3 class="wp-block-heading">Load Imagick into PHP</h3>



<p>Annoyingly, PHP won&#8217;t automatically notice Imagick is installed &#8211; you have to tell it so, manually.  Though this is pretty easy to do.  There are a few ways to do it, the easiest being through Plesk:  go to the &#8220;Tools &amp; Settings&#8221; section of your Plesk dashboard, click &#8220;PHP Settings&#8221; (from the &#8220;General Settings&#8221; category), then click on the relevant handler in the list (e.g. &#8220;FPM application&#8221;).  If you&#8217;re not sure which is relevant, look for a non-zero number in the &#8220;Domains&#8221; column.</p>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<p>☝️If you use different handlers for different websites &#8211; as will be shown in the &#8220;Domains&#8221; column by a number greater than zero for multiple rows &#8211; then you might need to repeat the following steps for each one of them.  Start with any one of them, then when editing the <code>php.ini</code> file (as explained below) check which handlers are listed as also covered by that same file.  If any are missing, those are the ones you&#8217;ll need to repeat these steps on.</p>
</div></div>



<p>Click on &#8220;php.ini&#8221; to switch to that tab, and you should see a text field containing the contents of the relevant <code>php.ini</code> file.  Somewhere in this file &#8211; technically anywhere, but I like to scroll down to the section where all the other extensions are listed &#8211; you need to add the line:</p>



<pre class="wp-block-preformatted">extension=imagick_custom.so</pre>



<p>Then, click the &#8220;OK&#8221; button to save your changes.</p>



<p>In <em>theory</em> Plesk will now restart the relevant server daemons, to have them pick up the change, but if you subsequently find that WordPress doesn&#8217;t seem to see the new ImageMagick installation (or you edited <code>php.ini</code> directly from the command line), you can give it a more forceful shove:</p>



<figure class="wp-block-pullquote"><blockquote><p><code>service plesk-php82-fpm restart</code></p></blockquote></figure>



<p>You should now be set &#8211; you can test your upgrade in a variety of ways, such as:</p>



<ul class="wp-block-list">
<li>Try uploading an image in a format, or using features such as animation or transparency, that wasn&#8217;t previously supported.  e.g. AVIFs.  Note that you might need additional WordPress plug-ins to enable use of the new formats, e.g. <a href="https://wordpress.org/plugins/avif-support/" data-wpel-link="external" target="_blank" rel="external noopener">AVIF Support</a> or any of the <a href="https://wordpress.org/plugins/search/svg/" data-wpel-link="external" target="_blank" rel="external noopener">numerous SVG support plug-ins</a>.<br><br>See also <a href="https://wadetregaskis.com/image-workflow-for-wordpress/" data-wpel-link="internal">my earlier post on my Image workflow for WordPress</a> &#8211; particularly <a href="https://wadetregaskis.com/image-workflow-for-wordpress/#AVIF_Support" data-wpel-link="internal">the section on AVIF</a>.</li>



<li>Check phpinfo &#8211; in your Plesk dashboard, go to your website(s) in the &#8220;Websites &amp; Domains&#8221; section, click &#8220;PHP&#8221; (under the &#8220;Dev Tools&#8221; category), then click the subtle &#8220;View the phpinfo() page&#8221; link to the right of the first pop-up menus.  Search for &#8220;imagick&#8221; &#8211; you should find an entry for it, with a table of plug-in information such as its version, the version of ImageMagick being used, and the file formats supported.</li>
</ul>


<div class="wp-block-image">
<figure class="aligncenter size-full"><img fetchpriority="high" decoding="async" width="946" height="480" src="https://wadetregaskis.com/wp-content/uploads/2024/01/imagick-section-of-phpinfo.webp" alt="Screenshot of the &quot;imagick&quot; section of the phpinfo page." class="wp-image-7465" srcset="https://wadetregaskis.com/wp-content/uploads/2024/01/imagick-section-of-phpinfo.webp 946w, https://wadetregaskis.com/wp-content/uploads/2024/01/imagick-section-of-phpinfo-256x130.webp 256w, https://wadetregaskis.com/wp-content/uploads/2024/01/imagick-section-of-phpinfo-512x260.webp 512w, https://wadetregaskis.com/wp-content/uploads/2024/01/imagick-section-of-phpinfo@2x.webp 1892w" sizes="(max-width: 946px) 100vw, 946px" /></figure>
</div>


<h2 class="wp-block-heading">Addendum: updating ImageMagick &amp; Magick</h2>



<p>You can of course just repeat all the above steps to perform a fresh install, incorporating any updates since you last installed everything.  But you can save a little time by keeping the <code>imei</code> and <code>imagick</code> folders around, and just doing:</p>



<ol class="wp-block-list">
<li><code>git pull --rebase</code> in each, then re-run their respective build commands.  For Imagick you&#8217;ll probably have to <code>git stash</code> first, in order to do the <code>git pull</code>, and then restore your version string patch with <code>git stash apply</code>.<br><br>Don&#8217;t forget to check if you need to update the version string in <code>php_imagick.h</code>.</li>



<li>Rename the built <code>imagick.so</code> again, and fix its permissions.</li>



<li>Restart the PHP daemon.</li>
</ol>


<ol class="wp-block-footnotes"><li id="39baf781-8a25-40c7-8128-a093b1008184">Some versions &amp; builds nominally support AVIF, but this support is almost by accident &#8211; what they actually support formally is <a href="https://en.wikipedia.org/wiki/High_Efficiency_Image_File_Format" data-wpel-link="external" target="_blank" rel="external noopener">HEIF</a>, for which they use <a href="https://github.com/strukturag/libheif" data-wpel-link="external" target="_blank" rel="external noopener">libheif</a>, which <em>can</em> be built with AVIF support as well, but in my experience that support is buggy and incomplete &#8211; e.g. <a href="https://alexwlchan.net/2023/check-for-transparency/" data-wpel-link="external" target="_blank" rel="external noopener">alpha channels are not supported</a>. <a href="#39baf781-8a25-40c7-8128-a093b1008184-link" aria-label="Jump to footnote reference 1">↩︎</a></li><li id="dd7bbb45-83b3-427f-b78e-2e7899711d0f">Alas I don&#8217;t actually know if / how often it was successfully exploited, as far as Google saw.  I have to imagine it was not uncommon, though, given the large attack surface that is ImageMagick&#8217;s APIs and image plug-ins, not to mention how lucrative a target Google is. <a href="#dd7bbb45-83b3-427f-b78e-2e7899711d0f-link" aria-label="Jump to footnote reference 2">↩︎</a></li></ol>]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/how-to-install-imagemagick-7-for-wordpress-under-plesk-obsidian-on-ubuntu-22-04/feed/</wfw:commentRss>
			<slash:comments>12</slash:comments>
		
		
			<media:content url="https://wadetregaskis.com/wp-content/uploads/2024/01/ImageMagick-logo.avif" medium="image" />
<post-id xmlns="com-wordpress:feed-additions:1">7457</post-id>	</item>
		<item>
		<title>No more Dark Mode support</title>
		<link>https://wadetregaskis.com/no-more-dark-mode-support/</link>
					<comments>https://wadetregaskis.com/no-more-dark-mode-support/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Mon, 01 Jan 2024 03:45:56 +0000</pubDate>
				<category><![CDATA[Meta]]></category>
		<category><![CDATA[Bloated]]></category>
		<category><![CDATA[Dark mode]]></category>
		<category><![CDATA[Dark Mode for Safari]]></category>
		<category><![CDATA[Dark Reader]]></category>
		<category><![CDATA[Dracula Dark Mode]]></category>
		<category><![CDATA[Noir]]></category>
		<category><![CDATA[Perfect Images]]></category>
		<category><![CDATA[Sad]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[WP Dark Mode]]></category>
		<category><![CDATA[WP Fastest Cache]]></category>
		<guid isPermaLink="false">https://wadetregaskis.com/?p=7255</guid>

					<description><![CDATA[For about a month I was using WP Dark Mode. I don&#8217;t really recall how I thought upon it to begin with, but I vaguely recall choosing to install it because it seemed kind to support dark mode. Even though I don&#8217;t use it myself, it does seem to have a non-trivial following. And I&#8230; <a class="read-more-link" href="https://wadetregaskis.com/no-more-dark-mode-support/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[
<p>For about a month I was using <a href="https://wordpress.org/plugins/wp-dark-mode/" data-wpel-link="external" target="_blank" rel="external noopener">WP Dark Mode</a>.  I don&#8217;t really recall how I thought upon it to begin with, but I vaguely recall choosing to install it because it seemed kind to support dark mode.  Even though I don&#8217;t use it myself, it does seem to have a non-trivial following.  And I remember being obsessively into it &#8211; and OS theming in general &#8211; when I was a child.</p>



<p>WP Dark Mode had &#8216;flashing&#8217; problems, though &#8211; where the page loads first in normal, &#8216;light&#8217; mode and only then re-renders into dark mode.  Possibly just a result of interference by <a href="https://www.wpfastestcache.com" data-wpel-link="external" target="_blank" rel="external noopener">WP Fastest Cache</a>, which I later realised was probably deferring WP Dark Mode&#8217;s JavaScript files past initial page load.  Irrespective, I found that <a href="https://wordpress.org/plugins/dracula-dark-mode/" data-wpel-link="external" target="_blank" rel="external noopener">Dracula Dark Mode</a> worked better &#8211; though still not flawlessly in this regard &#8211; so I switched to that.</p>



<p>However, I eventually noticed that Dracula Dark Mode adds <em>415 KiB</em> to every single page load, with its JavaScript and CSS files.  That <em>doubles</em> the total size for some pages, even with WordPress &amp; Jetpack bloating the baseline.  Its own analytics suggested that basically nobody uses dark mode, at least amongst people that browse my website.  So that does not seem like a reasonable trade-off.</p>



<p>Thus, with a bit of sadness, I&#8217;ve disabled the plug-in.  Maybe in future the plug-in&#8217;s authors can find a way to optimise things such that its JS &amp; CSS is only loaded if dark mode is actually in use.</p>



<p>Turns out, though, that almost no websites support dark mode anyway &#8211; I discovered as much while having dark mode enabled during my own testing.  So it doesn&#8217;t seem like I&#8217;m an odd one out, and my tiny website is not going to start any trends.  From the looks of it the way most people actually tackle the web in dark mode is through browser plug-ins which basically do the same thing as the WordPress plug-ins, but for <em>every</em> website.  And only users actually interested in dark mode have to pay their price.</p>



<p>I haven&#8217;t tried any of them, but there&#8217;s numerous Safari plug-ins for dark mode, e.g. <a href="https://darkreader.org" data-wpel-link="external" target="_blank" rel="external noopener">Dark Reader</a>, <a href="https://getnoir.app" data-wpel-link="external" target="_blank" rel="external noopener">Noir</a>, <a href="https://alexdenk.eu/mywork/darkmode.html" data-wpel-link="external" target="_blank" rel="external noopener">Dark Mode for Safari</a>, etc.</p>



<p>It does mean I can&#8217;t do image substitutions for dark mode users, but I couldn&#8217;t find any dark mode WordPress plug-in that works correctly in that regard anyway (they seem to do naive URL substitutions, without accounting for images having various replicas of different sizes per WordPress standard practice, and certainly without supporting <a href="https://meowapps.com/wp-retina-2x/" data-wpel-link="external" target="_blank" rel="external noopener">Perfect Images</a>).  It&#8217;s also rare that I have a dark mode version of an image available &#8211; though I can at least be better about using actual alpha channels rather than fixed white backgrounds, going forward.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/no-more-dark-mode-support/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">7255</post-id>	</item>
		<item>
		<title>Image workflow for WordPress</title>
		<link>https://wadetregaskis.com/image-workflow-for-wordpress/</link>
					<comments>https://wadetregaskis.com/image-workflow-for-wordpress/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Sun, 31 Dec 2023 01:41:49 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Meta]]></category>
		<category><![CDATA[AVIF]]></category>
		<category><![CDATA[AVIF Support]]></category>
		<category><![CDATA[Enable Media Replace]]></category>
		<category><![CDATA[Image Regenerate & Select Crop]]></category>
		<category><![CDATA[Image Tool+]]></category>
		<category><![CDATA[ImageOptim]]></category>
		<category><![CDATA[JPEG 2000]]></category>
		<category><![CDATA[JPEG XL]]></category>
		<category><![CDATA[Perfect Images]]></category>
		<category><![CDATA[PNG]]></category>
		<category><![CDATA[WebP]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://wadetregaskis.com/?p=7146</guid>

					<description><![CDATA[These are the main tools and procedures I use for publishing images through WordPress. In case it&#8217;s helpful to others. My input images generally fall into three categories: Some of these formats can be published directly into WordPress &#8211; mainly PNG and JPEG &#8211; but not all, and neither PNG nor JPEG are the best&#8230; <a class="read-more-link" href="https://wadetregaskis.com/image-workflow-for-wordpress/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[
<p>These are the main tools and procedures I use for publishing images through WordPress.  In case it&#8217;s helpful to others.</p>



<p>My input images generally fall into three categories:</p>



<ol class="wp-block-list">
<li>Screenshots, as PNGs.</li>



<li>Random 3rd party images, typically as JPEGs but sometimes PNGs or other formats.</li>



<li>Photos, as Nikon NEFs.</li>
</ol>



<p>Some of these formats <em>can</em> be published directly into WordPress &#8211; mainly PNG and JPEG &#8211; but not all, and neither PNG nor JPEG are the best file formats for anything these days.  In terms of compression efficiency, there are numerous superior formats &#8211; JPEG 2000, JPEG XL, HEIF<sup data-fn="ce19f9a1-4b3d-427c-b205-ec8684b1e5ae" class="fn"><a href="#ce19f9a1-4b3d-427c-b205-ec8684b1e5ae" id="ce19f9a1-4b3d-427c-b205-ec8684b1e5ae-link">1</a></sup>, WebP, AVIF, etc.</p>



<p>Using an appropriate and efficient format &#8211; and suitable compression quality settings &#8211; is important to me to save disk space, save bandwidth, minimise page load times, and ensure images are seen the way I want them to be (re. lossless vs lossy).</p>



<h1 class="wp-block-heading">Best image codecs</h1>



<h2 class="wp-block-heading">Legacy options</h2>



<p>PNG and JPEG are supported in practically any &amp; every web browser still in real use today.  As is GIF, technically, although it&#8217;s strictly inferior to PNG [for static images] and actual video formats [for moving images].  It certainly <em>is</em> possible to still use them, but it wastes storage space &amp; bandwidth, and hurts page load times.</p>



<p>That said, PNG is not the worst option <em>if</em> you use appropriate tooling to maximise the compression.  The level of compression you achieve &#8216;out of the box&#8217; with most applications &#8211; e.g. Photoshop, Apple&#8217;s apps, etc &#8211; is actually quite poor.  There are numerous specialised tools which can greatly improve the compression.  I recommend <a href="https://imageoptim.com/mac" data-wpel-link="external" target="_blank" rel="external noopener">ImageOptim</a> &#8211; it&#8217;s free and open source.  It typically reduces PNG files sizes by a further 20% to 50% (depending on how much fine detail or noise the image contains) without any loss of image quality.  It actually makes PNG competitive with the modern formats to a degree, although ultimately still not the best.</p>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<p>⚠️ ImageOptim does not work correctly with <em>animated</em> PNGs &#8211; it silently removes the animation!</p>
</div></div>


<div class="wp-block-image">
<figure class="aligncenter size-full is-resized"><img decoding="async" width="664" height="559" src="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim.webp" alt="" class="wp-image-7150" style="width:664px;height:auto" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim.webp 664w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-256x216.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-512x431.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim@2x.webp 1328w" sizes="(max-width: 664px) 100vw, 664px" /></figure>
</div>


<p>It&#8217;s quite configurable, including with regard to stripping metadata or not &#8211; although, alas, it offers no nuance in this, such as keeping copyright metadata but removing spurious camera metadata, or geolocations.</p>



<div class="alignnormal"><div id="metaslider-id-7155" style="max-width: 775px; margin: 0 auto;" class="ml-slider-3-107-0 metaslider metaslider-flex metaslider-7155 ml-slider ms-theme-default nav-hidden" role="region" aria-label="ImageOptim Preferences" data-height="510" data-width="775">
    <div id="metaslider_container_7155">
        <div id="metaslider_7155" class="flexslider">
            <ul class='slides'>
                <li style="display: block; width: 100%;" class="slide-7157 ms-image " aria-roledescription="slide" data-date="2023-12-30 12:03:47" data-filename="ImageOptim-Settings-General.webp" data-slide-type="image"><img decoding="async" width="775" height="510" src="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-General.webp" class="slider-7155 slide-7157 msDefaultImage" alt="Screenshot of the ImageOptim Preferences window, showing the General tab" rel="" title="ImageOptim Settings - General" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-General.webp 775w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-General-256x168.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-General-512x337.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-General@2x.webp 1550w" sizes="(max-width: 775px) 100vw, 775px" /><div class="caption-wrap"><div class="caption">You have full control over which libraries are used.  Not all the libraries are enabled by default - Guetzli in particular is off by default because it can make the recompression process take a particularly long time.  But in my opinion, if you're going to the trouble of using specialised tools to improve your image compression, you might as well use them to their fullest.</div></div></li>
                <li style="display: none; width: 100%;" class="slide-7158 ms-image " aria-roledescription="slide" data-date="2023-12-30 12:03:47" data-filename="ImageOptim-Settings-Quality.webp" data-slide-type="image"><img loading="lazy" decoding="async" width="775" height="510" src="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Quality.webp" class="slider-7155 slide-7158 msDefaultImage" alt="Screenshot of the ImageOptim Preferences window, showing the Quality tab" rel="" title="ImageOptim Settings - Quality" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Quality.webp 775w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Quality-256x168.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Quality-512x337.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Quality@2x.webp 1550w" sizes="auto, (max-width: 775px) 100vw, 775px" /><div class="caption-wrap"><div class="caption">By default ImageOptim preserves your images exactly as they appear (lossless recompression), but it does give you the option of using lossy compression.  Just beware of significant and unpredictable compression artefacts, particularly with PNGs.</div></div></li>
                <li style="display: none; width: 100%;" class="slide-7156 ms-image " aria-roledescription="slide" data-date="2023-12-30 12:03:46" data-filename="ImageOptim-Settings-Optimisation-level.webp" data-slide-type="image"><img loading="lazy" decoding="async" width="775" height="510" src="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Optimisation-level.webp" class="slider-7155 slide-7156 msDefaultImage" alt="Screenshot of the ImageOptim Preferences window, showing the Optimisation level tab" rel="" title="ImageOptim Settings - Optimisation level" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Optimisation-level.webp 775w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Optimisation-level-256x168.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Optimisation-level-512x337.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/ImageOptim-Settings-Optimisation-level@2x.webp 1550w" sizes="auto, (max-width: 775px) 100vw, 775px" /><div class="caption-wrap"><div class="caption">I haven't really played with this 'Optimisation level' setting, I just set it to maximum.  Why use a tool like this if you're not going to use it to its fullest?</div></div></li>
            </ul>
        </div>
        
    </div>
</div></div>



<p>It&#8217;s also possible to use such specialised tools for <em>lossy</em> PNG compression.  PNG is not inherently lossy, but by manipulating the image before compression it is possible to greatly improve its compressibility.  e.g. by reducing the colour palette, adding or removing dithering, or simply removing fine detail.  Various tools &#8211; including ImageOptim &#8211; will do this for you if you wish, although be warned that the resulting image quality is unpredictable and sometimes very poor (exhibiting obvious colour changes, banding, or visual artefacts otherwise).</p>



<p>The example below is a fairly typical &#8220;good&#8221; result &#8211; the file size is cut by 70%, but the lossy PNG compression has introduced noticeable banding and dithering.  You might consider it worth the trade-off but consider that a lossy WebP version, <em>also</em> saving 70% on file size, doesn&#8217;t have any noticeable image degradation.  And an AVIF version with similar image quality cuts the file size by <em>80%</em>.  So while you might think it&#8217;s neat to use a &#8216;lossy&#8217; PNG and get &#8211; by PNG standards &#8211; dramatically higher compression, you&#8217;re probably better off just using WebP or AVIF.</p>



<div class="alignnormal"><div id="metaslider-id-7178" style="max-width: 1000px; margin: 0 auto;" class="ml-slider-3-107-0 metaslider metaslider-flex metaslider-7178 ml-slider ms-theme-default nav-hidden nav-hidden" role="region" aria-label="Lossy PNG warning" data-height="597" data-width="1000">
    <div id="metaslider_container_7178">
        <div id="metaslider_7178" class="flexslider">
            <ul class='slides'>
                <li style="display: block; width: 100%;" class="slide-7183 ms-image " aria-roledescription="slide" data-date="2023-12-30 16:01:23" data-filename="Swift-on-Raspberry-Pi-lossless.png" data-slide-type="image"><img loading="lazy" decoding="async" width="2000" height="1194" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossless.png" class="slider-7178 slide-7183 msDefaultImage" alt="" rel="" title="Swift on Raspberry Pi (lossless)" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossless.png 2000w, https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossless-256x153.png 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossless-512x306@2x.png 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossless-512x306.png 512w" sizes="auto, (max-width: 2000px) 100vw, 2000px" /><div class="caption-wrap"><div class="caption">Lossless PNG (1,956 KB)</div></div></li>
                <li style="display: none; width: 100%;" class="slide-7184 ms-image " aria-roledescription="slide" data-date="2023-12-30 16:01:23" data-filename="Swift-on-Raspberry-Pi-lossy.png" data-slide-type="image"><img loading="lazy" decoding="async" width="2000" height="1194" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossy.png" class="slider-7178 slide-7184 msDefaultImage" alt="" rel="" title="Swift on Raspberry Pi (lossy)" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossy.png 2000w, https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossy-256x153.png 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossy-512x306@2x.png 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/Swift-on-Raspberry-Pi-lossy-512x306.png 512w" sizes="auto, (max-width: 2000px) 100vw, 2000px" /><div class="caption-wrap"><div class="caption">Lossy PNG (587 KB)</div></div></li>
            </ul>
        </div>
        
    </div>
</div></div>



<h2 class="wp-block-heading">Non-options</h2>



<p>Despite its age JPEG 2000 is surprisingly good in my experience &#8211; I used it many years ago on this website for my <a href="https://wadetregaskis.com/raw-converter-comparison/" data-wpel-link="internal">Raw converter comparison</a> as an alternative to TIFF and PNG, as it yielded file sizes about half that of PNG.  It&#8217;s competitive even with newer formats like WebP and AVIF.  JPEG XL is purportedly even better again.  Alas, no browser other than Safari supports either of them.</p>



<p>HEIF exists and is &#8220;modern&#8221; but isn&#8217;t really in the same ballpark &#8211; while it <em>is</em> better than JPEG, that&#8217;s a low bar; it achieves worse results even than JPEG 2000, a codec that&#8217;s <em>twenty years</em> older.  Its only claim to any fame is that it&#8217;s the native source format for many photos today, thanks to its use on Apple iDevices.  In any case, the only current-version web browser which supports it is Safari.</p>



<h2 class="wp-block-heading">Viable options</h2>



<p>The only modern format which is universally supported<sup data-fn="42530c0c-bed1-4a7a-bff8-2c27f0a337bd" class="fn"><a href="#42530c0c-bed1-4a7a-bff8-2c27f0a337bd" id="42530c0c-bed1-4a7a-bff8-2c27f0a337bd-link">2</a></sup> is WebP.</p>


<div class="wp-block-image">
<figure class="aligncenter size-full"><img loading="lazy" decoding="async" width="1158" height="746" src="https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-WebP.webp" alt="Screenshot of caniuse.com showing the web browser compatibility matrix for the WebP image format" class="wp-image-7147" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-WebP.webp 1158w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-WebP-256x165.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-WebP-512x330@2x.webp 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-WebP-512x330.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-WebP@2x.webp 2316w" sizes="auto, (max-width: 1158px) 100vw, 1158px" /><figcaption class="wp-element-caption">Source: <a href="https://caniuse.com/webp" data-wpel-link="external" target="_blank" rel="external noopener">caniuse.com</a></figcaption></figure>
</div>


<p>AVIF is <em>nearly</em> universally supported, with the unfortunately notable exception of Edge.</p>


<div class="wp-block-image">
<figure class="aligncenter size-full"><img loading="lazy" decoding="async" width="1158" height="879" src="https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-AVIF.webp" alt="Screenshot of caniuse.com showing the web browser compatibility matrix for the AVIF image format" class="wp-image-7148" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-AVIF.webp 1158w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-AVIF-256x194.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-AVIF-512x389@2x.webp 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-AVIF-512x389.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/caniuse-com-for-AVIF@2x.webp 2316w" sizes="auto, (max-width: 1158px) 100vw, 1158px" /><figcaption class="wp-element-caption">Source: <a href="https://caniuse.com/avif" data-wpel-link="external" target="_blank" rel="external noopener">caniuse.com</a></figcaption></figure>
</div>


<p>I choose to use AVIF nonetheless, as my audience are unlikely to be using Edge anyway, since they&#8217;re unlikely to be using Windows at all.  I also like to assume that Edge <em>will</em>, eventually, get with the program &#8211; although the fact that AVIF support was apparently incorporated in versions 114 to 117, but then <em>removed</em>, is concerning.</p>



<p>So those are the two options, basically.  For better or worse, neither one is strictly superior to the other.</p>



<figure class="wp-block-pullquote"><blockquote><p>WebP is best for lossless compression, and AVIF is usually the best for lossy compression (especially at lower qualities).</p></blockquote></figure>



<p>It is case-dependent and a little subjective as they have noticeably different methodologies:</p>



<ul class="wp-block-list">
<li>AVIF tends to be heavy-handed with &#8216;noise&#8217; removal, which seems to be a significant part of how it achieves better compression.</li>



<li>WebP will more faithfully preserve noise (and artefacts from earlier lossy compressions), which can be counter-productive.</li>
</ul>



<p>AVIF really excels &#8211; compared to WebP and earlier codecs &#8211; with more aggressive compression settings.  It&#8217;s much better under tight file size constraints.  It also performs particularly well for images which <em>aren&#8217;t</em> so clean to begin with &#8211; where they do have some actual image noise, or visible compression artefacts from an earlier lossy compression stage, or otherwise fine details that aren&#8217;t important to preserve.</p>



<p>WebP behaves more &#8220;traditionally&#8221; &#8211; like JPEG &#8211; with regard to increase blockiness and banding as you crank up the compression.  AVIF does a much better job of degrading image quality more &#8216;smoothly&#8217; across the image &#8211; so that particularly bad, noticeable artefacts don&#8217;t develop as easily.  Even while it preserves more genuine detail.</p>



<div class="alignnormal"><div id="metaslider-id-7171" style="max-width: 1024px; margin: 0 auto;" class="ml-slider-3-107-0 metaslider metaslider-flex metaslider-7171 ml-slider ms-theme-default nav-hidden nav-hidden nav-hidden" role="region" aria-label="Noisy Echo (WebP vs AVIF high-compression comparison)" data-height="1024" data-width="1024">
    <div id="metaslider_container_7171">
        <div id="metaslider_7171" class="flexslider">
            <ul class='slides'>
                <li style="display: block; width: 100%;" class="slide-7174 ms-image " aria-roledescription="slide" data-date="2023-12-30 15:40:08" data-filename="Noisy-Echo-10.avif" data-slide-type="image"><img loading="lazy" decoding="async" width="2048" height="2048" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-10.avif" class="slider-7171 slide-7174 msDefaultImage" alt="" rel="" title="Noisy-Echo (10)" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-10-1024x1024@2x.avif 2048w, https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-10-256x256.avif 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-10-512x512@2x.avif 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-10-512x512.avif 512w" sizes="auto, (max-width: 2048px) 100vw, 2048px" /><div class="caption-wrap"><div class="caption">AVIF (188 KB)</div></div></li>
                <li style="display: none; width: 100%;" class="slide-7175 ms-image " aria-roledescription="slide" data-date="2023-12-30 15:40:09" data-filename="Noisy-Echo-22.webp" data-slide-type="image"><img loading="lazy" decoding="async" width="2048" height="2048" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-22.webp" class="slider-7171 slide-7175 msDefaultImage" alt="" rel="" title="Noisy-Echo (22)" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-22-1024x1024@2x.webp 2048w, https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-22-256x256.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-22-512x512@2x.webp 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/Noisy-Echo-22-512x512.webp 512w" sizes="auto, (max-width: 2048px) 100vw, 2048px" /><div class="caption-wrap"><div class="caption">WebP (185 KB)</div></div></li>
            </ul>
        </div>
        
    </div>
</div></div>



<p>WebP is more competitive with high quality settings or high quality, &#8216;smooth&#8217; images (e.g. screenshots or computer renderings).  In lossless mode WebP universally outperforms AVIF, often by a significant margin.  In fact even PNG typically outperforms AVIF for lossless compression!</p>


<div class="wp-block-image">
<figure class="aligncenter size-full is-resized"><img loading="lazy" decoding="async" width="1208" height="566" src="https://wadetregaskis.com/wp-content/uploads/2019/03/Dialog-screenshot.webp" alt="" class="wp-image-4352" style="width:604px" srcset="https://wadetregaskis.com/wp-content/uploads/2019/03/Dialog-screenshot.webp 1208w, https://wadetregaskis.com/wp-content/uploads/2019/03/Dialog-screenshot-512x240@2x.webp 1024w, https://wadetregaskis.com/wp-content/uploads/2019/03/Dialog-screenshot-256x120.webp 256w, https://wadetregaskis.com/wp-content/uploads/2019/03/Dialog-screenshot-512x240.webp 512w" sizes="auto, (max-width: 1208px) 100vw, 1208px" /><figcaption class="wp-element-caption">82 KB as WebP, 119 KB as PNG, and a whopping 284 KB as AVIF!</figcaption></figure>
</div>


<p>I&#8217;ve also noticed that WebP is <em>substantially</em> better at compressing repetitive patterns (even if they&#8217;re not perfectly identical).</p>


<div class="wp-block-image">
<figure class="aligncenter size-full"><img loading="lazy" decoding="async" width="1024" height="1024" src="https://wadetregaskis.com/wp-content/uploads/2023/12/WebP-repetitive-tiling-example.webp" alt="" class="wp-image-7151" style="object-fit:cover" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/WebP-repetitive-tiling-example-512x512@2x.webp 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/WebP-repetitive-tiling-example-256x256.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/WebP-repetitive-tiling-example-512x512.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/WebP-repetitive-tiling-example@2x.webp 2048w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /><figcaption class="wp-element-caption">Using high-quality (but <em>lossy</em>) compression, this conglomerate image comparing four different RAW converters is 2.3 MB as WebP, 3.8 MB as AVIF (and 12.6 MB as an uncompressed TIFF, for reference).  Yet if you compress any one of the quarters individually, AVIF outperforms WebP.  Even though each quarter is significantly different, there&#8217;s enough repetition between them that WebP can extract significant compression gains, that AVIF apparently cannot.  And in cases with more verbatim repetition, WebP&#8217;s advantage increases even further.</figcaption></figure>
</div>


<p>AVIF seems particularly good at reducing visible artefacts resulting from JPEG over-compression, and in avoiding prominent compression artefacts in general &#8211; such as in the example below, where the file sizes are very similar (14 KB for AVIF, 13 KB for WebP) but AVIF does more with it &#8211; preserving more genuine detail such as in the camera lens and IR sensor even while doing a better job of removing the JPEG artefacts (noise, blockiness, and banding).</p>



<div class="alignnormal"><div id="metaslider-id-7188" style="max-width: 849px; margin: 0 auto;" class="ml-slider-3-107-0 metaslider metaslider-flex metaslider-7188 ml-slider ms-theme-default nav-hidden nav-hidden nav-hidden nav-hidden" role="region" aria-label="AVIF vs WebP for reducing JPEG artefacts" data-height="538" data-width="849">
    <div id="metaslider_container_7188">
        <div id="metaslider_7188" class="flexslider">
            <ul class='slides'>
                <li style="display: block; width: 100%;" class="slide-7196 ms-image " aria-roledescription="slide" data-date="2023-12-30 16:52:16" data-filename="Blink-XT.png" data-slide-type="image"><img loading="lazy" decoding="async" width="849" height="538" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT.png" class="slider-7188 slide-7196 msDefaultImage" alt="" rel="" title="Blink-XT" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT.png 849w, https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-256x162.png 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-512x324.png 512w" sizes="auto, (max-width: 849px) 100vw, 849px" /><div class="caption-wrap"><div class="caption">Original, full of JPEG artefacts</div></div></li>
                <li style="display: none; width: 100%;" class="slide-7195 ms-image " aria-roledescription="slide" data-date="2023-12-30 16:52:16" data-filename="Blink-XT-60.webp" data-slide-type="image"><img loading="lazy" decoding="async" width="849" height="538" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-60.webp" class="slider-7188 slide-7195 msDefaultImage" alt="" rel="" title="Blink-XT (60)" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-60.webp 849w, https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-60-256x162.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-60-512x324.webp 512w" sizes="auto, (max-width: 849px) 100vw, 849px" /><div class="caption-wrap"><div class="caption">WebP</div></div></li>
                <li style="display: none; width: 100%;" class="slide-7194 ms-image " aria-roledescription="slide" data-date="2023-12-30 16:52:15" data-filename="Blink-XT-30.avif" data-slide-type="image"><img loading="lazy" decoding="async" width="849" height="538" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-30.avif" class="slider-7188 slide-7194 msDefaultImage" alt="" rel="" title="Blink-XT (30)" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-30.avif 849w, https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-30-256x162.avif 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Blink-XT-30-512x324.avif 512w" sizes="auto, (max-width: 849px) 100vw, 849px" /><div class="caption-wrap"><div class="caption">AVIF</div></div></li>
            </ul>
        </div>
        
    </div>
</div></div>



<p>While generally I avoid re-compressing from an already lossy source since it tends to just compound the compression artefacts, AVIF can be useful for replacing low-quality JPEGs when you don&#8217;t have a quality original available.  It can actually <em>improve</em> subjective image quality &#8211; by correcting JPEG artefacts &#8211; even while substantially shrinking the file size.</p>



<h1 class="wp-block-heading">Image format conversion</h1>



<p>There&#8217;s basically two schools of thought on converting images to their serving format &#8211; do it in advance of uploading the image to WordPress, or have WordPress do it (via one or more plug-ins).  I prefer the former as:</p>



<ol class="wp-block-list">
<li>I have more control over the images by doing the conversion myself.
<ul class="wp-block-list">
<li>I can pick the best format for each situation.</li>



<li>I can customise compression settings to suit the situation (e.g. use more aggressive compression if the source image isn&#8217;t high quality to begin with) and use (e.g. use lossless for images which are about comparing image formats, RAW converters, or other such situations where viewers need to see the image <em>exactly</em>).</li>
</ul>
</li>



<li>I have more reliably-available computing horsepower locally; I can run pretty much any conversion or optimisation process and it&#8217;ll just work.  In contrast, WordPress-hosted processing is subject to various limits on runtime and RAM usage, which can cause things to fail in all sorts of ways both obvious and nefarious.  Most web servers [used for WordPress sites] have <em>way</em> less RAM available than even an entry-level personal computer.  Processing of &#8220;large&#8221; images, such as photos from a camera, <em>will</em> fail with default WordPress &amp; PHP settings.</li>



<li>Every additional WordPress plug-in increases the possibility of problems, whether due to bugs in the plug-in, the possibility of incompatibilities between plug-ins, etc.</li>



<li>WordPress plug-ins don&#8217;t always age well; each one I adopt is yet another plug-in which I might have to migrate off of in future.</li>



<li>WordPress plug-ins for image format conversion &amp; optimisation tend, in my experience, to be both buggy and money-grubbing.  Many are tied to 3rd party services like CDNs or &#8220;Cloud&#8221;-based image processing, and try to lock you into pricey and unnecessary paid subscriptions.</li>
</ol>



<p>Nominally having WordPress do it means you can just upload any random image without care for its format or compression, <em>and</em> that over time you can easily adopt new image formats just by installing new plug-ins, with all existing images converted retroactively.  In reality, new image formats come along very rarely and popular ones &#8211; like PNG, JPEG and WebP &#8211; are supported basically forever.</p>



<p>You do have to be a little careful, however, to not over-compress your original uploads (or, retain higher-quality versions locally).  Especially if you&#8217;re churning through image conversions &amp; uploads rapidly, you might not immediately notice compression artefacts.  Having the original available in order to redo the compression is valuable.</p>



<h2 class="wp-block-heading">Advance conversion</h2>



<p>There&#8217;s a further choice as to whether you do the processing locally or use a website.  I prefer to just do it locally, for some of the same reasons as not using WordPress, and <em>also</em> because in my experience I can achieve better results &#8211; websites that do image conversion / recompression, <em>especially</em> those that do it for free, use weak compression in order to minimise processing time, and consequently do not achieve the best results.</p>



<p>The best tool I&#8217;ve found for local image processing is <a href="https://apps.apple.com/us/app/image-tool/id1524216218" data-wpel-link="external" target="_blank" rel="external noopener">Image Tool+</a>.  It supports all the formats you&#8217;ll likely need and is designed for easy batch conversions.</p>



<div class="wp-block-group"><div class="wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained">
<p>⚠️ While Image Tool+ <em>mostly</em> supports animated images, it does <em>not</em> support animated AVIFs.  It will silently remove animation from any AVIFs it creates.</p>



<p>Beyond that, though, I&#8217;ve found that it does a surprisingly poor job of producing animated images, no matter what format you use &#8211; the resulting files are <em>huge</em>.  You can get <em>much</em> better results with other tools (e.g. <a href="https://ezgif.com/gif-to-avif" data-wpel-link="external" target="_blank" rel="external noopener">EZGIF</a> albeit with no control over the quality).</p>
</div></div>


<div class="wp-block-image">
<figure class="aligncenter size-full"><img loading="lazy" decoding="async" width="1277" height="832" src="https://wadetregaskis.com/wp-content/uploads/2023/12/Image-Tool.webp" alt="Screenshot of the Image Tool+ main window, showing a bunch of image format conversions in progress" class="wp-image-7149" srcset="https://wadetregaskis.com/wp-content/uploads/2023/12/Image-Tool.webp 1277w, https://wadetregaskis.com/wp-content/uploads/2023/12/Image-Tool-256x167.webp 256w, https://wadetregaskis.com/wp-content/uploads/2023/12/Image-Tool-512x334@2x.webp 1024w, https://wadetregaskis.com/wp-content/uploads/2023/12/Image-Tool-512x334.webp 512w, https://wadetregaskis.com/wp-content/uploads/2023/12/Image-Tool@2x.webp 2554w" sizes="auto, (max-width: 1277px) 100vw, 1277px" /><figcaption class="wp-element-caption">The user interface is a little clunky &#8211; with some odd but harmless rendering issues occasionally, as seen in the left hand column &#8211; but ultimately it&#8217;s functional, and does a better job than any other apps I&#8217;ve found.</figcaption></figure>
</div>


<p>In years gone by I used <a href="https://www.lemkesoft.de/en/products/graphicconverter/" data-wpel-link="external" target="_blank" rel="external noopener">GraphicConverter</a>, but it doesn&#8217;t support AVIF.</p>



<p>It&#8217;s important to note that the PNG files produced by Image Tool+ are not very efficiently compressed &#8211; you should run them through ImageOptim if you actually intend to use them.</p>



<h1 class="wp-block-heading">Publishing images in WordPress</h1>



<p>WordPress supports <em>some</em> image formats natively, and does a passable job of handling them by default.  So you don&#8217;t <em>have</em> to do anything additional, necessarily.  However, there&#8217;s several plug-ins I recommend which significantly improve its capabilities.</p>



<h2 class="wp-block-heading" id="avif-support"><a href="https://wordpress.org/plugins/avif-support/" data-wpel-link="external" target="_blank" rel="external noopener">AVIF Support</a></h2>



<p>As it says on the tin, it adds support for AVIF to WordPress, which sadly lacks support otherwise.  Without this plug-in, WordPress will simply refuse to accept AVIF uploads.</p>



<p>It&#8217;s free, <a href="https://plugins.trac.wordpress.org/browser/avif-support/" data-wpel-link="external" target="_blank" rel="external noopener">open source</a>, and works pretty seamlessly, as long as your web server and WordPress installation are sufficiently modern.  The easiest way to determine if that&#8217;s the case it to simply install the plug-in &#8211; its Settings page will tell you if AVIF is supported or not.  If it&#8217;s not, only then will you need to do some package upgrading.  In particular, you need (as best I can tell from experience and what I&#8217;ve read online):</p>



<ul class="wp-block-list">
<li><a href="https://grandplugins.com/how-to-upload-avif-images-in-wordpress/" data-wpel-link="external" target="_blank" rel="external noopener">PHP 8.2 (or later)</a>.</li>



<li><a href="https://php.watch/versions/8.1/gd-avif" data-wpel-link="external" target="_blank" rel="external noopener">libavif and suitably-compiled versions of GD and PHP</a>.</li>



<li><a href="https://web.archive.org/web/20240104012918/https://avif.io/blog/tutorials/imagemagick/" data-wpel-link="external" target="_blank" rel="external noopener">ImageMagick 7.0.25 (or later)</a><br><br>…<em>or</em> <a href="https://legacy.imagemagick.org" data-wpel-link="external" target="_blank" rel="external noopener">ImageMagick 6</a> with a suitably new and compiled <a href="https://github.com/strukturag/libheif" data-wpel-link="external" target="_blank" rel="external noopener">libheif</a> w/ AVIF support.  I haven&#8217;t been able to pin down specific version numbers, and it might vary by package repo (as libheif has to be compiled with certain flags to include the AVIF support).  In a nutshell you can tell if your system has it by following the dependency graph from your libmagickcore-6… library (via <code>apt info &lt;package></code> or similar) and seeing if it includes libheifN with in turn an [installed] dependency on svt-av1 or libaomN.  Where &#8216;N&#8217; may be any number.<br><br>Note: ImageMagick 6 doesn&#8217;t support alpha channels in AVIF images (see <a href="#avif-bug-alpha-channels">Bug: Alpha channels</a>, below).  So use ImageMagick 7 if possible.</li>
</ul>



<p>Even though all those versions are quite old, <a href="https://wadetregaskis.com/migrated-hosts-out-of-the-subdomain/" data-wpel-link="internal">I actually had to switch web hosts in order to get them</a>, as you&#8217;d be sadly surprised how many WordPress hosting services are running wildly ancient versions of Linux (kernel &amp; distro) and PHP.  Now that I have my own Linux VPS, however, it was quite trivial &#8211; I basically just used <code>apt</code> and <a href="https://www.plesk.com" data-wpel-link="external" target="_blank" rel="external noopener">Plesk</a> to install the latest versions of all the relevant software (which you should be frequently doing anyway, for security patches and bug fixes).  Although sadly that still only gets me ImageMagick 6 (and an outdated GD that doesn&#8217;t support AVIF) &#8211; Plesk PHP builds are pretty far behind, and Ubuntu doesn&#8217;t officially support ImageMagick 7 at all! 😠</p>



<p>Note that you only need <em>one</em> of GD or ImageMagick to have the necessary AVIF support, which is fortunate in case one of the two is difficult to upgrade with your particular system (such as if you use Plesk).</p>



<p>ImageMagick is apparently superior:</p>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow">
<p>It&#8217;s recommended though to use Imagick lib. It gives way better results in terms of speed, quality and size.</p>
<cite>AVIF Support author (<a href="https://grandplugins.com" data-wpel-link="external" target="_blank" rel="external noopener">GrandPlugins</a>)</cite></blockquote>



<p>I haven&#8217;t tested that claim myself, but you&#8217;ll find it repeated in numerous places online, and not just in the context of AVIF.  It sounds like the common wisdom is that GD just isn&#8217;t very good<sup data-fn="416556d8-6d2c-4a41-9401-e301838a8bb7" class="fn"><a href="#416556d8-6d2c-4a41-9401-e301838a8bb7" id="416556d8-6d2c-4a41-9401-e301838a8bb7-link">3</a></sup>.</p>



<h3 class="wp-block-heading"><s>Bug: AVIF over-compression</s></h3>



<p><s>At time of writing, it has a bug whereby it doesn&#8217;t respect image quality settings, neither the WordPress defaults nor any customisation you might do with other plug-ins.  Instead, it always uses a 30% quality setting for AVIF compression (e.g. for thumbnails) which often results in noticeable visual artefacts from the over-compression.  I&#8217;ve reported this to the developer and 🤞 they address this soon, as it looks like a trivial one-line patch.</s></p>



<p><em>Update</em>: the plug-in author fixed this in version 1.0.5, January 2nd 2024.  As a bonus they also added plug-in settings for specifying the desired image quality and (for GD) &#8216;speed&#8217; (how hard the AVIF encoder tries, trading off compression speed for effectiveness).</p>



<h3 class="wp-block-heading" id="avif-bug-alpha-channels">Bug: Alpha channels</h3>



<p><a href="https://alexwlchan.net/2023/check-for-transparency/" data-wpel-link="external" target="_blank" rel="external noopener">AVIFs with alpha channels don&#8217;t work with ImageMagick 6</a>, at time of writing &#8211; any time WordPress re-encodes the image, such as for thumbnail generation, it removes the alpha channel.  Typically this results in the transparent sections turning black instead.</p>



<p><s>For now, I use WebP when transparency is involved, as I&#8217;m hamstrung by Plesk&#8217;s lack of support for ImageMagick 7 in their PHP packages. 😕</s></p>



<p>I ultimately upgraded to ImageMagick 7 to fix this bug.  See <a href="https://wadetregaskis.com/how-to-install-imagemagick-7-for-wordpress-under-plesk-obsidian-on-ubuntu-22-04/" data-wpel-link="internal">my upgrade guide</a> if you&#8217;re on Ubuntu or using Plesk, or otherwise can&#8217;t seem to get ImageMagick 7 from your normal package management process.</p>



<h3 class="wp-block-heading">CDN incompatibility</h3>



<p>Note that some CDNs <em>still</em> don&#8217;t support AVIF, and there&#8217;s nothing the AVIF Support plug-in can do about that.  You might be using such a CDN without even realising it &#8211; e.g. the popular <a href="https://wordpress.org/plugins/jetpack/" data-wpel-link="external" target="_blank" rel="external noopener">Jetpack</a> plug-in secretly uses the wp.com CDN, so AVIF images don&#8217;t work in some places, such as Jetpack&#8217;s &#8220;Related posts&#8221; feature.  Alas there&#8217;s not much you can do other than not use such broken CDNs &#8211; nor plug-ins that rely on them, like Jetpack.</p>



<p>In general you don&#8217;t want to use such CDNs anyway, because their lack of support for AVIF &#8211; or any other content format &#8211; is usually only a result of them mucking with your images in some way.  Not all CDNs are bad, though &#8211; e.g. <a href="https://www.cloudflare.com/" data-wpel-link="external" target="_blank" rel="external noopener">Cloudflare</a> has no issues with AVIF because they don&#8217;t try to mess with your files.</p>



<h2 class="wp-block-heading" id="enable-media-replace"><a href="https://wordpress.org/plugins/enable-media-replace/" data-wpel-link="external" target="_blank" rel="external noopener">Enable Media Replace</a></h2>



<p>This lets you replace an existing image without breaking any use of it in existing posts, pages, etc.  <em>Including with a different file format</em>.  That latter detail is something most competing image replacement plug-ins do <em>not</em> support [reliably], but it&#8217;s crucial if you want to upgrade any existing images on your website.</p>



<p>It&#8217;s free and <a href="https://github.com/short-pixel-optimizer/enable-media-replace" data-wpel-link="external" target="_blank" rel="external noopener">open source</a>.</p>



<h2 class="wp-block-heading" id="image-regenerate-and-select-crop"><a href="https://iuliacazan.ro/image-regenerate-select-crop/" data-wpel-link="external" target="_blank" rel="external noopener">Image Regenerate &amp; Select Crop</a></h2>



<p>This lets you perform a bunch of helpful little things, including:</p>



<ul class="wp-block-list">
<li>You can define custom image &#8220;thumbnail&#8221; sizes (and modify WordPress&#8217;s defaults), which can be handy for tailoring your images to your actual presentation sizes.  The WordPress defaults are pretty arbitrary and typically don&#8217;t match what your theme desires, let-alone any other plug-ins&#8217; needs (such as for galleries, slideshows, etc).</li>



<li>You can adjust the default image compression quality setting (for each thumbnail size individually).<br><br>Note however that this doesn&#8217;t always apply, e.g. currently the <a href="#avif-support">AVIF Support</a> plug-in has a bug whereby it ignores this setting.  The setting seems to work for the built-in-supported image formats, though, like JPEG and WebP.</li>



<li>You can manually delete or [re]generate thumbnails in each of the possible sizes, for images both individually or en masse.  This can be handy if you change relevant settings (like compression quality, above) or in debugging situations (such as if you&#8217;re experimenting with other image plug-ins and they muck up your thumbnails).</li>
</ul>



<p>It&#8217;s free (albeit with optional paid &#8216;advanced&#8217; features).</p>



<h2 class="wp-block-heading"><a href="https://meowapps.com/wp-retina-2x/" data-wpel-link="external" target="_blank" rel="external noopener">Perfect Images</a></h2>



<p>It&#8217;s baffling that <em>to this day</em> WordPress doesn&#8217;t support modern displays &#8211; and I use &#8216;modern&#8217; in a very liberal sense, since we&#8217;re talking circa 2010 onwards.  That is, displays designed with a high pixel density that use a non-1-to-1 ratio of points to pixels.  i.e. any smartphone or quality computer display in the last decade.</p>



<p>The result is images that render at a quarter (or worse) of full resolution, looking pixelated or soft.</p>



<p>If you care enough about image quality to even consider what image formats or compression settings you&#8217;re using, you absolutely should be using Perfect Images.</p>



<p>Basically it fixes &amp; extends WordPress&#8217;s image support to &#8211; mostly automagically and invisibly &#8211; just work with full-resolution images.  It&#8217;s particularly noticeable and essential for things like screenshots, or any images containing text, as those are especially obvious if rendered incorrectly.</p>



<p>Its core functionality is free &#8211; and you can get a fair way with just the free version &#8211; but <a href="https://meowapps.com/products/wp-retina-2x-pro/" data-wpel-link="external" target="_blank" rel="external noopener">the pro version</a> is worth it, even if a bit pricey.</p>



<h3 class="wp-block-heading">Usage tips</h3>



<h4 class="wp-block-heading">Fix WordPress&#8217;s image size limit</h4>



<p>Make sure to check the &#8220;Image Threshold … Disable&#8221; checkbox in the General settings.  This fixes a truly obnoxious WordPress bug whereby it mangles uploads of large images.</p>



<h4 class="wp-block-heading">Upload &#8216;Retina&#8217; images specially</h4>



<p>For images which are explicitly &#8220;2x&#8221; &#8211; such as screenshots &#8211; it&#8217;s important to upload them &#8216;manually&#8217; using Media &gt; Add New Media File, as opposed to e.g. just drag-and-dropping them into a post.  The plug-in adds an &#8220;Upload New Retina Image&#8221; option to the dedicated upload page, which registers the uploaded image with WordPress at technically a quarter of its actual size.  That basically tricks WordPress into using the <em>correct</em> dimensions for the image &#8211; otherwise, WordPress mistakes the <em>pixel</em> dimensions for the <em>point</em> dimensions, and will naively try to display the image at four times its natural size.</p>



<p>Don&#8217;t worry, Perfect Images preserves the real, full-resolution version as the &#8220;2x&#8221; version of the upload, and will display that instead to your visitors.</p>



<p>This particular upload method is the <em>only</em> way to get images to render correctly in all cases.  In some places &#8211; e.g. embedded in posts &#8211; you can manually specify the correct image dimensions, but that&#8217;s both tedious and error-prone, and not possible in all uses.</p>



<p>The only caveat is that those images will look ugly and blurry in the post &amp; page editors.  Don&#8217;t worry, they&#8217;ll render correctly in the actual published (and preview) version of your posts &amp; pages.</p>



<p>For images which don&#8217;t have an intrinsic pixel density &#8211; such as photos &#8211; you typically don&#8217;t have to worry about this, as you&#8217;ll usually just let them render at whatever size the viewport &amp; layout permit, up to their natural full size.</p>



<h3 class="wp-block-heading">Limitations</h3>



<p>The core functionality works reliably in my experience (over <em>many</em> years now), but some of the peripheral features are broken or notably buggy:</p>



<ul class="wp-block-list">
<li>Image replacement will <em>not</em> work correctly if the file format changes &#8211; and it won&#8217;t even recognise this case and prevent it, instead leaving you with broken images.  Use <a href="#enable-media-replace">Enable Media Replace</a> for this instead.</li>



<li>Batch regeneration of thumbnails doesn&#8217;t work reliably &#8211; it will silently fail midway if an error occurs, such as it encountering a video file.  Use <a href="#image-regenerate-and-select-crop">Image Regenerate &amp; Select Crop</a> for this instead.</li>



<li>Custom Image Sizes don&#8217;t work correctly &#8211; they <em>always</em> force cropping of the image (&#8220;resize to fill&#8221;), rather than resizing to fit.  This is almost never what you want.  Use <a href="#image-regenerate-and-select-crop">Image Regenerate &amp; Select Crop</a> for this instead.</li>



<li>For the Pro version [only], auto-update doesn&#8217;t work.  You have to periodically check the website for new versions.</li>



<li>It sometimes reports &#8220;issues&#8221; for images, in its special dashboard under the Media section, when there aren&#8217;t any.  This is of course pretty insignificant &#8211; you can just ignore it &#8211; although it might hide any <em>actual</em> issues if they occur.  I did find a way to clear these bogus issues, but it involved manually deleting all thumbnails for all my images and regenerating them, which was a bit of an ordeal due to other, aforementioned bugs.  So I don&#8217;t recommend mucking with it.</li>
</ul>


<ol class="wp-block-footnotes"><li id="ce19f9a1-4b3d-427c-b205-ec8684b1e5ae">Note that <a href="https://nokiatech.github.io/heif/technical.html" data-wpel-link="external" target="_blank" rel="external noopener">HEIF <em>does</em> support lossless encoding</a> but support for this amongst actual encoding applications is poor to non-existent.  As such it&#8217;s generally not a suitable replacement for PNG in practice. <a href="#ce19f9a1-4b3d-427c-b205-ec8684b1e5ae-link" aria-label="Jump to footnote reference 1">↩︎</a></li><li id="42530c0c-bed1-4a7a-bff8-2c27f0a337bd">As the matrix shows, no version of <a href="https://en.wikipedia.org/wiki/Internet_Explorer" data-wpel-link="external" target="_blank" rel="external noopener">Internet Explorer</a> supports WebP.  But &#8211; though there apparently <em>is</em> some non-trivial number of people still using it &#8211; I don&#8217;t consider Internet Explorer a browser of concern anymore, given it has an official and straightforward successor in <a href="https://en.wikipedia.org/wiki/Microsoft_Edge" data-wpel-link="external" target="_blank" rel="external noopener">Edge</a>, and <a href="https://en.wikipedia.org/wiki/Internet_Explorer#Internet_Explorer_11" data-wpel-link="external" target="_blank" rel="external noopener">its last version was released <em>a decade ago</em> in 2013</a>. <a href="#42530c0c-bed1-4a7a-bff8-2c27f0a337bd-link" aria-label="Jump to footnote reference 2">↩︎</a></li><li id="416556d8-6d2c-4a41-9401-e301838a8bb7">Although for image compression, specifically, this is odd, since there&#8217;s only a couple of underlying libraries they could possibly be using, and while <a href="https://github.com/strukturag/libheif/wiki/AVIF-Encoder-Benchmark" data-wpel-link="external" target="_blank" rel="external noopener">they do vary significantly in speed</a> they should produce very similar outputs. <a href="#416556d8-6d2c-4a41-9401-e301838a8bb7-link" aria-label="Jump to footnote reference 3">↩︎</a></li></ol>]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/image-workflow-for-wordpress/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			<media:content url="https://wadetregaskis.com/wp-content/uploads/2023/12/Image-Tool.webp" medium="image" />
<post-id xmlns="com-wordpress:feed-additions:1">7146</post-id>	</item>
		<item>
		<title>Migrated hosts &#038; out of the subdomain</title>
		<link>https://wadetregaskis.com/migrated-hosts-out-of-the-subdomain/</link>
					<comments>https://wadetregaskis.com/migrated-hosts-out-of-the-subdomain/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Tue, 28 Nov 2023 03:53:25 +0000</pubDate>
				<category><![CDATA[Meta]]></category>
		<category><![CDATA[Cyberduck]]></category>
		<category><![CDATA[DNS]]></category>
		<category><![CDATA[Gandi.net]]></category>
		<category><![CDATA[IONOS]]></category>
		<category><![CDATA[TLS]]></category>
		<category><![CDATA[Transmit]]></category>
		<category><![CDATA[UpdraftPlus]]></category>
		<category><![CDATA[VPS]]></category>
		<category><![CDATA[webhosting]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://wadetregaskis.com/?p=5896</guid>

					<description><![CDATA[Mainly just a note for posterity &#8211; after many years of wanting to do it but procrastinating, I&#8217;ve finally migrated to a new web host. While I was doing that, I figured it was high time to drop the subdomain, so now it&#8217;s just https://wadetregaskis.com, instead of https://blog.wadetregaskis.com. Blogs are so last year. Previously I&#8230; <a class="read-more-link" href="https://wadetregaskis.com/migrated-hosts-out-of-the-subdomain/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[
<p>Mainly just a note for posterity &#8211; after many years of wanting to do it but procrastinating, I&#8217;ve finally migrated to a new web host.</p>



<p>While I was doing that, I figured it was high time to drop the subdomain, so now it&#8217;s just <a href="https://wadetregaskis.com" data-wpel-link="internal">https://wadetregaskis.com</a>, instead of <a href="https://blog.wadetregaskis.com" data-wpel-link="internal">https://blog.wadetregaskis.com</a>.  Blogs are <em>so</em> last year.</p>



<p>Previously I was using <a href="https://www.gandi.net" data-type="link" data-id="https://www.gandi.net" data-wpel-link="external" target="_blank" rel="external noopener">Gandi.net</a> (I recall choosing them because they were touted as a particularly privacy-centric host) <a href="https://www.gandi.net/en-AU/simple-hosting" data-wpel-link="external" target="_blank" rel="external noopener">shared webhosting</a>.  I&#8217;m now using an <a href="https://www.ionos.com/servers/vps" data-wpel-link="external" target="_blank" rel="external noopener">unmanaged VPS</a> from <a href="https://www.ionos.com" data-wpel-link="external" target="_blank" rel="external noopener">IONOS</a>.  This is far superior &#8211; site performance is much higher, I can finally use modern web technologies like TLS 1.3 and AVIF<sup data-fn="e357962a-2622-48d7-a0a8-7a1f62278e12" class="fn"><a href="#e357962a-2622-48d7-a0a8-7a1f62278e12" id="e357962a-2622-48d7-a0a8-7a1f62278e12-link">1</a></sup>, and frankly it&#8217;s just deeply satisfying to have a whole [virtual] machine at my disposal.  It might be a gateway to bigger things.</p>



<p>I chose IONOS because they offered the best apparent value amongst hosts that seemed well-reviewed.  I&#8217;m now paying just a <em>third</em> of what I was at Gandi.net (for what amounts to at least 2x the CPU performance and 4x the RAM!).  They also include a full copy of <a href="https://www.plesk.com" data-wpel-link="external" target="_blank" rel="external noopener">Plesk</a>, which has proven a net win in getting everything set up and configured &#8211; notwithstanding some serious initial issues with it, that ended up requiring me to reimage the whole VM and restart from scratch. 😒</p>



<p>The process took over two full days, partly because of the aforementioned Plesk issue which cost me nearly a full day by itself, and otherwise because of just a whole bunch of issues along the way.  e.g.:</p>



<ul class="wp-block-list">
<li>File transfers (via HTTPS or SFTP) to &amp; from Gandi are slow.  They always have been &#8211; it&#8217;s one of several things that always bothered me about Gandi.</li>



<li>TCP connections to Gandi tend to get killed if they hang around for any significant amount of time (such as for large file transfers over HTTPS or SFTP<sup data-fn="9a5ac91a-c7ce-450d-9d7e-d2f7434e5772" class="fn"><a href="#9a5ac91a-c7ce-450d-9d7e-d2f7434e5772" id="9a5ac91a-c7ce-450d-9d7e-d2f7434e5772-link">2</a></sup>).
<ul class="wp-block-list">
<li>This in turn exacerbated a few bugs in <a href="https://cyberduck.io" data-wpel-link="external" target="_blank" rel="external noopener">Cyberduck</a> whereby automatic retries don&#8217;t work <em>and</em> I had to manually relaunch Cyberduck completely between retries (otherwise it locked up).<br><br>I partly addressed this by using <a href="https://panic.com/transmit/" data-wpel-link="external" target="_blank" rel="external noopener">Transmit</a> instead, which isn&#8217;t <em>entirely</em> immune to Gandi&#8217;s bugginess but seemed to hit it <em>much</em> less often.  And is also a much more elegant application, in any case.</li>



<li>Combined with the general slowness, this meant it took most of an entire day to copy out the compressed copy of the old site &#8211; which was just a few gigabytes.</li>
</ul>
</li>



<li>I struggled to find a good way to migrate the site <em>before</em> committing to the actual domain name migration.  I had never migrated a WordPress site between hosts &#8211; never even restored in-place from an existing backup &#8211; so I had no real idea to what degree it would work.<br><br>This would have been easier without TLS.  I long-ago enabled HSTS for my site, and I technically could have worked around that in various ways, but no matter which approach I took I think it would have been challenging.<br><br>Ultimately I just got too frustrated and said &#8220;screw it, I&#8217;ll switch the domain name and <em>then</em> figure out how to move WordPress&#8221;.  Thankfully almost nobody visits this site, so breaking it for a day or so was inconsequential.
<ul class="wp-block-list">
<li>I made this slightly harder on myself by insisting on a &#8220;proper&#8221; TLS certificate for the new host &#8211; and therefore from IONOS since they include one free with each VPS &#8211; rather than using <a href="https://letsencrypt.org" data-wpel-link="external" target="_blank" rel="external noopener">Let&#8217;s Encrypt</a> (support for which is provided by a pre-installed <a href="https://www.plesk.com/extensions/letsencrypt/" data-wpel-link="external" target="_blank" rel="external noopener">extension</a> to Plesk).  IONOS&#8217;s control dashboard didn&#8217;t particularly want to issue the certificate while non-IONOS nameservers were used for the domain, although eventually I coaxed it into doing so.</li>
</ul>
</li>



<li>It took a while to figure out how DNS needed to be configured, between the old host (and registrar), the new host, and Cloudflare.  DNS isn&#8217;t <em>that</em> complicated in principle, I just wasn&#8217;t all that familiar with it.  I&#8217;ve added TXT records before and done a few other tweaks, but nothing of the complexity of multiple intertwined nameservers and non-trivial subdomain routing.<br><br>Although in retrospect having Cloudflare in front of everything perhaps made it easier since ultimately I just had to change settings there, as opposed to having to move nameservers.
<ul class="wp-block-list">
<li>DNS propagation delays were a significant irritation and cause of substantial delays.  After several key changes, I had no choice but to wait an indeterminate number of hours before I could see their effects and move on to subsequent steps.
<ul class="wp-block-list">
<li>macOS bugs whereby it ignores the last entry in <code>/etc/hosts</code><sup data-fn="bb84bf6a-f6e4-4802-98c5-84b06ed2ef00" class="fn"><a href="#bb84bf6a-f6e4-4802-98c5-84b06ed2ef00" id="bb84bf6a-f6e4-4802-98c5-84b06ed2ef00-link">3</a></sup> also didn&#8217;t help.</li>
</ul>
</li>
</ul>
</li>



<li><a href="https://updraftplus.com" data-wpel-link="external" target="_blank" rel="external noopener">UpdraftPlus</a> kept failing to restore the new site from a backup of the old (ultimately it turned out to be an OOM-killing problem, easily fixed by <a href="https://www.digitalocean.com/community/tutorials/how-to-add-swap-space-on-ubuntu-22-04" data-wpel-link="external" target="_blank" rel="external noopener">enabling some swap space</a>).</li>



<li>Many miscellaneous bugs in Plesk, half of which I&#8217;ve already successfully repressed, but as merely a few examples:
<ul class="wp-block-list">
<li>Plesk&#8217;s <a href="https://www.plesk.com/wp-toolkit/" data-wpel-link="external" target="_blank" rel="external noopener">WP Toolkit</a> extension <em>believes</em> it can set up a crontab entry to poke <code>wp-cron.php</code> periodically, but it can&#8217;t (because apparently you can&#8217;t invoke that directly via <code>php</code>, you have to actually go through Apache with a real HTTPS request &#8211; I never got to the bottom of why).</li>



<li>Sendmail / postfix don&#8217;t work out of the box with Plesk; WordPress &amp; Plesk just silently fail to send emails.  I never found any way to get them to log their failures, but I did ultimately get it working through trial-and-error (and I can&#8217;t even say what specific configuration change(s) actually fixed it).
<ul class="wp-block-list">
<li>It also took a while to figure out how to properly set up DKIM, SPF, and DMARC, although that was relatively straightforward once I found <a href="https://docs.plesk.com/en-US/obsidian/administrator-guide/mail/antispam-tools/dkim-spf-and-dmarc-protection.59433" data-wpel-link="external" target="_blank" rel="external noopener">this documentation</a>.</li>
</ul>
</li>



<li>After using Plesk and staying logging in just fine for over a day, on multiple computers, it suddenly decided it would log me out instantly almost every time.  This is <a href="https://duckduckgo.com/?q=plesk+logs+me+out+immediately" data-wpel-link="external" target="_blank" rel="external noopener">apparently a common issue</a>, and through sheer stubbornness of countless login cycles I was able to get to the &#8220;Allow IP address changes during a single session&#8221; checkbox, which fixed it for me.</li>
</ul>
</li>
</ul>



<p>I&#8217;m glad it&#8217;s done, and there is a solid sense of satisfaction with having conquered the litany of bugs, design flaws, and limitations throughout the whole process.</p>



<p>But I really hope I don&#8217;t have to move hosts again anytime soon.</p>


<ol class="wp-block-footnotes"><li id="e357962a-2622-48d7-a0a8-7a1f62278e12">…because I can install modern versions of basic tools &amp; libraries, like curl and ImageMagick, that support things like TLS 1.3 and AVIF. <a href="#e357962a-2622-48d7-a0a8-7a1f62278e12-link" aria-label="Jump to footnote reference 1">↩︎</a></li><li id="9a5ac91a-c7ce-450d-9d7e-d2f7434e5772">Made worse by Gandi&#8217;s weird SSH server being incompatible with rsync, thus forcing the use of all-or-nothing transfers over SFTP. <a href="#9a5ac91a-c7ce-450d-9d7e-d2f7434e5772-link" aria-label="Jump to footnote reference 2">↩︎</a></li><li id="bb84bf6a-f6e4-4802-98c5-84b06ed2ef00">It always ignores the last line of the file, so you have to explicitly add a trailing line return.  This is actually not uncommon with Unix tools of a certain pedigree, from before good design, robustness, and user-friendliness were values. <a href="#bb84bf6a-f6e4-4802-98c5-84b06ed2ef00-link" aria-label="Jump to footnote reference 3">↩︎</a></li></ol>]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/migrated-hosts-out-of-the-subdomain/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">5896</post-id>	</item>
		<item>
		<title>Yay!  An actual outage!  I&#8217;m a real blog now!</title>
		<link>https://wadetregaskis.com/yay-an-actual-outage-im-a-real-blog-now/</link>
					<comments>https://wadetregaskis.com/yay-an-actual-outage-im-a-real-blog-now/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Thu, 31 Mar 2016 17:08:31 +0000</pubDate>
				<category><![CDATA[Meta]]></category>
		<category><![CDATA[Bugs!]]></category>
		<category><![CDATA[crashtastic]]></category>
		<category><![CDATA[lies]]></category>
		<category><![CDATA[Site down!]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://blog.wadetregaskis.com/?p=3614</guid>

					<description><![CDATA[I woke up this morning to find that my website &#8211; this one &#8211; had gone down only a few minutes earlier.  The host&#8217;s website, Gandi.net, was acting flaky and not letting me log in either, so I figured it was a widespread issue on their end. A few hours later, Gandi.net was working again,&#8230; <a class="read-more-link" href="https://wadetregaskis.com/yay-an-actual-outage-im-a-real-blog-now/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[<p>I woke up this morning to find that my website &#8211; this one &#8211; had gone down only a few minutes earlier.  The host&#8217;s website, Gandi.net, was acting flaky and not letting me log in either, so I figured it was a widespread issue on their end.</p>
<p>A few hours later, Gandi.net was working again, but my site wasn&#8217;t.  Sad panda.</p>
<p>Long story short, I used up all the disk space &#8211; and by &#8220;I&#8221;, I mean <em>something</em> &#8211; still haven&#8217;t figured out what, yet.  Apparently when you use up all the space, that simply kills the VM without any notification (their dashboard for my VM still claimed it was running just fine, no problems detected, which was obvious crap).</p>
<p>That said, their tech support identified the problem quickly and were ultimately able to rectify things for me (after first suggesting I delete some stuff myself, which I tried only to find that when your Gandi VM is wedged in this state, you can&#8217;t log in via SSH nor delete anything via SFTP, and those are your only two means for deleting any files…).</p>
<p>As far as I can recall, this is the first time my site&#8217;s actually been down in the ~four years I&#8217;ve hosted with them (other than a few errors on my part when messing with WordPress etc).</p>
]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/yay-an-actual-outage-im-a-real-blog-now/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3614</post-id>	</item>
		<item>
		<title>Four years &#038; time for a new theme</title>
		<link>https://wadetregaskis.com/four-years-time-for-a-new-theme/</link>
					<comments>https://wadetregaskis.com/four-years-time-for-a-new-theme/#respond</comments>
		
		<dc:creator><![CDATA[]]></dc:creator>
		<pubDate>Wed, 30 Mar 2016 02:31:25 +0000</pubDate>
				<category><![CDATA[Meta]]></category>
		<category><![CDATA[Bugs!]]></category>
		<category><![CDATA[Sad]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://blog.wadetregaskis.com/?p=3553</guid>

					<description><![CDATA[It&#8217;s been a bit over four years since I moved this blog off of the old statically-built site, by iBlog 2, to WordPress.  Apparently it&#8217;s time for an updated theme. Actually, Suffusion was pissing me off as per usual, and I accidentally applied a new theme when intending only to install it (apparently &#8216;Activating&#8217; a&#8230; <a class="read-more-link" href="https://wadetregaskis.com/four-years-time-for-a-new-theme/" data-wpel-link="internal">Read more</a>]]></description>
										<content:encoded><![CDATA[<p>It&#8217;s been a bit over four years since I moved this blog off of the old statically-built site, by iBlog 2, to WordPress.  Apparently it&#8217;s time for an updated theme.</p>
<p>Actually, Suffusion was pissing me off as per usual, and I accidentally applied a new theme when intending only to install it (apparently &#8216;Activating&#8217; a theme applies it, which is sensible in hindsight but not as clear as it should be given how plug-ins work).  Turns out, you can&#8217;t easily go back &#8211; changing themes permanently wipes out a bunch of settings.  #%@!</p>
<p>And as per usual the backups plug-in I have installed had silently wedged itself and failed to back anything up for a couple of months.  Sigh.</p>
<p>WordPress is kinda shit.  It&#8217;s a mess.  A complicated, slow, buggy mess.  If I actually cared to spend any more time on this site, I&#8217;d start by looking for another platform.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://wadetregaskis.com/four-years-time-for-a-new-theme/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3553</post-id>	</item>
	</channel>
</rss>
