This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var second=0;var customerCount=(Math.random()*50);customerCount=Math.floor(customerCount);var productCount=4;var productCount2=6;$(document).ready(function(){$('#footer-slider').fadeIn();second=getCookie();console.log(document.cookie);if(isNaN(second)){second=7200;};CustomerIncrement();ProductDecrement();CountDown();setInterval("CustomerIncrement()",3000);setInterval("CountDown()",1000);});function Rand_View_Num(){randNum=(Math.random()*8)-3;randNum=Math.floor(randNum);customerCount=customerCount+randNum;if(customerCount>999){customerCount=999;}if(customerCount<3){customerCount=3;}}function CustomerIncrement(){Rand_View_Num();var nowdate=new Date();var hour=nowdate.getHours();var min=nowdate.getMinutes();jQuery('#slider1 p').html(hour+"時"+min+"分現在あなたの他に<span class='blink' style='color:#ffff00;font-weight:bold;'>"+customerCount+"</span>人が見ています");jQuery('#slider3 p').html(hour+"時"+min+"分現在あなたの他に<span class='blink' style='color:#ffff00;font-weight:bold;'>"+customerCount+"</span>人が見ています");}function ProductDecreme |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const functions = require('firebase-functions'); | |
const admin = require('firebase-admin'); | |
admin.initializeApp(functions.config().firebase); | |
var fireStore = admin.firestore(); | |
exports.helloWorld = functions.https.onRequest((request, response) => { | |
if (request.method !== 'POST') { | |
response.status(405).send('method not allowed'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Queryfeed でチャンネルにツイートを垂れ流している場合のみ利用可能 | |
var token = '{slack-token}'; | |
var channelID = '{channel-id}'; | |
var userName = '{user-name}'; // @realDonaldTrump とか | |
function myFunction() { | |
var latest = Math.floor(new Date().getTime() / 1000); | |
var oldest = latest - 24 * 60 * 60; | |
var url = 'https://slack.com/api/channels.history?channel=' + channelID + '&oldest=' + oldest + '&latest=' + latest; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import smbus | |
import time | |
from datetime import datetime | |
from firebase import firebase | |
from pytz import timezone | |
i2c = smbus.SMBus(1) | |
address = 0x5c |