Allow SVG uploads in WordPress

By Default WordPress denies the upload of SVG files via the media uploader. This can be fixed by adding the following code into the functions.php file.

function cc_mime_types($mimes) {
$mimes['svg'] = 'image/svg+xml';
return $mimes;
add_filter('upload_mimes', 'cc_mime_types');

How To: Leverage browser caching

If you are using google pagespeed to measure your site speed you might find it says you must leverage browser caching to improve your site speed.

Fairly simple job and fairly standard. All you need is to add a few lines of code to the .htaccess file which can be found in the root of your website files.

Open it by using filemanager in your cpanel or downloading – editing – and uploading it.

When opened go to the last line and on a new line add the following:

<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 month"
ExpiresByType text/html "access 1 month"
ExpiresByType application/pdf "access 1 month"
ExpiresByType text/x-javascript "access 1 month"
ExpiresByType application/x-shockwave-flash "access 1 month"
ExpiresByType image/x-icon "access 1 year"
ExpiresDefault "access 1 month"