ScrnshotsRSS plugin 2.0 update

— I have released an updated version of the ScrnshotsRSS plugin with widget system support to easily display the screenshots in your sidebar without editing your themes files.

Also the plugin features some minor text corrections and a little fix in the image cache system. Grab the plugin here or upgrade it directly from your admin plugins page.

Tags: , , ,

Monday, November 10th, 2008 WordPress 2 Comments

Ternary Conditionals in PHP

— Ternary Conditionals are one of those things in php that can save some time when writing code and possibly make your code easier to read. I think many people don’t use them because they look a little strange ( at least thats what happened to me ).

if ($iExample == 1)
{
    $bVariable = true;
}
else
{
    $bVariable = false;
}

In the example above, if the statement is true then, it will set $bVariable to true or else it will set it to false. This is a regular conditional statement where if a condition is true something happens or else (if the condition is false) other thing happen. Conditional statements like that could be easily handled with a ternary conditional:

$bVariable = ($iExample == 1) ? true : false;

As you can see the syntax of the Ternary Conditional is pretty simple and looks good as its fits all in one line.

Variable = (condition) ?  its true : its false;

I hope you find this post useful, Cheers!

Tags:

Saturday, October 25th, 2008 Web Design & Development 5 Comments

Taking Advantage of Functions.php in WordPress Themes

— WordPress themes can optionally use a file where theme developers can add their own functions. This file acts like a plugin and gets automatically loaded during WordPress initialization, to get it working it just has to be named functions.php and reside in the theme folder.

Although not many themes seem to use it, it’s very powerful, you can use the functions inside for anything you choose. For me it helps me to define a library I can reuse to fasten up my work while keeping code clean and easy to manage. For example I have functions to list recent posts, easily display a copyright footer, highlight author comment, shorten text etc.

I have uploaded some of these functions I use as an example for you to download and try. To use them drop functions.php file in your theme folder.

→ Download the functions here

› Continue reading

Tags: , , ,

Thursday, October 23rd, 2008 WordPress 45 Comments
« Previous Entries Next Entries »

About Me

Matt Varone - Matias Varone - sksmatt
HI there,

I'm a freelance creative web developer, UI designer and hobbyist musician.

Twitter Status

Flickr Gallery

    Blue WallClutter drawerCS4 Replacement iconsCS4 Replacement icons