Location: PHPKode > scripts > WH Social > wh_social/framework/class/newest_class.php
<?php

    function newest_members() {
        $rand_sql = "SELECT id, name, avatar FROM members ORDER BY date DESC LIMIT 1";
        $rand_members = mysql_query($rand_sql) OR die(mysql_error());

        $rand_result = mysql_fetch_row($rand_members);
        $rand_avatar = $rand_result[2];
        $rand_name   = $rand_result[1];

        return '<img src="' . $rand_avatar . '" class="Avatar" border="0" vspace="5" title="' . $rand_name . '" alt="Avatar"><br><small>' . $rand_name . '</small>';
        }

?>
Return current item: WH Social