Title: tetch1987の返信 | WordPress.org 日本語

---

# tetch1987

  [  ](https://ja.wordpress.org/support/users/tetch1987/)

 *   [プロフィール](https://ja.wordpress.org/support/users/tetch1987/)
 *   [作成したトピック](https://ja.wordpress.org/support/users/tetch1987/topics/)
 *   [作成した返信](https://ja.wordpress.org/support/users/tetch1987/replies/)
 *   [返信したトピック](https://ja.wordpress.org/support/users/tetch1987/replied-to/)
 *   [エンゲージメント](https://ja.wordpress.org/support/users/tetch1987/engagements/)
 *   [お気に入り](https://ja.wordpress.org/support/users/tetch1987/favorites/)

 返信を検索

## フォーラムへの返信

2件の返信を表示中 - 1 - 2件目 (全2件中)

 *   フォーラム: [テーマ](https://ja.wordpress.org/support/forum/themes/)
    返信が
   含まれるトピック: [著者ページ(author.php)の記事一覧にページ送りは可能ですか？](https://ja.wordpress.org/support/topic/%e8%91%97%e8%80%85%e3%83%9a%e3%83%bc%e3%82%b8authorphp%e3%81%ae%e8%a8%98%e4%ba%8b%e4%b8%80%e8%a6%a7%e3%81%ab%e3%83%9a%e3%83%bc%e3%82%b8%e9%80%81%e3%82%8a%e3%81%af%e5%8f%af%e8%83%bd%e3%81%a7%e3%81%99/)
 *  トピック投稿者 [tetch1987](https://ja.wordpress.org/support/users/tetch1987/)
 * (@tetch1987)
 * [12年、 2ヶ月前](https://ja.wordpress.org/support/topic/%e8%91%97%e8%80%85%e3%83%9a%e3%83%bc%e3%82%b8authorphp%e3%81%ae%e8%a8%98%e4%ba%8b%e4%b8%80%e8%a6%a7%e3%81%ab%e3%83%9a%e3%83%bc%e3%82%b8%e9%80%81%e3%82%8a%e3%81%af%e5%8f%af%e8%83%bd%e3%81%a7%e3%81%99/#post-187482)
 * 以下のコードを初心者ながら自作したところページ送りの部分だけ動きはしたのですが、
   WPの関数を利用した方法があればそちらを利用したいと考えています。また、WP-PageNavi
   の吐き出す「1」「2」…のような表記をさせるにはもっと考えなくてはいけません。
 *     ```
       <?php
       $PageNum = 0;
       $ParPosts = 5;
       if(is_numeric($_GET['pnum']) && isset($_GET['pnum'])){
       	$PageNum = htmlspecialchars($_GET['pnum']);
       	$PageNum = addslashes($PageNum);
       }
       $pnum_prev = $PageNum-1;
       $pnum_next = $PageNum+1;
       $DispPost = $PageNum*$ParPosts;
       $this_author = $user_data->user_login;
   
       $paged = get_query_var('paged');
       $args = array(
       	'author' => $user_data->ID,
       	'posts_per_page' => 5,
       	'offset' => $DispPost,
       	'paged' => $paged);
       $the_query = new WP_Query($args);
       $PageMax = $the_query->found_posts;
       if($post) : while ( $the_query->have_posts() ) : $the_query->the_post(); ?>
       <!--
   
       ループ内の記述
   
       -->
       <?php endwhile; ?>
       <p id="PageNavigation">
       <?php
       $MaxPages = $PageMax/$ParPosts;
       if($pnum_prev == 0) : ?>
       <a href="http://domain.com/<?php echo $this_author; ?>/">前の記事</a>
       <?php elseif($pnum_prev > 0) : ?>
       <a href="http://domain.com/<?php echo $this_author; ?>/?pnum=<?php echo $pnum_prev; ?>">前の記事</a>
       <?php endif; ?>
        |
       <?php
       if($pnum_next < $MaxPages) : ?>
       <a href="http://domain.com/<?php echo $this_author; ?>/?pnum=<?php echo $pnum_next; ?>">次の記事</a>
       <?php endif; ?></p>
       <?php endif; wp_reset_query(); ?>
       ```
   
 *   フォーラム: [使い方全般](https://ja.wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   返信が含まれるトピック: [複数のカスタム分類を利用した場合のパーマリンクについて](https://ja.wordpress.org/support/topic/%e8%a4%87%e6%95%b0%e3%81%ae%e3%82%ab%e3%82%b9%e3%82%bf%e3%83%a0%e5%88%86%e9%a1%9e%e3%82%92%e5%88%a9%e7%94%a8%e3%81%97%e3%81%9f%e5%a0%b4%e5%90%88%e3%81%ae%e3%83%91%e3%83%bc%e3%83%9e%e3%83%aa%e3%83%b3/)
 *  トピック投稿者 [tetch1987](https://ja.wordpress.org/support/users/tetch1987/)
 * (@tetch1987)
 * [12年、 3ヶ月前](https://ja.wordpress.org/support/topic/%e8%a4%87%e6%95%b0%e3%81%ae%e3%82%ab%e3%82%b9%e3%82%bf%e3%83%a0%e5%88%86%e9%a1%9e%e3%82%92%e5%88%a9%e7%94%a8%e3%81%97%e3%81%9f%e5%a0%b4%e5%90%88%e3%81%ae%e3%83%91%e3%83%bc%e3%83%9e%e3%83%aa%e3%83%b3/#post-177595)
 * すみません。どうゆう仕組みか分かりませんが以下のようにすれば、複数のタクソノミー
   の指定が表示されました。
 * ▽ジャンルでの表示
    ・パーマリンク [http://sample.com/genre/rock?area=japan](http://sample.com/genre/rock?area=japan)
 * ▽地域での表示
    ・パーマリンク [http://sample.com/area/japan?genre=rock](http://sample.com/area/japan?genre=rock)
 * テンプレートはarichive.phpが利用されました。
    また、wp_title();での出力結果は、
   両方「ジャンル ロック」になりました。
 * こうゆうとこWordpressすごいですね。
 * 汚してしまい申し訳ございません。

2件の返信を表示中 - 1 - 2件目 (全2件中)