Add Category ID into the body and post class in WordPress

Here’s a little snippet I regularly use to add the ID of the post/page into the body class and post class. It’s really helpful to aid targeting specific things in CSS, add functionality with javascript and to quickly pinpoint the ID of a page without checking through the back-end. Add this to your themes functions.php … Continued

Show content in specific category in Magento

Here’s a little snippet which allows you to enter specific content based on store category. This is handy if you want to show something on a page which belongs to just a specific category only. Likewise you can show either content A if on category and if not, show content on all other categories: