A WordPress Starter Theme Based on Bootstrap 5

A WordPress starter them based on Bootstrap V5 and Underscores.

Continue reading "A WordPress Starter Theme Based on Bootstrap 5" ››

Prevent PDF Caching With Invoice Ninja 5 (Apache, .htaccess)

If you find that PDF files aren’t updating after changes, it could be that they are cached by the browser or a CDN such as Cloudflare.

If you are running on Apache then you can modify the mod_headers block in the /public/.htaccess file to prevent PDF file caching:

<IfModule mod_headers.c>
    # Blocks Search Engine Indexing
    Header set X-Robots-Tag "noindex, nofollow"

    # Prevents PDF File Caching
    <FilesMatch ".pdf$">
        Header set Cache-Control no-store
  </FilesMatch>
</IfModule>

Customising the Client Portal Colour In Invoiceninja 5

Customizing the invoiceninja V5 client portal colour scheme.

Continue reading "Customising the Client Portal Colour In Invoiceninja 5" ››

Extend Yoast Schema with a New Type

Yoast 11 introduced schema data added by default. If your site already has schema added through your theme then this may break. At the time of writing, the documentation only shows how to extend an existing type (Person), not add a new one. So here I am going to show how to add event data by adding a new piece to the tree.

Continue reading “Extend Yoast Schema with a New Type” ››

Remove Yoast HTML Comments in Version 11.0

If you were previously stripping Yoast HTML comments on your website then there is a good chance that updating to v11.0 will show the new schema data at the top of your website.

The problem is that a widely used snippet for stripping out the comments searched for the string ‘yoast’ and then removed the surrounding comment tags. The new schema data added in V11.0 uses the word ‘yoast’ as a class on the script tag, so the script tags get stripped and the schema data shows at the top of the website.

Continue reading “Remove Yoast HTML Comments in Version 11.0” ››

Add Joomla’s Article Layout as a Body Class

Posted in Joomla

If you are using Joomla’s alternative layouts for certain pages, you might want to target those pages with a css class.

You could add a class directly into the layout file, but since the layout file is inserted into the main component area this only lets you target that specific area and not the page as a whole.

Continue reading “Add Joomla’s Article Layout as a Body Class” ››

How to Stop Joomla 3 Loading Bootstrap 2 JavaScript

Posted in Joomla

It used to be easy to remove core JavaScript files from Joomla’s output by unsetting the script at the top of your template’s index file.

unset( $this->_scripts[ JURI::root( true ) . '/media/jui/js/bootstrap.min.js' ] );

For whatever reason, this doesn’t work anymore with Joomla 3.9.

Continue reading “How to Stop Joomla 3 Loading Bootstrap 2 JavaScript” ››

Block WordPress Image Uploads by Filename Match

Are you continually telling people to optimise their image filenames before uploading them to a website?

Do staff members keep assuring you that they will optimise their filenames in the future whilst having no intention of doing so?

Have they said “I’ll go back and do it later” rather than taking 2 seconds to do the job properly in the first place?

Then it’s time to start blocking their uploads so you don’t have to check up on them like a child 🙂 Continue reading “Block WordPress Image Uploads by Filename Match” ››

Securing ISPConfig Admin Panel the Easy Way

The latest ISPConfig hosting panel includes support for Let’s Encrypt free SSL certificates. This makes it easy to secure all domains added to the panel, but it doesn’t have an option to generate a cert for the actual control panel login.

Rather than manually installing and configuring a new cert through the command line, there is an easier option. Continue reading “Securing ISPConfig Admin Panel the Easy Way” ››

Better Mautic Opt-In Campaigns

How to create a double opt-in campaign with Mautic that instantly sends the confirmation email rather than waiting for a campaign to trigger.

Continue reading "Better Mautic Opt-In Campaigns" ››