Use latest jQuery from CDN in WordPress

WordPress is shipped with a current jQuery version by default. When you update your WordPress core and there’s a new version of the jQuery library that is used in the package, it will be updated, too. But you might have reasons not to update your WordPress core, want to use an outdated version of jQuery, or use the jQuery library hosted on a content distribution network (CDN). Google is hosting jQuery and other libraries publicly that you could use and include in your WordPress theme.

« Read more about: Use latest jQuery from CDN in WordPress  »

Sort Magento category by multiple values – keep newest products on top

When running a magento store, you may come up with the idea of keeping your latest product(s) in the first place(s). But you still want to have the rest of the category listing ordered by another value or attribute you specified. As of Magento 1.9.2.4, there seems to be no way achieving this except for using a plugin.

If you do not want to invest into a plugin and you are are little bit into coding,

« Read more about: Sort Magento category by multiple values – keep newest products on top  »

How To: Setup DropBox on your NAS or shared network drive

Do you have a NAS at home or in your office and would like to use it with Dropbox? Dropbox’ desktop app unfortunately doesn’t let you use it anywhere outside your local harddrive, let alone a folder on a shared network drive.

I tried to use the Dropbox App that was shipped with my WD My Cloud EX 4 (affiliate-link). But unfortunately, this app was not really working.

« Read more about: How To: Setup DropBox on your NAS or shared network drive  »

Shared functions.php across WordPress multi-sites

Ever wondered how you could use a shared functions.php in a WordPress multisite (WPMU) environment? If you are using a WordPress multisite setup you’ve probably come across using the same custom WordPress functions over and over again. As a theme developer, you might already have created a functions.php blueprint that you will use in every new theme. In this article, I will show you how to set up and implement a shared functions.php that you are be able to use across a WordPress multisite installation.

« Read more about: Shared functions.php across WordPress multi-sites  »

Make your WordPress gallery link to a custom image size

Using the WordPress gallery shortcode and linking the gallery items to its media source, WordPress will always create a link to the full size image. For a project I needed to change this behaviour since the full size images uploaded by editors will usually be too large to be dealt with the way we want to.

We will be using galleries linking to large size images and displaying them in a fancybox.

« Read more about: Make your WordPress gallery link to a custom image size  »

Magento & WordPress Multisite: a challenging marriage

For the relaunch of a project’s website, we chose to use two CMSes: Magento for managing products and being able to actually sell products online and WordPress for good old content such as news around products and company, information about the products’ designers and other similar stuff. But we were also having “satellite sites” / microsites around specific products or brands that were managed in different content management systems on different servers. This made publishing content to those different websites challenging and confusing for the editors as well as maintaining the sites for me as developer.

« Read more about: Magento & WordPress Multisite: a challenging marriage  »

Bash script to copy remote MySQL databases

I am glad that I have set up multiple environments for a current project that I’m working on. The live site, a testing site, and two developing sites – all with their unique databases just in case something’s going very Murphy – are a fair deal to develop and test new features and bugfixes on any web project. But there’s one major drawback: Keeping data “in sync”. Version control like git or SVN do a great job with all that PHPs,

« Read more about: Bash script to copy remote MySQL databases  »

Enable PHP error-logging on an A2 Hosting shared web hosting account

I tried to re-install my favourite running tracking application and failed, I just wouldn’t stop getting Internal Server Error 500. I quickly figured that I would have to look into the error logs to actually see what is going wrong. But that’s not activated by default, so I had to enable PHP error-logging manually.

Of course, I thought that the Internal Server Error 500 might be caused by some errerous entry in the .htaccess-files. 

« Read more about: Enable PHP error-logging on an A2 Hosting shared web hosting account  »

Magento development environments with different database connections

After explaining, how to use Different database connections in WordPress development environments, I’m going to show, how to set up Magento development environments with different database connections. Magento works a little different here, since it has its database connection in an XML file rather than a configuration .php-file.

« Read more about: Magento development environments with different database connections  »

Content snippet in blog posts with a shortcode

You’re having the same content snippet on multiple WordPress blog posts and are fed up with making changes to that small piece on each single post? I’m showing you how to create a custom WordPress shortcode that pulls the content from a single post and injects it right into your blog posts.

The situation

I used an ad managing plugin for displaying the same content in multiple articles. Basically, those are a series of blog posts that had a table of contents.

« Read more about: Content snippet in blog posts with a shortcode  »