[英]Is there a way to extract JavaScript variables from a page in Google Docs/with Google Apps Script?
I'm very new to JavaScript, and much more of an analyst than a programmer. 我对JavaScript非常陌生,比起程序员,他更是一名分析师。
You know how you can open up Chrome's Console and type in a JavaScript variable, and the value of that variable will be returned? 您知道如何打开Chrome的控制台并键入JavaScript变量,然后将返回该变量的值吗? I want to know if it's possible to grab those variables from within Google Drive/Docs or Google Apps Script. 我想知道是否有可能从Google云端硬盘/文档或Google Apps脚本中获取这些变量。
I've seen a few examples on StackOverflow of getting the values of certain XML elements (say, the text within a title tag), but I don't want to grab the entire contents of the script that contains these variables (as would be returned with an XPath query), just the variables themselves. 我已经在StackOverflow上看到了一些示例,这些示例获取某些XML元素的值(例如,标题标签中的文本),但是我不想获取包含这些变量的脚本的全部内容(因为XPath查询返回),只是变量本身。
Is this possible? 这可能吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.