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 recent posts are shown. Which means if your “home” page is set to “static” then it will be false, otherwise it will be true.

..near 'option o ON (po.option_id = o.option_id) LEFT JOIN option_description od ON (o.o' at line 1

So you’ve just installed Opencart 1.5.0 and when attempting to edit a product or category or etc you get the following error: Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘option o ON (po.option_id = o.option_id) LEFT JOIN option_description od ON (o.o’ at line 1 Error No: 1064 SELECT * FROM product_option po LEFT JOIN option o ON (po.

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, if you perform a whois on the domain you can see it’s registration details linked back to Google. Perform an SiteInfo lookup

Hide all error messages PHP

PHP Error messages showing up in your web applications are a dangerous thing. Not only does it look unprofessional, but it is also a serious security concern! Once you have completed debugging your website or web application you can place the following one liner at the beginning of your code, this will turn off error reporting and therefore make sure that no application details are spilled to your users. 1 error_reporting(0); If a single line of code is causing the problems it is safer to use the at symbol (@) to suppress any errors it may cause.

What is xmlrpc.php?

It is a script which allows clients to make procedural calls over the net. As it says in the name, the encoding is XML and because it is used on websites we can make the fair assessment that it uses the HTTP protocol. If we break the name down we get: XML transmition via Remote Procedure Calls. So you are still not sure what this is all about? Read on..

Windows Genuine Advantage Notifications in a VM

Windows Genuine Advantage Notifications I am running a Windows XP SP3 VM used for testing multiple versions of InternetExplorer through Virtualbox. Running this wizard should be avoided if Windows is in a VirtualMachine.

Force HTTP using htaccess

1 2 3 RewriteEngine On RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://www.example.com/$1 [R,L]

Stop That Referrer in PHP!

Today I will show you a method to stop the traffic that a referrer site is sending your way, you may wonder why you would want to ignore traffic, after all, isn’t inbound traffic to your site fantastic no matter what? The simple answer is “NO!” Let me explain it in a real life situation so that you can better understand where to use this. Understanding where to use it

Viva la 09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0!

You may see this around and not have a clue what the heck it is, weirdly enough, I did.. Why “weirdly” you ask, well, because, who would be looking for something like “09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0”. Let me elaborate.. The Urban Dictionary says it like this: “An alphanumeric string denoting a hack and insecurites in the HD-DVD coding.”

Ternary Operation

If you do not know what the Ternary operator is, or do not use it while you are coding, let me be the first to tell you how much you are missing out! The Ternary operator looks like this: “?“, that’s right, it’s a question mark! My favourite way of using it is to shorten Conditional If Statements, so let me show you what I’m on about. The long way:

Oops the system encountered a problem (#104)

If you get the following error while using Google’s Gmail Service (gmail.com): Oops? the system encountered a problem (#104) ..then you should try deleting your browser’s cache and everything will be resolved. This appears to be a local problem and not on the Google servers as data is pushed via cookies to the local machine using the web service. In order to delete your browser’s cache in Firefox click Tools->Clear Recent History then select “Everything” in the dropdown menu and then deselect everything except for “Cache” in the below list box.

How to Write Unmaintainable Code

I have come across the following article before and again came across it today, after a revised browse through, I thought I may as well add another link to it on the web for whoever ends up clicking on it! It really is a worthwhile (in a humor sort of way) read: http://www.freevbcode.com/ShowCode.Asp?ID=2547

Captcha Fail!

Hey, thought I’d just post this one incase anybody else sees it and thinks it’s funny. This is not really a very helpful post like most of the others on this site, but HEY! TOUGH! So feel free to smile if you like.. What do you know, a snippet of helpful-ness is about to appear-> This issue is usually caused by an invalid referrer! HA!

Test IE versions on any machine!

Do you do web development and are unable to test your software in old shitty versions of Internet Explorer? If so then you may want to read on a little bit. Microsoft has got a whole bunch of virtual images you can download for FREE(not a usual Microsoft word) over here: http://www.microsoft.com/downloads/en/details.aspx?FamilyId=21EABB90-958F-4B64-B5F1-73D0A413C8EF&displaylang=en They contain an operating system and an install of your favourite IE version! Hooray! They have IE6 on XP SP3, IE7 on Vista, IE8 on XP and Vista.

Error 500 php_value .htaccess

I noticed on some server setups I could not do the following inside a .htacess file: <br> php_value upload_max_filesize 250M<br> php_value post_max_size 250M<br> I was getting an error 500 Internal Server Error with the above code in the .htaccess file. What to do to correct this is create a file called php.ini and save it in the same location as your .htaccess file and enter the following code instead: <br> upload_max_filesize = "250M"<br> post_max_size = "250M"<br>

Windows Directory Tree Never Finishes Loading?

I am running Windows 7 64-bit and since yesterday whenever I open “My Computer”/”Windows Explorer” (-Windows+E) the initial “showing drives” screen is frozen, so I have to use the address bar to navigate to the path I need to go. As you can see in the picture to the left even after you have gotten to and are viewing the folder you want, the directory tree in the sidebar continues to “check” for “who knows what”!

CSS background image data: base64?

What the heck is all that Gobbledygook in the CSS? So you have noticed that bit of css that says something like this in the CSS source-code and you have no idea what it could be? url(“data:image/gif;base64,R0lGODlfMAMEAIABAKysrObm5iH5BAEAAAEALAAAAAAwAwQAAAJOhI+py30Bo5y02ouz3rz7D4biSJbmiabqyrbuC8fyTKPOjedHzff+DwwKh8Si8YhMKku6pvOxjEqn1Kr1is1qt7ynV8cNi8fksvmMTiMLAD4=”) no-repeat scroll 50% 0 transparent It is a technique called Data URLs and using PHP – or your favourite server-side script – you can generate these nifty little things. An example of how to generate it in PHP:

WordPress remove Subscribe to my RSS feed after posts

If you are running WordPress and have noticed a line under all your posts that says: If you enjoyed this post, make sure you subscribe to my RSS feed! ..and if this irritates you as much as it did me, you can remove it by deactivating a plugin called Subscribe Remind. Done! P.S. Sorry Trevor, not trying to piss you off 😛

And then there was Google Instant!

If you have visited the Google.co.uk homepage (Yes, that’s Google UK) recently – since about the 8th of September 2010 then you would have noticed a new search feature Google is pushing called Google Instant. Now what is so nice about Google Instant? It is an ajax type search application that now searches using keyword ghosting and searches and returns results as you type to populate the normal search results page that has been used up until now.

[Solved] PHP’s typeof – gettype()

Quite often you may need the ability to check what type of data type a variable is. In most programming languages this is possible to do and is usually called something like typeof(). So what is typeof in php, or typeof php you ask? In PHP there is a simple function called gettype() and it’s so easy to use. All you have to do is pass the variable in question to gettype() as the first argument and the type will be returned.