javascript - Web app with Google script - handling the class google.script.url -
i have developed web app on google script, parameter "mocnumber" in url, people specific link can access directly needed information. web app run "as me", , access open people within organization.
here extract of .gs file (server side), doget function:
function doget(e) { var t = htmlservice.createtemplatefromfile('index'); t.data=json.stringify(e.parameter.mocnumber) logger.log(t.data); return t.evaluate().setsandboxmode(htmlservice.sandboxmode.iframe) .settitle('my tool - beta version ii'); }
on client side (.js file), use following function put parameter variable, , use load required information.
var mocnumber="" google.script.url.getlocation(function(location) { mocnumber=location.parameter.mocnumber; });
however, when share web app link people of organization, appears script file has shared them, incoherent fact app run me.
does know if use way "google.script.url" url parameters??
thank in advance.
Comments
Post a Comment