Aug 15

Lolz text effect using GIMP !

Scribbled on Friday, August 15th, 2008

This time its about some fancy text. “Lolz text effect” - as I call it. Here is the sample and outcome.

Sample Text

Final Text

Now it time for tutorial ! So read on…

Read on…

Aug 14

Gimping Kate Becky :p

Scribbled on Thursday, August 14th, 2008

Lolz…tis is pure ecstacy. I wish I had a digital pen etc to do things more fine

Anyway here is some mediocre editing by me.

Sample Greyscale Image

In-transition

Final Image

Inspired from: http://purplink.deviantart.com/art/Colorization-Kate-Beckinsale-33822062

Aug 12

Display 5 random posts in Wordpress

Scribbled on Tuesday, August 12th, 2008

Using plugins for every litte thing in Wordpress is a really bad idea. At least I like to have my own solution before anyone else’s. So I read wordpress function reference and database schema. At first it seemed so easy that I thought why would anyone make a plugin for this. Here is the first code that is itself given in Wordpress site to display random posts.

Solution 1 (Failed for me):

[sourcecode language='php']
$rand_posts = get_posts('numberposts=5&orderby=rand');
foreach( $rand_posts as $post ) :
?>

  • Failed too):

    [sourcecode language='css']
    have_posts()) : $recent->the_post(); ?>

  • Yay It worked !!!):

    [sourcecode language='css']

    $querystr = "SELECT * FROM (SELECT wposts.* FROM $wpdb->posts wposts WHERE wposts.post_status = ‘publish’ ORDER BY rand()) as y limit 5 “;

    $pageposts = $wpdb->get_results($querystr, OBJECT);

    ?>


  • posts wposts WHERE wposts.post_status = ‘publish’ ORDER BY rand()) as y limit 5 [/sourcecode]

    is a nested subquery where the query inside the brackets retrieves the posts that are published (it includes published pages too) and then order it by random. This randomly ordered list is then used to retrieve 5 first posts.

    See the result at the bottom of this website ;p

    Though I haven’t tested the performance but it works fine here.

  • Aug 11

    BnW to Color

    by T on Monday
    Aug 10

    FFmpeg - Convert any audio/video format in Linux

    by T on Sunday
    Aug 09

    UniSmilies 2.08.08 for Firefox 3 released !!!

    by T on Saturday
    Aug 08

    Main Jahaan Rahoon

    by T on Friday
    Aug 07

    Tagged by Smallstar !

    by T on Thursday
    Aug 05

    Extract an object from a pic using GIMP !

    by T on Tuesday
    Aug 04

    How sinful are YOU ?

    by T on Monday


    March 2010
    M T W T F S S
    « May    
    1234567
    891011121314
    15161718192021
    22232425262728
    293031