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
<?php | |
// 問題: | |
// プログラム引数で与えられる5枚のカード情報から、その5枚を用いて出来る一番強いポーカーの役を判定して出力せよ(*1)(*2)。 | |
// プログラム引数は以下のように与えられる。 | |
// $ prog Ac Th Kd 3h As | |
// カード情報について(*3)(*4)(*5) | |
// 1文字目:数値 (A:エース 2〜9:数字 T:10 J:11 Q:12 K:13) | |
// 2文字目:スート(s:スペード h:ハート d:ダイヤ c:クローバー) | |
// ポーカー役の強さの順番と出力値、それに対応する入力例 |
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
<?php session_start() ?> | |
<html> | |
<head> | |
<title>secureimage test</title> | |
</head> | |
<body> | |
<div> | |
<!-- 入力フォーム --> |
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
<?php | |
/** | |
* プラグイン の情報クラス. | |
*/ | |
class plugin_info{ | |
/** プラグインコード(必須):プラグインを識別する為キーで、他のプラグインと重複しない一意な値である必要があります*/ | |
static $PLUGIN_CODE = "PluginCodeForTest"; | |
/** プラグイン名(必須):EC-CUBE上で表示されるプラグイン名. */ | |
static $PLUGIN_NAME = "テスト用プラグイン"; |
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
<?php | |
class TestPlugin extends SC_Plugin_Base { | |
/** | |
* コンストラクタ | |
* プラグイン情報(dtb_plugin)をメンバ変数をセットします. | |
* @param array $arrSelfInfo dtb_pluginの情報配列 | |
* @return void | |
*/ | |
public function __construct(array $arrSelfInfo) { |
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
function install($arrPlugin) { | |
// ロゴファイルをhtmlディレクトリにコピーします. | |
copy(PLUGIN_UPLOAD_REALDIR . $arrPlugin['plugin_code'] . “/logo.png”, PLUGIN_HTML_REALDIR . $arrPlugin['plugin_code'] . “/logo.png”); | |
} |
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
sub _POST { | |
read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); | |
@pairs = split(/&/, $buffer); | |
foreach $pair (@pairs) { | |
($name, $value) = split(/=/, $pair); | |
#メール項目が「確認メールアドレス」「プライバシーポリシー」なら無視する。 | |
if ($name eq "confirm_email" || $name eq "privacy_policy"){ | |
}else { |
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
if(s % 2 == 0) className = 'mfp_achroma'; | |
//確認メールアドレスとプライバシーポリシー確認は、確認画面に表示しない! | |
if(elmName == 'confirm_email' || elmName == 'privacy_policy'){ | |
}else{ | |
mfp.ConfirmHTML += '<tr class="'+className+'"><th>'+elmName+'</th><td>'+val+'</td>'; | |
} | |
s++; |
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
<html> | |
<head> | |
<script type="text/javascript" src="https://www.google.com/jsapi"></script> | |
<script type="text/javascript"> | |
//RSSソース | |
const RSS_URL = "http://feeds.feedburner.com/messiahworks/rss"; | |
//取得するRSS記事数 | |
const RSS_NUM = 10; |
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
<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'); |
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
<?php | |
// 自分のkintoneの設定 | |
define("API_TOKEN", ""); | |
define("SUB_DOMAIN", ""); | |
define("APP_NO", "1"); | |
//サーバ送信するHTTPヘッダを設定 | |
$options = array( |
OlderNewer