Posted (Updated ) in Javascript, PHP

Earlier tonight I wanted to remove the ancient version of JQuery automatically loaded on the WordPress front end and replace it with the much speedier latest version (currently 1.4.2). This turned out to be more difficult than planned, however after a bit of scrounging I found the solution; add the following code to your template’s functions.php file:

if( !is_admin() )
{
	wp_deregister_script('jquery');
	//Add latest JQuery back into header. Comment this line out to remove JQuery alltogether
	wp_register_script('jquery', ("http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"), false, '1.4.2');
	wp_enqueue_script('jquery');
}

Enjoy your blazingly fast JavaScript experience 🙂

Read More »

Posted (Updated ) in Database, PHP

WordPress is great on its own but if you want to do alot of database work with it you’ll quickly realize how frustratingly limited the wpdb class is. In this tutorial I’ll show how to integrate Doctrine into WordPress through the use of a plugin and make your developing life so much easier.

Read More »

Posted (Updated ) in PHP

If you’re running WordPress on multiple servers, chances are you’ve come across an issue where once you’ve copied WordPress to the new domain, none of your scripts, styles or images are loading. One of the most common occurrences of this happening is running an installation on your local machine (localhost) and allowing people from an internet or network IP to view it. If you dig a little further by viewing page source you’ll notice the issue is caused by WordPress using your old domain (or localhost) for loading – resulting in extreme load on a single server or worse; a HTTP 404 error.

Read More »

Posted (Updated ) in PHP

WordPress is great. It allows you to quickly set up a blog with minimal effort. In the case of setting up the Google Syntax Highlighter, however, it ended up being quite a hassle due to WordPress’s WYSIWYG editor. This tutorial shows how to modify the editor to make Google Syntax Highlighter work as advertised.

Update Jan 3 2011 To allow pre tag in TinyMCE, we’re now modifying functions.php instead of a wordpress admin file so changes aren’t erased when WP is updated. See here for more details.

Read More »