Skip to content

Instantly share code, notes, and snippets.

@gyosit
Created May 18, 2018 13:04
Show Gist options
  • Save gyosit/78f9ef2356aeb3ecfd68bd8d3e793a04 to your computer and use it in GitHub Desktop.
Save gyosit/78f9ef2356aeb3ecfd68bd8d3e793a04 to your computer and use it in GitHub Desktop.
function doGet(req) {
var output;
if(req.parameters.cmd == "res"){ https://~?cmd=res
output = HtmlService.createTemplateFromFile("result");
output.name = req.parameters.name; // https://~?cmd=res&name=XXX
}else{
output = HtmlService.createTemplateFromFile("index");
}
return output.evaluate();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment