Press "Enter" to skip to content

Posts published in May 2011

Replace all spaces in HTML with   except in HTML tags using PHP

If you would like to replace all the spaces in an HTML string with   so that you can render it out to the browser but you also want to retain current spaces in HTML tags you can use the below method: [code lang=”php”] $inputString = ‘1 2 3′; $outputString…

Using PHP to validate an IP address

You can use the PHP code below to check if an IP address is valid or not. [code lang=”php”] $ip = “”; //enter a valid or invalid ip address here if(filter_var($ip, FILTER_VALIDATE_IP)) { // The IP Address is valid } else { // The IP Address is not valid }…

General Site Update

We are a Management Consultancy company and are split into IT and HR. Up until a short while ago our website had be quite general in it’s views to show the services of both divisions but we have decided to let our IT division take it’s own path so the…

What is the difference between is_home() and is_front_page()

Call me ignorant, or call me an ignorant geek, but I used to think is_home() and is_front_page() was the same thing, until I experimented with them the other day and noticed they did quite different things. Let me break them down: is_home() This actually is the page where all your…

What is 1e100.net?

So you are probably reading this because you are not sure what 1e100.net is or why you are being redirected via it when performing Google searches or using products such as youtube etc. Perform a SiteWhois lookup 1e100.net is owned by Google and has been in use since October 2009,…