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 | |
/** | |
* カスタム | |
* | |
* @package InfoTown | |
* @author Hiroshi Sawai <[email protected]> | |
* @copyright Hiroshi Sawai | |
*/ | |
class MyTheme_SetUp { | |
/** |
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 | |
/** | |
* InfoTown_Attachments_Utilsのテスト | |
* | |
* @package InfoTown | |
* @author Hiroshi Sawai <[email protected]> | |
* @copyright Hiroshi Sawai | |
*/ | |
class InfoTown_Attachments_Utils_Test extends WP_UnitTestCase { | |
public function setUp() { |
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
<!-- http://lokeshdhakar.com/projects/lightbox2/ --> | |
<head> | |
<link rel="stylesheet" href="<?php bloginfo( 'stylesheet_directory' ); ?>/css/lightbox/css/lightbox.css" type="text/css"> | |
<script type="text/javascript" src="<?php bloginfo( 'stylesheet_directory' ); ?>/js/lightbox.min.js"></script> | |
</head> | |
<body> | |
<a data-lightbox="roadtrip" href="original.png"> | |
<img src="thumb.png"> | |
</a> |
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 | |
/* | |
* https://github.com/tuupola/jquery_lazyload | |
*/ | |
?> | |
<?php if ( get_post_thumbnail_id() ): ?> | |
<?php if ( ! is_image_dead_link( get_post_thumbnail_id() ) ) : ?> | |
<a href="<?php the_permalink(); ?>"><?php the_lazyload( get_post_thumbnail_id() ); ?></a> | |
<?php else : ?> | |
<img src="<?php bloginfo( 'template_directory' ); ?>/images/common/nothumb.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
/* ------------------------------------------------------------------- | |
# WordPress required image style | |
------------------------------------------------------------------- */ | |
/* | |
## image align | |
margin is set by $font-size base | |
*/ | |
.aligncenter { | |
display: block; |
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
/** | |
* @module InfoTown | |
*/ | |
jQuery( function ( $ ) { | |
/** | |
* Resizeオブジェクト | |
* | |
* スクロールを管理します。 | |
* | |
* @class Resize |
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
.circle { | |
display: inline-block; | |
width: 60px; | |
height: 60px; | |
border-radius: 30px; | |
color: #fff; | |
background: #ff0000; | |
font-size: 0.75em; | |
font-weight: bold; | |
text-align: center; |
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 | |
ini_set( 'xdebug.var_display_max_children', - 1 ); | |
ini_set( 'xdebug.var_display_max_data', - 1 ); | |
ini_set( 'xdebug.var_display_max_depth', - 1 ); | |
$records = CategoriesTree::get_records_for_category_tree( 起点となるカテゴリーID, array() ); | |
$data = CategoriesTree::set_records_for_category_tree( $records ); | |
$tree = CategoriesTree::get_category_tree( $data[0], array( $data[1][0] ) ); | |
var_dump( $tree ); | |
?> |
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
.menu { | |
position: relative; | |
width: 100%; | |
} | |
.menu__nav { | |
display: block; | |
position: absolute; | |
top: 0; | |
right: 0; |
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 | |
// https://codex.wordpress.org/Post_Status | |
$my_post = array(); | |
$my_post['ID'] = 123 // 投稿ID; | |
$my_post['post_status'] = 'draft'; // 下書き | |
wp_update_post( $my_post ); | |
?> |