我正在撰写Gmail上下文小工具
是否可以使用小工具xml传递域名 e.g
<Extension id="HelloWorldGadget" type="gadget">
<Name>Hello World Gmail contextual gadget</Name>
<Url>_http://example.com/gadgets/hello_world_gadget.xml?domain=${DOMAIN_NAME}</Url>
<Container name="mail"/>
</Extension>
域= $ {DOMAIN_NAME}
以其他方式使用API获取域名?
我们有多个CRM客户端,并希望根据域名连接客户端数据库。
答案 0 :(得分:0)
我目前在Module xml的内容部分中使用此域名来获取域名。不是我的代码,但我不记得我在哪里找到了这个例子。
var googledomain = gadgets.util.getUrlParameters()['parent'].match(/.+\/a\/(.+)\/html/)[1];