The forum of the forums

Would you like to react to this message? Create an account in a few clicks or log in to continue.
The forum of the forums
4 posters

    chatbox java doesnt work

    h4d3z
    h4d3z
    New Member


    Posts : 10
    Reputation : 1
    Language : Dutch

    Solved chatbox java doesnt work

    Post by h4d3z Sat 2 Jul 2016 - 0:31

    So i tried adding some java code i found here but it doenst do anything.
    Im a doing something wrong ?
    there are 2 codes :

    $(window).load(function() {
    var chatbox_script = function() {
    var overrided = Chatbox.prototype.refresh;
    Chatbox.prototype.refresh = function(data) {
    overrided.call(this, data);
    $('.chatbox-username').each(function(){
    this.previousSibling&&$.trim(this.previousSibling.nodeValue)=="@"&&$(this.previousSibling).replaceWith('<img src="https://i.imgur.com/zICIAne.png" /> ')
    })
    };
    };
    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){}})
    });




    And :

    $(window).load(function() {
    var chatbox_script = function() {
    $('#chatbox > p > .msg > span').filter('[style="color"],[style="color"]').closest('p').remove();
    var overrided = Chatbox.prototype.refresh;
    Chatbox.prototype.refresh = function(data) {
    if (data.messages && data.messages.length) {
    data.messages = $.grep(data.messages, function(v) {
    return v.userId != -10 || $.inArray(v.msgColor, ["red", "green"]) == -1;
    });
    }
    overrided.call(this, data);
    };
    };

    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){}})
    });


    They are the crown replace for @
    and the login / logout removal


    Last edited by h4d3z on Sat 2 Jul 2016 - 1:03; edited 1 time in total
    Nemo
    Nemo
    Active Poster


    Male Posts : 1203
    Reputation : 119
    Language : Greek, English, French

    Solved Re: chatbox java doesnt work

    Post by Nemo Sat 2 Jul 2016 - 0:37

    Hey,

    What's your forum's URL?

    Hello
    h4d3z
    h4d3z
    New Member


    Posts : 10
    Reputation : 1
    Language : Dutch

    Solved Re: chatbox java doesnt work

    Post by h4d3z Sat 2 Jul 2016 - 0:38

    SLGray
    SLGray
    Administrator
    Administrator


    Male Posts : 51498
    Reputation : 3523
    Language : English
    Location : United States

    Solved Re: chatbox java doesnt work

    Post by SLGray Sat 2 Jul 2016 - 0:41

    Please use the BBCode code tags when you post coding.
    Code:
    [code][/code]



    chatbox java doesnt work Slgray10

    When your topic has been solved, ensure you mark the topic solved.
    Never post your email in public.
    Nemo
    Nemo
    Active Poster


    Male Posts : 1203
    Reputation : 119
    Language : Greek, English, French

    Solved Re: chatbox java doesnt work

    Post by Nemo Sat 2 Jul 2016 - 0:43

    Hey,

    Have you enabled the JavaScript management via your ACP?

    Hello
    h4d3z
    h4d3z
    New Member


    Posts : 10
    Reputation : 1
    Language : Dutch

    Solved Re: chatbox java doesnt work

    Post by h4d3z Sat 2 Jul 2016 - 0:44

    sry, il will use code and /code

    i did enable the java script
    h4d3z
    h4d3z
    New Member


    Posts : 10
    Reputation : 1
    Language : Dutch

    Solved Re: chatbox java doesnt work

    Post by h4d3z Sat 2 Jul 2016 - 0:47

    omg it worked now lol,
    dont now why
    Ape
    Ape
    Administrator
    Administrator


    Male Posts : 19324
    Reputation : 2005
    Language : fluent in dork / mumbojumbo & English haha

    Solved Re: chatbox java doesnt work

    Post by Ape Sat 2 Jul 2016 - 1:03

    is this now solved
    If yes please hit the big green solved button on the top of your first post

    thank you.



    chatbox java doesnt work Left1212chatbox java doesnt work Center11chatbox java doesnt work Right112
    chatbox java doesnt work Ape_b110
    chatbox java doesnt work Ape1010
    Nemo
    Nemo
    Active Poster


    Male Posts : 1203
    Reputation : 119
    Language : Greek, English, French

    Solved Re: chatbox java doesnt work

    Post by Nemo Sat 2 Jul 2016 - 9:53

    Problem solved & topic archived.
    Please read our forum rules: ESF General Rules

      Current date/time is Sun 22 Sep 2024 - 12:16