welcartを入れる
D/d_parts/welcart
をコピーして入れる
f4_int.less(中心less)
に
@import "../d_parts/welcart/welcart.less";
@import "../4_custom/welcart/welcart.less"; // welcart
追加
welcart_funcに
$welcart_cat= 287;
$welcart_cat_out= -287;
の商品カテゴリにのIDを記載
//除外したいカテゴリIDを入れる
if ( ! in_array( $parent->term_id, array( 287,290 ) ) )
を変更
// テキストエディタにクイックタグボタンを追加
もここで変更する
シンプルカスタムフィールドで
商品詳細フィールドを作成
商品詳細
WYSIWYG
item_info
投稿
ブログトップ
記事すべて読む
part_blog_top.php
に商品を表示させないコードを追加
//ブログトップ
<?php query_posts('post_type=post&cat='.$info_cat_out.','.$welcart_cat_out .'&paged='.$paged);
//記事すべて読む
<?php query_posts('post_type=post&posts_per_page=12&cat='.$info_cat_out.','.$welcart_cat_out .'&paged='.$paged);
//part_blog_top.php
<?php
$args = array(
'posts_per_page' => 6,
'post_type' => 'post', //カスタム投稿名
'cat' => $info_cat_out.','.$welcart_cat_out,
)
?>
ブログサイドバーにカテゴリを使うなら
blog_side_menu.phpに
'exclude_tree' => $welcart_cat_out,//welcartの商品ID
を追加
アーカーイブに
<?php //--------------------------------商品アーカイブなら
if( in_category( 'item' ) ||
//親カテゴリスラッグで分岐 ファンクションコード使用
post_is_in_descendant_category( get_term_by( 'slug', 'item', 'category' ))):
?>
<?php include(get_stylesheet_directory() . "/d_parts/welcart/welcart-archive.php"); ?>
<? return; endif;?>
を入れてリターンさせる
カスタムアドミンでいらないものを隠す
使いやすくする
custom-admin-css.css
/*welcart 商品詳細入力の横タイトル消す*/
.smart-cf-meta-box th{display: none;}
/*商品詳細本文欄*/
.welcart-shop_page_usces_itemedit #wp-content-wrap
,.welcart-shop_page_usces_itemedit #postdivrich
/*商品詳細本文文字 これで効く不明*/
,div.inside div.itempagetitle:nth-of-type(3)
/*商品オプション*/
,#itemoption
,.welcart-shop_page_usces_itemedit #cftdiv
,.welcart-shop_page_usces_itemedit #cfs_input_991
,.welcart-shop_page_usces_itemedit #tagsdiv-post_tag
,.welcart-shop_page_usces_itemedit #postimagediv
,.welcart-shop_page_usces_itemedit #commentsdiv
,.welcart-shop_page_usces_itemedit #yarpp_relatedposts
{display: none;}
/*SKU追加ボタンを忘れがちだから赤化*/
#newskusubmit input{ background: #e14d43;
border-color: #d02c21;
color: #fff;
-webkit-box-shadow: inset 0 1px 0 #ec8b85,0 1px 0 rgba(0,0,0,.15);
box-shadow: inset 0 1px 0 #ec8b85,0 1px 0 rgba(0,0,0,.15);
margin-bottom:15px;}
/*編集画面がちいさいから スマート*/
#smart_custom_fields_item_info__0__ifr{min-height: 600px;}
エディター画面にテーブルcssを対応させる
editor-style.css
/*welcart*/
.size_table th{background: #ececec;text-align: center;}
.size_table td{text-align: center;}
.size_table th,.size_table td{padding: 10px;}
xserverの管理画面でssl対応する
アップしたワードプレスの設定をhttpsに変更
htaccessに
RewriteEngine On
RewriteCond %{HTTPS} !on
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
を追加
ラインウィジェットのアイコン画像のurlをhttpsに
google jsを
http://から
//
にする。
コンテンツエディタで投稿したものは
http になっているので
すべてhttpsに変換するべし
プラグインありそう
OK
月: 2017年11月
地域 まとめ
ファンク 地域
function cptui_register_my_taxes_service_chiiki() {
/**
* Taxonomy: 周辺地域.
*/
$labels = array(
"name" => __( '対応地域', '' ),
"singular_name" => __( '対応地域', '' ),
);
$args = array(
"label" => __( '対応地域', '' ),
"labels" => $labels,
"public" => true,
"hierarchical" => true,
"label" => "対応地域",
"show_ui" => true,
"show_in_menu" => true,
"show_in_nav_menus" => true,
"query_var" => true,
"rewrite" => array( 'slug' => '対応地域', 'with_front' => true, ),
"show_admin_column" => false,
"show_in_rest" => false,
"rest_base" => "",
"show_in_quick_edit" => false,
);
register_taxonomy( "service_chiiki", array( "site","post" ), $args );
}
add_action( 'init', 'cptui_register_my_taxes_service_chiiki' );
サイドバーのリスト表示
css 親子だとliでおかしな表示になるのでliで表示さあせない
そのため a で表示
css
con
.service_chiiki{
a{display: inline-block;}
a:after{content:",\00A0";}
overflow: hidden;
//li{float: left;}
//li a:after{content:",\00A0";}
}
親子無視リストなし
<div class="side_shop service_chiiki" style="margin-top:20px;">
★対応地域<br>
<?php
$args = array(
'show_option_all' => '',
'orderby' => 'name',
'order' => 'ASC',
'style' => 'none',
'show_count' => 0,
'hide_empty' => 0,
'use_desc_for_title' => 1,
'child_of' => 0,
'feed' => '',
'feed_type' => '',
'feed_image' => '',
'exclude' => '',
'exclude_tree' => '',
'include' => '',
'hierarchical' => 1,
'title_li' => __( '' ),
'show_option_none' => __( '' ),
'number' => null,
'echo' => 0,
'depth' => 0,
'current_category' => 0,
'pad_counts' => 0,
'taxonomy' => 'service_chiiki',
'walker' => null
);
$list = wp_list_categories( $args );
$list = str_replace("<br />", "", $list);
echo $list;
?>
<div style="clear:both"></div>
その他地域もお気軽にご相談下さい。
</div>
ブログサイドバー用 分岐+ ドロップダウン
買取地域は 別にタクソノミー(ブログ買取地域はblog_chiiki として サービス地域と全く同じものを入れる )
WP Taxonomy Import 設定からインポートすると楽
//ブログサイドバー blog_side_menu.php
//ドロップダウン地域 blog_side_menu_chiiki.php
シングル追加 カテゴリに地域 roop.php
<div class="blog_deta"><ul><li><?php the_time('Y.m.d'); ?></li><li class="blogcate_icon"><?php the_category(', '); ?>
<?php echo get_the_term_list( $post->ID, 'blog_chiiki', ', ', ', ', '' ); ?>
</li></ul>
タクソノミーに追加
<?php elseif(is_tax('blog_chiiki')):?>
<?php include( get_stylesheet_directory() . '/archive.php'); ?>
<?php endif; ?>
アーカイブに追加 archive.php
<h2 class="h2_class">
BLOG <? if(is_tag()):?>タグ:<? elseif(is_tax('blog_chiiki')):?>古本出張買取実績:<? else:?> カテゴリ:<? endif;?><?php single_term_title(); ?>
</h2>
カテゴリの説明と画像を取得してservice_chiiki にひょうじさせる
アドバンスカスタムフィールど使用 cat_img 画像ID
説明はそのままディスプリクション
さらにブログカテゴリーにその同じ名前の記事があればリンクを表示させる
<!--個-->
<h3 class="h3_class2" style="margin-bottom:30px;">趣味の本の出張買取 <span class="d_price"></span></h3>
<?php
$tarmname = '趣味の本 出張買取';
$tarm_id = get_category_by_slug($tarmname)->term_id;//ここまでディスプ&画像
$post_id = 'category_'.$tarm_id;
$catimg = get_field('cat_img',$post_id);
$img = wp_get_attachment_image_src($catimg, 'd_jirei_img');
?>
<div style="position:relative; float:left;">
<? if($catimg):?>
<img src="<?php echo $img[0]; ?>" width="320" class="img_left img_waku" alt="<?php echo $tarmname; ?>|<?php echo $alt1; ?> ">
<?php else: ?>
<img src="<?php echo get_stylesheet_directory_uri(); ?>/d/img/page_sam2.jpg" width="320" class="img_left img_waku" alt="キーワード|<?php echo $alt1; ?> ">
<?php endif; ?>
</div>
<p>
<?php
echo category_description($tarm_id); ?>
<br>
</p>
<?php //関連制作事例コード
$taxonomy_name = 'category';
$args = array(
'slug' => $tarmname
);
$taxonomy_term = get_terms($taxonomy_name,$args);
if(!is_wp_error( $taxonomy_term) && count( $taxonomy_term)):
$url = get_term_link($tarmname, $taxonomy_name);
?>
<div class="jirei_link">
<a href="<?php echo $url; ?>" class=" link_bottan"><?php echo $tarmname; ?>実績 ▶▶</a>
</div>
<?php
endif; //--------ここまで
?>
<div style="clear:both"></div>
<br>
さらに
サービス地域の最下段で 同じ地域のブログがあればブログ 出す
<?php //------------ブログあれば出す
$cat_name = single_term_title("", false);
$args = array(
'posts_per_page' => 3,
'post_type' => 'post', //カスタム投稿名
'cat' => $info_cat_out,
'tax_query' => array(
'relation' => 'AND',
array(
'taxonomy' => 'blog_chiiki',
'field' => 'slug',
'terms' => $cat_name,
//'operator'=>'NOT IN'
),
),
// 'category_name' => $cat_name,
)
?>
<?php
$myposts = get_posts( $args );
if( $myposts){ echo '
<br><br>
<h2 class="h2_class">'. $cat_name .'出張買取実績</h2>
<div class="flex_box" style="padding-top:24px;">
';}
foreach ( $myposts as $post ) : setup_postdata( $post ); ?>
<?php include(get_stylesheet_directory() . "/d_roop/a_blog_box1.php"); ?>
<?php endforeach;
if( $myposts){ echo '
</div>
<div class="tsuzuki_box">
<a href="/blog_chiiki/'. $cat_name .'/" class="link_all link_bottan" style=" font-size:13px;">すべて見る ▶▶</a>
</div>
';}
wp_reset_postdata();//------------ブログあれば出す ?>
Shop 制作時追加
シンプルカスタムで
コンテンツを追加
出力
https://ja.wordpress.org/support/topic/smart-custom-fields%E3%81%AEwysiwyg-%E3%83%95%E3%82%A3%E3%83%BC%E3%83%AB%E3%83%89%E6%8A%95%E7%A8%BF%E3%81%AB%E3%81%A4%E3%81%84%E3%81%A6/
<?php
$cf_sample = SCF::get('aaa');
echo wp_kses_post($cf_sample);
?>
但しクイックタグが利用できないので
自作クイックタグを テキストの方で
表示させる
テーブル
追加する
プラグイン不要!WordPressのテキストエディタにタグ挿入クイックタグボタンを追加する方法
WordPressで脱プラグイン!AddQuicktagを使わないでコード挿入ボタンを増やす方法
カスタムアドミン
/*welcart*/
.size_table th{background: #ececec;text-align: center;}
.size_table td{text-align: center;}
.size_table th,.size_table td{padding: 10px;}
xserverの管理画面でssl対応する
アップしたワードプレスの設定をhttpsに変更
htaccessに
RewriteEngine On
RewriteCond %{HTTPS} !on
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
を追加
ラインウィジェットのアイコン画像のurlをhttpsに
google jsを
http://から
//
にする。
コンテンツエディタで投稿したものは
http になっているので
すべてhttpsに変換するべし
プラグインありそう
OK
河島 製作時 追加
.mob_br{display: inline-block}
スライダー おかいしい コード
<?php if(!is_home()):?></div><? endif;?>
スライダー モブ
.sl_under_p{ font-size:14px;width:80%; margin:0 auto;
margin-bottom:24px;}
con
.service_chiiki{
a{display: inline-block;}
a:after{content:",\00A0";}
overflow: hidden;
//li{float: left;}
//li a:after{content:",\00A0";}
}
ファンク 地域
function cptui_register_my_taxes_service_chiiki() {
/**
* Taxonomy: 周辺地域.
*/
$labels = array(
"name" => __( '対応地域', '' ),
"singular_name" => __( '対応地域', '' ),
);
$args = array(
"label" => __( '対応地域', '' ),
"labels" => $labels,
"public" => true,
"hierarchical" => true,
"label" => "対応地域",
"show_ui" => true,
"show_in_menu" => true,
"show_in_nav_menus" => true,
"query_var" => true,
"rewrite" => array( 'slug' => '対応地域', 'with_front' => true, ),
"show_admin_column" => false,
"show_in_rest" => false,
"rest_base" => "",
"show_in_quick_edit" => false,
);
register_taxonomy( "service_chiiki", array( "site","post" ), $args );
}
add_action( 'init', 'cptui_register_my_taxes_service_chiiki' );
親子無視リストなし
<div class="side_shop service_chiiki" style="margin-top:20px;">
★対応地域<br>
<?php
$args = array(
'show_option_all' => '',
'orderby' => 'name',
'order' => 'ASC',
'style' => 'none',
'show_count' => 0,
'hide_empty' => 0,
'use_desc_for_title' => 1,
'child_of' => 0,
'feed' => '',
'feed_type' => '',
'feed_image' => '',
'exclude' => '',
'exclude_tree' => '',
'include' => '',
'hierarchical' => 1,
'title_li' => __( '' ),
'show_option_none' => __( '' ),
'number' => null,
'echo' => 0,
'depth' => 0,
'current_category' => 0,
'pad_counts' => 0,
'taxonomy' => 'service_chiiki',
'walker' => null
);
$list = wp_list_categories( $args );
$list = str_replace("<br />", "", $list);
echo $list;
?>
<div style="clear:both"></div>
その他地域もお気軽にご相談下さい。
</div>
ブログサイドバー用 分岐+ ドロップダウン
買取地域は 別にタクソノミー
<?php if(is_page('ブログトップ') || is_page('blog-all') || is_category() ||is_tag()||is_month()||is_author() || is_singular('post')||is_tax('blog_chiiki')) :?>
<h3 class="side_blog_cat_title">
<a href="<?php echo home_url(); ?>/ブログトップ/">
古本出張買取ブログ</a>
</h3>
<div style="padding-top:20px;"></div>
<ul class="blog_side_menu">
<?php wp_list_categories(array(
'title_li' => '',//最初に何も入れない 入れると<li class="categories">入れた文字<ul>リスト一覧</ul></li>となる
'taxonomy' => 'category', //カテゴリ
'show_count' => 0,
'hide_empty' => 0, //記事がなくとも表示
'orderby' => 'order',//順番は指定します
'depth' => 0,//子は表示しません。
'exclude' => 30,
)); ?>
</ul><br>
<ul class="car_side_menu">
<?php $cats = get_categories(array(
'post_type' => 'post',
'taxonomy' => 'blog_chiiki' ,
'hide_empty' => 0 ,//記事がなくとも表示
'depth' => 1,//子は表示しません。
'orderby' => 'order',//順番は指定します
)); ?>
<?php if(!empty($cats)): ?>
<select name="cat" id="cat">
<option value=" ">古本出張買取地域</option>
<?php foreach($cats as $cat): ?>
<option value="<?php $cat_term = $cat->slug; echo get_term_link($cat_term ,'blog_chiiki'); ?>"><?php echo $cat->cat_name; ?>(<?php echo $cat->count; ?>)</option>
<?php endforeach; ?>
</select>
<script type="text/javascript">
var dropdown = document.getElementById("cat");
function onCatChange(){
if(dropdown.options[dropdown.selectedIndex].value != ""){
location.href = dropdown.options[dropdown.selectedIndex].value;
}
}
dropdown.onchange = onCatChange;
</script>
<?php endif; ?>
</ul>
<br>
<br>
<?php endif; ?>
シングル追加 カテゴリに地域
<div class="blog_deta"><ul><li><?php the_time('Y.m.d'); ?></li><li class="blogcate_icon"><?php the_category(', '); ?>
<?php echo get_the_term_list( $post->ID, 'blog_chiiki', ', ', ', ', '' ); ?>
</li></ul>
アーカイブに追加
<h2 class="h2_class">
BLOG <? if(is_tag()):?>タグ:<? elseif(is_tax('blog_chiiki')):?>古本出張買取実績:<? else:?> カテゴリ:<? endif;?><?php single_term_title(); ?>
</h2>
タクソノミーに追加
<?php elseif(is_tax('blog_chiiki')):?>
<?php include( get_stylesheet_directory() . '/archive.php'); ?>
<?php endif; ?>
カテゴリから説明と画像を取得
<!--個-->
<h3 class="h3_class2" style="margin-bottom:30px;">趣味の本の出張買取 <span class="d_price"></span></h3>
<?php
$tarmname = '趣味の本 出張買取';
$tarm_id = get_category_by_slug($tarmname)->term_id;//ここまでディスプ&画像
$post_id = 'category_'.$tarm_id;
$catimg = get_field('cat_img',$post_id);
$img = wp_get_attachment_image_src($catimg, 'd_jirei_img');
?>
<div style="position:relative; float:left;">
<? if($catimg):?>
<img src="<?php echo $img[0]; ?>" width="320" class="img_left img_waku" alt="<?php echo $tarmname; ?>|<?php echo $alt1; ?> ">
<?php else: ?>
<img src="<?php echo get_stylesheet_directory_uri(); ?>/d/img/page_sam2.jpg" width="320" class="img_left img_waku" alt="キーワード|<?php echo $alt1; ?> ">
<?php endif; ?>
</div>
<p>
<?php
echo category_description($tarm_id); ?>
<br>
</p>
<?php //関連制作事例コード
$taxonomy_name = 'category';
$args = array(
'slug' => $tarmname
);
$taxonomy_term = get_terms($taxonomy_name,$args);
if(!is_wp_error( $taxonomy_term) && count( $taxonomy_term)):
$url = get_term_link($tarmname, $taxonomy_name);
?>
<div class="jirei_link">
<a href="<?php echo $url; ?>" class=" link_bottan"><?php echo $tarmname; ?>実績 ▶▶</a>
</div>
<?php
endif; //--------ここまで
?>
<div style="clear:both"></div>
<br>
サービス地域の最下段 あればブログ 出す
<?php //------------ブログあれば出す
$cat_name = single_term_title("", false);
$args = array(
'posts_per_page' => 3,
'post_type' => 'post', //カスタム投稿名
'cat' => $info_cat_out,
'tax_query' => array(
'relation' => 'AND',
array(
'taxonomy' => 'blog_chiiki',
'field' => 'slug',
'terms' => $cat_name,
//'operator'=>'NOT IN'
),
),
// 'category_name' => $cat_name,
)
?>
<?php
$myposts = get_posts( $args );
if( $myposts){ echo '
<br><br>
<h2 class="h2_class">'. $cat_name .'出張買取実績</h2>
<div class="flex_box" style="padding-top:24px;">
';}
foreach ( $myposts as $post ) : setup_postdata( $post ); ?>
<?php include(get_stylesheet_directory() . "/d_roop/a_blog_box1.php"); ?>
<?php endforeach;
if( $myposts){ echo '
</div>
<div class="tsuzuki_box">
<a href="/blog_chiiki/'. $cat_name .'/" class="link_all link_bottan" style=" font-size:13px;">すべて見る ▶▶</a>
</div>
';}
wp_reset_postdata();//------------ブログあれば出す ?>
問い合わせ促しと ブログカテゴリサイド と 丸画像の見出し
css 印と
//tel_mail_box
@mail_color:#8c6239;
.info_mail_box{ width: 100%; margin-top: 84px;
position: relative;
.info_mail_box_h2{ padding: 12px; background: lighten(@mail_color,0%); color: #fff; font-size: 14px;}
.info_mail_box_h3{padding: 12px 12px; font-size:24px; font-weight: bold;
// border-left: solid 1px #8c6239;
// border-right: solid 1px #8c6239;
background: lighten(@mail_color,55%);
}
.tel_mail_box{background: @mail_color; color: #fff;
.flex_box;
.com__box{width: 100%; font-size: 20px;padding: 12px 24px 0 24px;}
.tel__box{padding: 0px 24px 12px 24px; width: 50%;
.tell{font-family: 'Roboto Condensed', sans-serif; font-size: 52px; }
.tell_time{ font-size: 17px; padding: 12px; text-align: center; background: lighten(@mail_color,10%);}
}
.mail__box{padding: 0px 24px 12px 24px; width: 50%;
text-align: center;
.mailform_bottan{width: 100%; display: inline-block;}
.mail_time{text-align: left; padding: 12px;}
z-index: 1;
}
.man_photo{position: absolute; right: 0; margin-top: -82px;z-index: 0}
}
}
@media screen and (max-width: 736px) {
.info_mail_box{
.info_mail_box_h2{ font-size: 13px;}
.info_mail_box_h3{font-size:20px;
}
.tel_mail_box{
.flex_box;
.com__box{width: 100%; font-size: 18px;}
.tel__box{ width: 100%;
.tell{font-size: 44px;}
.tell_time{ font-size: 14px;}
}
.mail__box{width: 100%;
.mailform_bottan{width: 100%; margin-top: 0px; }
.mail_time{display: none;}
z-index: 1;
}
.man_photo{ margin-top: 162px; display: none;
max-width: 100px;
img{width: 100%; height: auto;}
}
}
}
}
.page_img1{float: right; width: 24%; margin-right: 12px; img{width: 100%}}
@media screen and (max-width: 736px) {
.page_img1{ width: 44%; }
}
//ブログメニュー
@side_color:#956743;
.side_blog_cat_title a {display: block; padding: 12px; background: @side_color; color: #fff}
.blog_side_menu li a{display: block;
background: #fff;
margin-bottom: 6px;
padding: 6px 12px;
border-left: solid 4px @side_color}
.blog_side_menu li a:hover{background: @side_color; color: #fff; text-decoration: none;}
全部
if (!empty($terms) && !is_wp_error( $terms)) {
じゃないといかん
もしくは
カテゴリと同じくelse
car を g2バイクに直した時に出た修正
disp.php
elseif(is_post_type_archive( 'car' )){
$disp = '中古原付バイク販売TOP';//falseで出力せん //single_term_titleでも同じ
//過去の出演予定判断
$sortset = (string)filter_input(INPUT_GET, 'sort');
if ( $sortset == 'newer' ) :
$disp = '中古原付バイク販売TOP|新着順';
elseif ( $sortset == 'car_price_low' ) :
$disp = '中古原付バイク販売TOP|低価格順';
elseif ( $sortset == 'car_price_high' ) :
$disp = '中古原付バイク販売TOP|高価格順';
elseif ( $sortset == 'car_km_low' ) :
$disp = '中古原付バイク販売TOP|走行距離が短い順';
elseif ( $sortset == 'car_year_new' ) :
$disp = '中古原付バイク販売TOP|年式が新しい順';
elseif ( $sortset == 'car_cc_big' ) :
$disp = '中古原付バイク販売TOP|排気量が大きい順';
elseif ( $sortset == 'car_cc_big' ) :
$disp = '中古原付バイク販売TOP|排気量が小さい順';
endif;
$description = $disp . $disp_page .' | '. $disp_base;
}
d_h_title
//カスタムポストタイプアーカイブ指定
//car TOPなら
elseif(is_post_type_archive( 'car' )):
$disp = '中古原付バイク販売TOP';
//並び替え判断
$sortset = (string)filter_input(INPUT_GET, 'sort');
if ( $sortset == 'newer' ) :
$disp = '中古原付バイク販売TOP|新着順';
elseif ( $sortset == 'car_price_low' ) :
$disp = '中古原付バイク販売TOP|低価格順';
elseif ( $sortset == 'car_price_high' ) :
$disp = '中古原付バイク販売TOP|高価格順';
elseif ( $sortset == 'car_km_low' ) :
$disp = '中古原付バイク販売TOP|走行距離が短い順';
elseif ( $sortset == 'car_year_new' ) :
$disp = '中古原付バイク販売TOP|年式が新しい順';
elseif ( $sortset == 'car_cc_big' ) :
$disp = '中古原付バイク販売TOP|排気量が大きい順';
elseif ( $sortset == 'car_cc_big' ) :
$disp = '中古原付バイク販売TOP|排気量が小さい順';
endif;
echo $disp.' | ';
FB OG が アーカイブの設定が出来ていない模様
タイトル等設定してからやる
car.css
.flickSlider .flickThumb {
width: 100%;
overflow: hidden;
margin-top: 6px;
カスタム の 車 その他 が 投稿タイプなってない
メーカー car_maker が変わらないのはcar_maker がいけない
car_maker2にすると かわらないのが治った
特にテンプレの変更箇所ない
走行距離においては
数字で入れていないので
'type' => 'DECIMAL(3,1)', //値のタイプ 数字
としなければならない
参照
https://hacknote.jp/archives/24699/
シングルいらない
<td colspan="4" class="td_titel">
<!-- <?php echo implode( ',', $names ); //ターム名区切り文字を指定 ?> -->
<?php the_title(); ?>
hihead しんぐるcar いらない
<?php elseif ( is_singular('car') ) : //--中古車販売 個ページなら--?>
<h1 class="head"><?php
if(mb_strlen($wp_title.$h1_head_min, 'utf-8') > '77'):
$h1_title = mb_substr($wp_title.$h1_head_min, 0, 77, 'utf-8') .'…';
else:
$h1_title = mb_substr($wp_title.$h1_head_min, 0, 77, 'utf-8');
endif;
echo $h1_title
?></h1>
あっても
小カテゴリがひょうじされたりおやがひょうじされたり
タイトルを直した
ブログにタクソノミーを使っていないので
簡単にis_taxで分岐
part_blog_top.phpをゲットポスト
a_blog_box2.php alt 古い
f4 int
body 下に
/*テキストリンク*/
.jirei_link a{color:@link_color; border: solid 1px @link_color; padding: 12px; display: inline-block;}
.jirei_link a:hover{text-decoration: none; color:#fff; background: @link_color;}
blog1box
cat.php がない てかやめる
ファンク追加 印と
//get_the_categoryにかわりで特定のカテゴリを除外するコードの書き方
function my_get_the_category( $id = false, $exclude = array() ) {
$cats = get_the_category( $id );
$excluded_cats = array();
foreach( $cats as $cat ) {
if ( !in_array( $cat->cat_ID, $exclude ) ) {
$excluded_cats[] = $cat;
}
}
return $excluded_cats;
}
//書き方
//$category = my_get_the_category(false, array(1, 2));