Hi soyemil,
Please tyr this way
1. Open file “DesktopModules\CuteSoft_Client\CuteChat\Script\ChatUI.js”
2. Find section below
function ChatUI_GetInstantAvatar(user)
{
var atype="Messenger";
var avatar=user.PublicProperties.InstantAvatar||"";z
return CuteChatUrlBase+"DrawAvatar.Ashx?Avatar="+escape(avatar)+"&AvatarType="+atype;
}
3. Change it to
function ChatUI_GetInstantAvatar(user)
{
var atype="Messenger";
var avatar=user.PublicProperties.InstantAvatar||"";
return CuteChatUrlBase+"DrawAvatar.Ashx?Avatar="+user.UserId+"&AvatarType="+atype;
}
4. Open file “\DesktopModules\CuteSoft_Client\CuteChat\DrawAvatar.Ashx” and delete all code in this page
5. Add the code below into the page above “DrawAvatar.Ashx”
- <%@ WebHandler Language="C#" Class="DrawAvatar" %>
-
- using System;
- using System.Web;
- using System.Web.UI;
-
- public class DrawAvatar : IHttpHandler
-
- {
-
- public void ProcessRequest(HttpContext context)
-
- {
-
- string avatar = context.Request.QueryString["Avatar"];
-
- string type = context.Request.QueryString["AvatarType"];
-
- DotNetNuke.Entities.Portals.PortalSettings ps = DotNetNuke.Entities.Portals.PortalController.GetCurrentPortalSettings();
-
- DotNetNuke.Entities.Users.UserInfo user = DotNetNuke.Entities.Users.UserController.GetUserByName(ps.PortalId, avatar.Substring(5));
-
- if (user.Profile.Photo != null)
-
- {
-
- avatar = "~/LinkClick.aspx?fileticket=" + user.Profile.Photo;
-
- }
-
- else
-
- {
-
- avatar = "~/DesktopModules/CuteSoft_Client/CuteChat/Avatars/Messenger/default.png";
-
- }
-
- context.Response.Redirect(avatar);
-
- }
-
- public bool IsReusable
-
- {
-
- get
-
- {
-
- return false;
-
- }
-
- }
-
- }
6. Ope file “DesktopModules\CuteSoft_Client\CuteChat\NewMessengerMain.htm”
7. Find section below
<img id="ccm_MyAvatar" src="#__cc_urlbase#Images/1x1.gif" class="MessengerAvatar" title="[[UI_ChangePicture]]" onclick="CuteChatMessenger.BubbleCommand('ShowMyInfo',this,event)" />
8. Change it to(just hide the change avatar function)
<img id="ccm_MyAvatar" src="#__cc_urlbase#Images/1x1.gif" class="MessengerAvatar" title="[[UI_ChangePicture]]" />
Regards,
Ken