Skip to Main Content

Oracle Forms

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to execute function with web.javascript_eval_function

MWaseemMar 16 2021

I can execute this function in Javascript Well.
async function getIP() { try {
const res = await fetch('https://api.ipify.org?format=json');;)
const jsonObj = (res.json()).then(data => document.write(data.ip));
} catch (err) {
console.error(err);
}}

When i execute with
:function_ouput := web.javascript_eval_function('async function getIP() { try {
const res = await fetch("https://api.ipify.org?format=json");;)
const jsonObj = (res.json()).then(data => document.write(data.ip));
} catch (err) {
console.error(err);
}}
');
it did not give any result. not any response. How could i write it to run with web.javascript_eval_function

Comments
Post Details
Added on Mar 16 2021
2 comments
342 views