Skip to content

Instantly share code, notes, and snippets.

@prog-mitsu
Last active December 6, 2017 19:30
Show Gist options
  • Select an option

  • Save prog-mitsu/5954202 to your computer and use it in GitHub Desktop.

Select an option

Save prog-mitsu/5954202 to your computer and use it in GitHub Desktop.
googleサイト上で好き勝手にjavascriptを動かす方法 ref: https://qiita.com/ms32/items/8cd40ebc8c4fecc60df4
<?xml version="1.0" encoding="UTF-8" ?>
<Module>
<!-- ガジェット名 -->
<ModulePrefs title="myapp" />
<!-- ガジェットから渡すユーザーパラメータの定義 -->
<UserPref name="param00" datatype="string" default="9999" />
<UserPref name="param01" datatype="string" default="hoge" />
<Content type="html">
<![CDATA[
<!-- CDNから読み込み(http, https省いています) -->
<script type="text/javascript" src='//ajax.googleapis.com/ajax/libs/jquery/1.8/jquery.min.js '></script>
<script type="text/javascript" src='//ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js'></script>
<link rel="stylesheet" type="text/css" href="//ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/redmond/jquery-ui.css">
<!-- google site添付から読み込み(https省いています) -->
<!-- ライブラリ -->
<script type="text/javascript" src='//sites.google.com/site/qiitatestpublic/jquery.jqGrid.src.js'></script>
<script type="text/javascript" src='//sites.google.com/site/qiitatestpublic/grid.locale-ja.js'></script>
<script type="text/javascript" src='//sites.google.com/site/qiitatestpublic/apprise-1.5.full.js'></script>
<link rel="stylesheet" type="text/css" href="//sites.google.com/site/qiitatestpublic/apprise.css">
<!-- 自前コード -->
<script type="text/javascript" src='//sites.google.com/site/qiitatestpublic/myapp.js'></script>
<!-- 実行 -->
<script type="text/javascript">
$(document).ready(function(){
MYAPP.setJqGrid("#jqGridList");
apprise('TEST', {'animate':true});
});
</script>
<h2 class="ui-widget-header ui-corner-all">テスト</h2>
<br>
<table id="jqGridList"> </table>
]]>
</Content>
</Module>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment