I want to control the popup location

Last post 11-04-2004, 10:36 AM by cutechat. 1 replies.
Sort Posts: Previous Next
  •  11-03-2004, 4:22 PM 2304

    I want to control the popup location

    I want to use CuteChat as part of my application and don’t want to have multiple popup windows opening. For That I like to control the location of in what frame to open. Instead of “_blank” I want to give it my own location.
    I’m an advanced ASP classic programmer, but know (yet) a little about the .net environment. Expect the default.aspx, I don’t find the place where the other pages be opened.
    Can anyone tell me how to control the popup and where to find the code.
    Mike
  •  11-04-2004, 10:36 AM 2309 in reply to 2304

    Re: I want to control the popup location

    Mike:

     
        Currently the CuteChat send the script 'window.open...' to the client and execute .
        You could catch it by this way:
     
    var _myoldopen=window.open;
    window.open=myopen;
    function myopen(a,b,c)
    {
        if(a.toLowerCase().indexOf('chatptop.aspx')!=-1)
        {
                return window.open(a,'myframename');
        }
        return window.open(a,b,c);
    }
     
     
    Hope this helps.
     
    Regards,Terry .
View as RSS news feed in XML