View Single Post
  #1  
Old 23rd March 2010, 20:09
helvijs13 helvijs13 is offline
Senior Member
 
Join Date: Sep 2008
Posts: 23
Angry Avatar resizer! [YSE pre6]
Hello! So i have small problem ! I can't found script what resize avatars. So i have seen in one tracker you can add add picture how big you want ,but in userdetails its shows in orginal size but in details its shows 100x100 px. So mybe some one have this script i realy need it this.

Or if you have seen this topic somewhere before write the adress!

Tnx before!:bubble:

Bump: Hy again ! i found how to fix that !


go in include/functions.php

and search line Function Commenttable

and all function replece with this code :

PHP Code:
function commenttable($rows)
{
        global 
$CURUSER;
        
begin_main_frame();
        
begin_frame();
        
$count 0;
        foreach (
$rows as $row)
        {
                print(
"<p class=sub>#" $row["id"] . " by ");
    if (isset(
$row["username"]))
                {
                        
$title $row["title"];
                        if (
$title == "")
                                
$title get_user_class_name($row["class"]);
                        else
                                
$title htmlspecialchars($title);
        print(
"<a name=comm"$row["id"] .
                
" href=userdetails.php?id=" $row["user"] . "><b>" .
                
htmlspecialchars($row["username"]) . "</b></a>" . ($row["donor"] == "yes" "<img src=pic/star.gif alt='Donor'>" "") . ($row["warned"] == "yes" "<img src=".
                            
"/pic/warned.gif alt=\"Warned\">" "") . " ($title)\n");
                }
                else
                   print(
"<a name=\"comm" $row["id"] . "\"><i>(orphaned)</i></a>\n");

                print(
" at " $row["added"] . " GMT" .
                        (
$row["user"] == $CURUSER["id"] || get_user_class() >= UC_MODERATOR "- [<a href=comment.php?action=edit&amp;cid=$row[id]>Edit</a>]" "") .
                        (
get_user_class() >= UC_MODERATOR "- [<a href=comment.php?action=delete&amp;cid=$row[id]>Delete</a>]" "") .
                        (
$row["editedby"] && get_user_class() >= UC_MODERATOR "- [<a href=comment.php?action=vieworiginal&amp;cid=$row[id]>View original</a>]" "") . "</p>\n");
                
$avatar = ($CURUSER["avatars"] == "yes" htmlspecialchars($row["avatar"]) : "");
                if (!
$avatar)
                        
$avatar "/pic/default_avatar.gif";
                
$text format_comment($row["text"]);
    if (
$row["editedby"])
            
$text .= "<p><font size=1 class=small>Last edited by <a href=userdetails.php?id=$row[editedby]><b>$row[username]</b></a> at $row[editedat] GMT</font></p>\n";
                
begin_table(true);
                print(
"<tr valign=top>\n");
                print(
"<td align=center width=150 style='padding: 0px'><img width=150 src=$avatar></td>\n");
                print(
"<td class=text>$text</td>\n");
                print(
"</tr>\n");
     
end_table();
  }
        
end_frame();
        
end_main_frame();

Reply With Quote