⌘T | go to file |
⌘⌃P | go to project |
⌘R | go to methods |
⌃G | go to line |
⌘KB | toggle side bar |
⌘⇧P | command prompt |
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 | |
function category_list( $atts ) { | |
extract( shortcode_atts( array( | |
'post_type' => 'post', | |
'cat_name' => '', | |
'num' => 3, | |
'class' => 'relational_lists', | |
'orderby' => 'date', | |
), $atts ) ); |
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 function category_list( $atts ) { | |
extract( shortcode_atts( array( | |
'post_type' => 'post', | |
'cat_name' => '', | |
'num' => 3, | |
'class' => 'relational_lists', | |
'order' => 'date', | |
), $atts ) ); | |
global $post; |
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 // https://gist.github.com/marushu/8013747 ← my gists | |
$args = array( | |
'post_type' => get_post_type(), | |
'numberposts' => -1, | |
'orderby' => 'rand' | |
); | |
$no_overlap_posts = get_posts( $args ); | |
setup_postdata( $post ); | |
//$test_array[] = $no_overlap_posts; |
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
<div id="copyright"> | |
<p>Copyright 2010 - <?php echo date('Y', current_time('timestamp')); ?> xxxx xxxx All Rights Reserved.</p> | |
</div><!-- /#copyright --> |
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 nagasa = $(".each_creature_event li.live").size(); | |
var storage = sessionStorage; | |
var storageLength = storage.length; | |
var arr = new Array(); | |
var checkarr = new Array(); | |
var date = new Date(); | |
var unixTimestamp = Math.round( date.getTime() / 1000 ); | |
var pageAttribute = $("html").attr("lang"); | |
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
<section id="data_inner"> | |
<?php | |
// 緊急のお知らせ用カウンタ | |
$boxcounter = 0; | |
// サイトの「今日」の日付を取得 | |
$local_timestamp = current_time( 'timestamp' ); // ローカルのタイムスタンプ | |
$now = gmdate( 'H', $local_timestamp ); // ローカルの時刻文字列 | |
//echo "nowを出力" . $now; // 現在時刻の「時」を出力 | |
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 | |
define('CRON_SCHEDULE_HANDLER', 'load_oricon_entry_38'); | |
// wp-cron で実行させたい処理 | |
function cron_schedule_handler() { | |
load_oricon(); | |
// 指定時間後に再度起動 | |
$time_interval = 5 * 60; // 5 * 60 : 5分おき | |
wp_schedule_single_event( time() + $time_interval, CRON_SCHEDULE_HANDLER ); |
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 | |
// user role display test | |
global $wp_roles; | |
$all_roles = $wp_roles->roles; | |
echo "<pre>"; | |
print_r( $wp_roles ); | |
echo "</pre>"; | |
ditable_roles = apply_filters('editable_roles', $all_roles); | |
echo "<pre>"; | |
print_r( $editable_roles ); |
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
# Copyright (C) 2014 | |
# This file is distributed under the same license as the package. | |
msgid "" | |
msgstr "" | |
"Project-Id-Version: \n" | |
"Report-Msgid-Bugs-To: http://wordpress.org/tag/login-lockdown\n" | |
"POT-Creation-Date: 2014-05-17 05:44:39+00:00\n" | |
"MIME-Version: 1.0\n" | |
"Content-Type: text/plain; charset=UTF-8\n" | |
"Content-Transfer-Encoding: 8bit\n" |