WP PLUGIN アーカイブページの投稿表示順設定

・不要な初期化を削除
・カスタムタクソノミー対応
・設定画面のタブ化
・設定画面各タクソノミーの投稿リスト表示をメソッド化
・name属性の閉じ忘れ修正
・不要なreturn削除
・APOP_UI::create_product_none_order_list() returnに変数が未設定の場合の条件を追加
・readmeに若干加筆
This commit is contained in:
2021-05-05 17:48:32 +09:00
parent 7722f53f10
commit 05b5fa91aa
12 changed files with 280 additions and 173 deletions
+5 -5
View File
@@ -4,7 +4,7 @@ $all_tags = APOP_UI::get_all_taxonomies( 'post_tag' );
$all_tax = APOP_UI::get_all_taxonomies( 'taxonomy' );
?>
<div class="post-order-box">
<div class="post-setting-box">
<form action="" method="post">
<?php
wp_nonce_field( 'sh_options' );
@@ -13,10 +13,10 @@ $all_tax = APOP_UI::get_all_taxonomies( 'taxonomy' );
$opt_tax = get_option( '_apop_tax_order' );
?>
<h2>対象タクソノミー選択</h2>
<table>
<table class="form-table">
<?php if ( count( $all_categories ) > 0 ): ?>
<tr>
<th>カテゴリー</th>
<th scope="row">カテゴリー</th>
<td>
<ul class="order_setting_list">
<?php foreach ( $all_categories as $category ): ?>
@@ -42,7 +42,7 @@ $all_tax = APOP_UI::get_all_taxonomies( 'taxonomy' );
<?php endif; ?>
<?php if ( count( $all_tags ) > 0 ): ?>
<tr>
<th>タグ</th>
<th scope="row">タグ</th>
<td>
<ul class="order_setting_list">
<?php foreach ( $all_tags as $tag ): ?>
@@ -68,7 +68,7 @@ $all_tax = APOP_UI::get_all_taxonomies( 'taxonomy' );
<?php endif; ?>
<?php if ( count( $all_tax ) > 0 ): ?>
<tr>
<th>カスタム分類</th>
<th scope="row">カスタム分類</th>
<td>
<ul class="order_setting_list">
<?php foreach ( $all_tax as $tax ): $all_taxs = APOP_UI::get_all_taxonomies( $tax ) ?>