Enigma 78 Posted August 21, 2014 Report Share Posted August 21, 2014 Anyone knows how to run a javascript code into a script and instead of displaying the result into the ubot browser i want to #Set the result into a variable or $add it to a list. I have tried a few things, like Run Javascript, tried the $eval, tried with Define Function but it all seems not to work for me. Thanks in advance. Quote Link to post Share on other sites
UBotDev 276 Posted August 22, 2014 Report Share Posted August 22, 2014 $eval is the right one, you just need "echo" the variable value at the end of your JS script. Quote Link to post Share on other sites
Enigma 78 Posted August 22, 2014 Author Report Share Posted August 22, 2014 @ubotdev What do you mean by example for a document.write? Quote Link to post Share on other sites
UBotDev 276 Posted August 22, 2014 Report Share Posted August 22, 2014 It's all on the forum, you just need to search a bit: http://www.ubotstudio.com/forum/index.php?/topic/16080-javascript-and-ubot-variables/&do=findComment&comment=92883 However, by "echo" I mean call variable to print it's value, like "counter;" in example on page linked above. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.