Problem with chatbox auto-login javascript
2 posters
Page 1 of 1
Problem with chatbox auto-login javascript
Hello,
I am using the following javascript for chatbox members auto-login but it conflicts other javascripts is there a way to fix it?
I am using the following javascript for chatbox members auto-login but it conflicts other javascripts is there a way to fix it?
- Code:
$(function() {
var chatbox_window = document.getElementById('frame_chatbox');
var iframewindow = chatbox_window.contentWindow ? chatbox_window.contentWindow : chatbox_window.contentDocument.defaultView;
var chat = iframewindow.chatbox;
function check_logged()
{
if( !chat.connected ) {
chat.connect();
}
}
check_logged();
setInterval(function() {
check_logged();
}, 3000);
});
Last edited by Black-Shadow on February 24th 2015, 2:39 pm; edited 1 time in total
Re: Problem with chatbox auto-login javascript
Hi @Black-shadow,
Try this instead :
Try this instead :
- Code:
$(window).load(function() {
var chatbox_script = function() {
setTimeout(function(){ $('#chatbox_option_co:visible').click() }, 1000);
};
var s=document.createElement('script');s.text="("+chatbox_script.toString()+")();";$('object[data^="/chatbox/index.forum"],iframe[src^="/chatbox/index.forum"]').each(function(){try{$(this.contentDocument||this.contentWindow.document).find("#chatbox").closest("html").find("head").first().each(function(){this.appendChild(s.cloneNode(true))})}catch(a){}})
});
Re: Problem with chatbox auto-login javascript
Hi Ange Tuteur,
It seems working is there a way to hide the options archive/login/logout due the members are always connect in chatbox?
It seems working is there a way to hide the options archive/login/logout due the members are always connect in chatbox?
Re: Problem with chatbox auto-login javascript
Add the following code to your stylesheet.
Administration Panel > Display > Colors > CSS stylesheet
Administration Panel > Display > Colors > CSS stylesheet
- Code:
a[href="/chatbox/index.forum?archives=1"], #chatbox_option_disco { display:none }
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum