Re: Has anyone tried using their own images inst of avatars?

  •  02-19-2008, 11:27 AM

    Re: Has anyone tried using their own images inst of avatars?

    Hi Jessica,
     
    You  have to rewrite the Code in the HttpHandler DrawAvatar's ProcessRequest method (/CuteSoft_Client/CuteChat/DrawAvatar.ashx). The script file /CuteSoft_Client/CuteChat/Script/ChatUI.js contains two methods for drawing avatars where parameters are passed to the handler via querystring (ChatUI_GetAvatar(user) and ChatUI_GetInstantAvatar(user)). For eymaple you could rewrite the paths in these methods as follows:

    CuteChatUrlBase+"DrawAvatar.Ashx?ID="+user.UserId
     
    the body of the handler's ProcessRequest method could then look like this:
     
    context.Response.Redirect("/ProfileImages/"+context.Request.QueryString["ID"]+".jpg");
     
    That's how we did it. We are using the user's profile images exclusively, so we disabled the avatar function in the GUI completely. However, it shouldn't be too complicated to let users choose between avatars and their profile image or imges from their albums. The only challange might be, that the user object doesn't store that data, so that you'll have to work around e.g. using a cookie.
     
    Hope that helps!
    Kind regards, Christoph
View Complete Thread