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
| /** | |
| * ポイント使用するかの判定 | |
| * | |
| * $status が null の場合は false を返す. | |
| * | |
| * @param integer $status 対応状況 | |
| * @return boolean 使用するか(会員テーブルから減算するか) | |
| */ | |
| function isUsePoint($status) { | |
| if ($status == null) { |
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
| wp_embed_register_handler( | |
| 'qiita', | |
| '#http://qiita.com/(.*)/items/([a-z0-9]+)$#i', | |
| function($m, $attr, $url, $rawattr){ | |
| $url = sprintf("http://qiita.com/api/v2/items/%s", $m[2]); | |
| $result = wp_remote_get($url); | |
| if ( ! is_wp_error( $result ) && $result['response']['code'] === 200 ) { | |
| $data = json_decode($result['body']); | |
| return $data->rendered_body; | |
| } |
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
| wp_embed_register_handler( | |
| 'twitcasting', | |
| '#http://twitcasting.tv/(.*)$#i', | |
| function($m, $attr, $url, $rawattr){ | |
| $width = 320; | |
| $height = 198; | |
| return <<< __EOS__ | |
| <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=10,0,0,0" width="{$width}" height="{$height}" id="livestreamer" align="middle"> | |
| <param name="allowScriptAccess" value="always" /> | |
| <param name="allowFullScreen" value="true" /> |
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 | |
| /* | |
| Plugin Name: oEmbed TwitCasting | |
| Version: 0.1-alpha | |
| Description: Embed source from twitcasting. | |
| Author: kurozumi | |
| Author URI: http://a-zumi.net | |
| Plugin URI: http://a-zumi.net | |
| Text Domain: oembed-twitcasting | |
| Domain Path: /languages |
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 | |
| /* | |
| Plugin Name: WP Setting Page | |
| Version: 0.1-alpha | |
| Description: wordpress setting page template | |
| Author: kurozumi | |
| Author URI: http://a-zumi.net | |
| Plugin URI: http://a-zumi.net | |
| Text Domain: wp-setting-page | |
| Domain Path: /languages |
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
| // Bogo support | |
| if(isset($instance['bogo_locales'])){ | |
| $from .= " LEFT JOIN {$wpdb->postmeta} AS postmeta_bogo ON (p.ID = postmeta_bogo.post_id AND postmeta_bogo.meta_key = '_locale')"; | |
| $tmp_where = array(); | |
| foreach($instance['bogo_locales'] as $locale) | |
| { | |
| if ( bogo_is_default_locale( $locale ) ) | |
| $tmp_where[] = "postmeta_bogo.meta_id IS NULL"; | |
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 | |
| /* | |
| Plugin Name: Wp Metabox Template | |
| Version: 0.1-alpha | |
| Description: metabox template | |
| Author: kurozumi | |
| Author URI: http://a-zumi.net | |
| Plugin URI: http://a-zumi.net | |
| Text Domain: wp-metabox | |
| Domain Path: /languages |
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 | |
| /* | |
| Plugin Name: oEmbed FC2 Video | |
| Version: 0.1-alpha | |
| Description: Embed source from fc2 video. | |
| Author: kurozumi | |
| Author URI: http://a-zumi.net | |
| Plugin URI: http://a-zumi.net | |
| Text Domain: oembed-fc2-video | |
| Domain Path: /languages |
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 | |
| /* | |
| Plugin Name: oEmbed FC2 Live | |
| Version: 0.1-alpha | |
| Description: Embed source from fc2 live. | |
| Author: kurozumi | |
| Author URI: http://a-zumi.net | |
| Plugin URI: http://a-zumi.net | |
| Text Domain: oembed-fc2-live | |
| Domain Path: /languages |
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 Twig | |
| { | |
| public function __construct() | |
| { | |
| $this->ci =& get_instance(); | |
| $loader = new Twig_Loader_Filesystem(VIEWPATH); | |
| $this->twig = new Twig_Environment($loader, array('cache' => APPPATH . "cache/twig", "debug" => true)); | |
| } |