Browser::call

From RAGE Multiplayer Wiki

Client-Side
Function

 JavaScript



JavaScript Syntax


Calls a registered browser `mp.events.add`

Syntax

browser.call(eventName, ...args);

Example

CEF (html)

<script>
    mp.events.add('cefishere', (print) => {
        print ? console.log("im here") : console.log("not here");
    });
</script>


Client Side

const browser = mp.browsers.new("http://package/page/index.html");
browser.call("cefishere", false);


See also