Thelastkiss Posted November 8, 2017 Share Posted November 8, 2017 Hello Me call Html : menu = mp.browsers.new('package://realliferpg/index.html'); I want to chang text in html Element By Client side script Can it be done? Do not you have another way? Thank you Sory My Bad Eng Link to comment Share on other sites More sharing options...
kostya_nad Posted November 9, 2017 Share Posted November 9, 2017 Yes. HTML page: <!DOCTYPE html> <html> <head> <meta name="Content-Type" content="text/html; charset=utf-8" /> </head> <body> <div id="editdiv">Some word & example</div> </body> </html> JS: let menu = mp.browsers.new('package://realliferpg/index.html'); // start of CEF (HTML) menu.execute(`document.getElementById('editdiv').innerHTML="Hello!"`); After this executing this script with this HTML in block with id="editdiv" text will be this: Hello! menu.execute is executing methods in CEF 2 Link to comment Share on other sites More sharing options...
Thelastkiss Posted November 10, 2017 Author Share Posted November 10, 2017 Thank you Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now