We’ve been using one and one as our web host for a good few years now, we’ve got a couple of older servers which run and host quite a few older sites that were created using PHP 5. You might know that the latest versions of WordPress require at least PHP 5 to be running on your server before it will even install. here’s how i get round it..

Pretty simple it’s just the first two lines below placed in an .htacess file and uploaded in the root folder of a site. They bump up the server install from version 5 to version 6 meaning that older sites created with PHP 4 are untouched by the sly upgrade. Obviously the best practice would be to revisit these older sites and update the code accordingly but this solution solves the problem when your’re developing numerous sites rapidly.

I also add the other 2 sections to speed the site up for Google as it likes sites to run as fast as possible. Basically it Gzips the files that your serving and also sets the expiry date of all files types. When you check this in Page speed in Firebug you should notice a marked difference in your sites score. Try it out and increase the speed of your site

[php]
AddType x-mapp-php6 .php
AddHandler x-mapp-php6 .php


<IfModule mod_gzip.c>
mod_gzip_on       Yes
mod_gzip_dechunk  Yes
mod_gzip_item_include file      \.(html?|txt|css|js|php|pl|jpg|png|gif)$
mod_gzip_item_include handler   ^cgi-script$
mod_gzip_item_include mime      ^text/.*
mod_gzip_item_include mime      ^text/css*
mod_gzip_item_include mime      ^application/text-javascript.*
mod_gzip_item_exclude mime      ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</IfModule>


<ifModule mod_expires.c>
ExpiresActive On
ExpiresDefault "access plus 1 day"
ExpiresByType image/png "access plus 30 days"
ExpiresByType image/jpeg "access plus 4 weeks"
ExpiresByType image/gif "access plus 1 month"
ExpiresByType image/x-icon "access plus 1 year"
ExpiresByType application/javascript "modification plus 2 weeks"
ExpiresByType text/css "modification plus 14 days"
</ifModule>
[/php]
WordPress 5.4 Adderley Update

WordPress 5.4 Adderley Update

New exciting features coming in Adderley: Highlights This new update to WordPress sees more…

read more

What is Content Marketing?

What is Content Marketing?

What is Content Marketing? This is content marketing! By creating a blog and giving…

read more

Embed a Twitter feed on your website

Embed a Twitter feed on your website

A few years ago Twitter closed it's API off meaning that if you're looking…

read more

Google is now favouring SSL Certificates on all Websites

Google is now favouring SSL Certificates on all Websites

Over the last few years there has been a push to move websites from…

read more

WordPress 5.3 Kirk Update

WordPress 5.3 Kirk Update

New exciting features coming in Kirk: Highlights With this new update WordPress have refined…

read more

© 2020 Portal Creative