Setting a Channel / List Channels

Last post 09-24-2007, 12:44 PM by clarkjason. 2 replies.
Sort Posts: Previous Next
  •  09-22-2007, 5:09 AM 33743

    Setting a Channel / List Channels

    Hi,
     
    I'm sure this been covered before, but I cannot find an answer.
     
    I'm running Cute Chat in Embed mode in DotNetNuke.
     
    I have followed a snippet of code from the forums which enables the channel list on the control.
     However the code breaks out of the current embed mode to full screen mode
     i.e. it takes me to:
     
    DesktopModules/CuteSoft_Client/CuteChat/CH_MainForm.aspx?Location=Lobby&LocationId=1
     
    I kinda need the dropdown to keep me in embed mode with the channel changed.
     
    I assume I need to add somthing in the following method ( but what? )
     
     
    <Method Modifiers="protected" Name="OnSelectChange">
        <![CDATA[
        var element=this.GetElement();
        var select=Html_FindChildById(element,"select_lobbylist");
        var option=select.options[select.selectedIndex];
        if(option)
        {
         var val=option.value;
         if( parseInt(val) && parseInt(val)!=GetChannel().LocationId)
         {
          location.href=CuteChatUrlBase+"CH_MainForm.aspx?Location=Lobby&LocationId="+val;
         }
        }
        ]]>
       </Method>
     
    look forward to your repy. Bottom line is I ant to change channels in Embed mode ( without breaking out of embed mode )
     
    cheers,
     
    jason.
  •  09-23-2007, 11:58 PM 33775 in reply to 33743

    Re: Setting a Channel / List Channels

    Jason,
     
    Yes. This feature is disabled in the embed mode. Please follow the steps below to enable it:
     
    Open CuteSoft_Client\CuteChat\ChatUI.xml
     
    and find the following code:
     

        <![CDATA[
        if(typeof(IsEmbed)!="undefined"&&IsEmbed)
        {
         this.SetVisible(false);
         
        }
        else
        {
         AttachChatEvent("CHANNEL",this.OnChatEvent);
         AttachChatEvent("LOBBYLISTRETURN",this.OnListReturn);
        }
        ]]>
     
     
    And change it to:
     

        <![CDATA[     
          AttachChatEvent("CHANNEL",this.OnChatEvent);
          AttachChatEvent("LOBBYLISTRETURN",this.OnListReturn);
        ]]>
     
    This should resolve the problem.

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  09-24-2007, 12:44 PM 33787 in reply to 33775

    Re: Setting a Channel / List Channels

    Hi,
     
    Thats about as far as I got, you see the code you supplied shows the dropdown, but when in Embed mode you change the dropdown it opens the main chat windows and doesnt stay in Embedded mode.
     
    cheers,
    jason
     
View as RSS news feed in XML