I need a chrome extension (userscript)

Status
Not open for further replies.

H41822

Newbie
Joined
Apr 25, 2014
Messages
18
Reaction score
2
I need the following Userscript converted as a google chrome userscript:
https://greasyfork.org/scripts/11672-gkplugins-helper/code/GkPlugins%20Helper.user.js

Please keep in mind, that this is not a simple userscript, it needs special rights granted.
A "advanced coder" would know what i am talking about.

I am requestion this, because i failed to do it myself.

Demo Site:
http://nou4r.net/x/play/play.php?url=https://ok.ru/video/37675534991

For the beginning, you can install the userscript via Tampermonkey or greasemonkey.
I will ofcourse you money for your work.

Code:
    var request = function(reqObj,onCom,onErr){
        var xhttp;
        if (window.XMLHttpRequest) {
            xhttp = new XMLHttpRequest()
        }else{
            xhttp = new ActiveXObject("Microsoft.XMLHTTP")
        }
        xhttp.onreadystatechange = function(){
            if(xhttp.readyState == 4) {
                if(xhttp.status == 200){
                    if(onCom){onCom(xhttp.responseText)}
                }else{
                    if(onErr){onErr(reqObj)}
                }
            }
        }
        var async = true;
        if(reqObj.async!=null){
            async = reqObj.async;
        }
        xhttp.open(reqObj.method, reqObj.url, async);
        if(reqObj.data){
            xhttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
            xhttp.send(reqObj.data);
        }else{
            xhttp.send();
        }
    }
 
Status
Not open for further replies.
This thread has been auto closed due to the forum's thread age policy. Read more.
Back
Top