Icy Phoenix

     
 


Post new topic  Reply to topic 
Page 1 of 1
 
 
Reply with quote Download Post 
Post 027-0020 Default Avatar In Profile_view_user.php 
 
I have found this bug after an user told me that when she watch the list of users who viewed her profile there appeared an user without name and just the "member" avatar. It was a guest, of course, but IP was displaying the wrong default avatar. This is because the user_id used to retrieve the default avatar is the current user id instead the viewer user id. Here is how to fix it:

Code: [Download] [Hide]
  1. #    
  2. #-----[ OPEN ]------------------------------------------    
  3. #  
  4.  
  5. profile_view_users.php  
  6.  
  7. #    
  8. #-----[ FIND ]------------------------------------------    
  9. #  
  10.  
  11.     $viewer_avatar = user_get_avatar($row['user_id'], $row['user_avatar'], $row['user_avatar_type'], $row['user_allowavatar']);  
  12.  
  13. #    
  14. #-----[ REPLACE WITH ]------------------------------------------    
  15. #  
  16.  
  17.     $viewer_avatar = user_get_avatar($row['viewer_id'], $row['user_avatar'], $row['user_avatar_type'], $row['user_allowavatar']);  
  18.  

 



 
hal9000Send private message  
Back to topPage bottom
Icy Phoenix is an open source project, you can show your appreciation and support future development by donating to the project.

Support us
 
Reply with quote Download Post 
Post Re: BUG: Default Avatar In Profile_view_user.php (FIXED) 
 
Thanks I have fixed it.
 




____________
Luca
SEARCH is the quickest way to get support.
Icy Phoenix ColorizeIt - CustomIcy - HON
 
Mighty GorgonSend private messageSend e-mail to userVisit poster's website  
Back to topPage bottom
Post new topic  Reply to topic  Page 1 of 1
 


Display posts from previous:    

HideWas this topic useful?

Link this topic
URL
BBCode
HTML




 
Permissions List
You cannot post new topics
You cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events


  

 

  cron