<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script>
var x1,x2;
var nn1,nn2;
function sample(){
$("#memo").click(function () {
alert(nn1);
});
$("#memo2").click(function () {
alert(nn2);
});
google.script.run
.withSuccessHandler(function(q) {
f(q);
})
.withFailureHandler(function(msg) {})
.step();
}
function f(q){
var name=new Array();
var pic=new Array();
number=q.length;
var str="<table>";
for(s=0;s<q.length;s++){
var x=q[s].split(",");
name[s+1]=x[0];
pic[s+1]=x[1];
}
n1=number*Math.random();
x1=Math.floor(n1)+1;
n1=number*Math.random();
x2=Math.floor(n1)+1;
nn1=name[x1];
nn2=name[x2];
p1="http://web-m.webcdn.stream.ne.jp/www09/web-m/ske48/img/profile/small/"+pic[x1];
p1="<img src=\""+p1+"\" width=100 height=100>"
p2="http://web-m.webcdn.stream.ne.jp/www09/web-m/ske48/img/profile/small/"+pic[x2];
p2="<img src=\""+p2+"\" width=100 height=100>"
$("#memo").html(p1);
$("#memo2").html(p2);
}
</script>
最終更新:2015年10月08日 02:18