This file contains 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
/* | |
※kintoneでの検索の注意点!! | |
1, 1文字では検索出来ない(最低でも2文字以上) | |
2, 英数字検索が単語単位(cyで、cybozeがヒットしない!) | |
https://help.cybozu.com/ja/k/user/search_details.html | |
*/ | |
// 設定値 | |
const FIELD_CODE1 = "company_name_a"; | |
const FIELD_CODE1_NAME = "会社名A"; |
This file contains 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
// twitterモジュールを読み込み( npm install twitter ) | |
var twitter = require('twitter'); | |
// アプリ登録時に取得したkeyを入れてOAuth認証し、初期化 | |
var client = new twitter({ | |
consumer_key: 'xxxx', | |
consumer_secret: 'xxxxx', | |
access_token_key: 'xxxxx', | |
access_token_secret: 'xxxxx' | |
}); |
This file contains 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 MASTER_CATEGORY_APP_NO = 1; | |
var MASTER_CATEGORY_QUERY = ' 有効フラグ in ("ON") '; | |
var MASTER_BIG_CATEGORY_NAME = '大カテゴリ'; | |
var MASTER_MIDDLE_CATEGORY_NAME = '中カテゴリ'; | |
var MASTER_SMALL_CATEGORY_NAME = '小カテゴリ'; | |
// プルダウンの値を格納するフィールド名(このJSを読み込んでいるアプリ) | |
var BIG_CATEGORY_NAME = '大'; | |
var MIDDLE_CATEGORY_NAME = '中'; |
This file contains 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
<?php | |
// 自分のkintoneの設定 | |
define("API_TOKEN", ""); | |
define("SUB_DOMAIN", ""); | |
define("APP_NO", "1"); | |
//サーバ送信するHTTPヘッダを設定 | |
$options = array( |
This file contains 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
<?php | |
// 50ページ目(24冊✕50ページ=1200冊)までしか表示されなかった | |
for($i=1; $i < 50+1; $i++){ | |
// コンテンツを取得 | |
$ch = curl_init(); | |
curl_setopt_array($ch, [ | |
CURLOPT_URL => 'https://www.amazon.co.jp/s/?rh=n%3A465392%2Cn%3A%21465610%2Cn%3A466280%2Cn%3A2278488051%2Cp_n_publication_date%3A2285541051&sort=date-asc-rank&unfiltered=1&page=' . $i, // 未来30日以内 | |
// CURLOPT_URL => 'https://www.amazon.co.jp/s/?rh=n%3A465392%2Cn%3A%21465610%2Cn%3A466280%2Cn%3A2278488051%2Cp_n_publication_date%3A82837051&sort=date-asc-rank&unfiltered=1&page=' . $i, // 過去30日以内 |
This file contains 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
<?php | |
/* | |
kintone REST APIのupsert自動化の処理時間テスト。 | |
時間かかかるので、コマンドラインから実行する( php upsert.php ) | |
100件で試した所、処理時間は33-38秒だった。単純計算すると1時間で1万レコード? | |
1レコード毎にselect → update/insertしているので遅い(オーバーヘッドがありすぎ) | |
フィールド数が50なのは、csv/excelからのアプリ生成の上限だから(フィールド数は、速度に無関係っぽい) | |
Web APIのエラーコード一覧みたいなのが無いので、エラー処理が出来ない。 |
This file contains 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
<?php session_start() ?> | |
<html> | |
<head> | |
<title>secureimage test</title> | |
</head> | |
<body> | |
<div> | |
<!-- 入力フォーム --> |
This file contains 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
<?php | |
// サンプル初期値を入れておく。POSTされた値があったら、それを使う | |
if(empty($_POST['parents'])){ | |
$posted_parents = "100-0001\n100-0002\n100-0003"; | |
}else{ | |
$posted_parents = $_POST['parents']; | |
} | |
if(empty($_POST['children'])){ | |
$posted_children = "100-0001\n100-0002\n100-0003\n123-4567"; |
This file contains 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
<!doctype html> | |
<html lang="ja"> | |
<head> | |
<meta charset="UTF-8" /> | |
<title>連絡先の第三希望まで選択肢を減らしていくサンプル</title> | |
<script src="http://code.jquery.com/jquery-1.11.2.min.js"></script> | |
<script> | |
$(function() { | |
$("#優先順位1").change(function() { |
This file contains 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
<html> | |
<head> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"> </script> | |
<script> | |
$.getJSON( | |
"http://localhost/rss/rss.php?callback=?", | |
{ rss_num : 5 }, | |
function(json) { | |
alert('b'); |
NewerOlder