サポート » テーマ » アーカイブとカテゴリのページについて

  • お世話になります。
    WordPress2.5日本語版を使用しています。
    サーバのPHPのVersion 4.3.9です。

    アーカイブとカテゴリのページについて質問ですが、
    通常ページを開くと下記のとおり、現在閲覧中の案内の表示がされますが、
    これを表示させなくしたいのです。

    テーマテンプレートの「archive.php」を修正すれば、
    出来るかと思われますが、どの部分をカットするばよいかが不明です。
    ご指導をよろしくお願いします。

    [案内の表示]
    「*** の 2008 年 5 月 のアーカイブを閲覧中です。」

2件の返信を表示中 - 1 - 2件目 (全2件中)
  • モデレーター IKEDA Yuriko

    (@lilyfan)

    テーマテンプレートの「archive.php」を修正すれば、
    出来るかと思われますが、

    テーマは何をお使いでしょうか? それが分からないと何とも言えません。
    実際に archive.php を開いてみても該当部分が見つからなければ、ローカライズ文字列を使っている可能性があります。出力された HTML コードと、テーマの PHP コードを比較して、それっぽい箇所が見つかりませんか?

    トピック投稿者 igarashi

    (@igarashi)

    lilyfan 様

    テーマはデフォルトのもの使用しておりました。

    すみません。私の方で勘違いをしておりまして、実際に「案内の表示」がされるのは
    サイドバー(sidebar.php)に表示していました。

    HTMLのソースを見たところ、
    <!– Author information is disabled per default. Uncomment and fill in your details if you want to use it.

    • <h2>作成者</h2>
      <p>A little something about you, the author. Nothing lengthy, just an overview.</p>
    • –>

    • <p>テスト の 2008 年 5 月 のアーカイブを閲覧中です。</p>
    • <!—->で囲まれた部分の下に書かれていましたので、
      テーマのサイドバー(sidebar.php)と比較して、下記部分の<p></p>で囲まれた内のタグをカットしてみたところ非表示にすることが出来ました。

      <p><?php printf(__(‘You are currently browsing the archives for the %s category.’, ‘kubrick’), single_cat_title(”, false)); ?></p>

      <?php /* If this is a yearly archive */ } elseif (is_day()) { ?>
      <p><?php printf(__(‘You are currently browsing the %2$s blog archives for the day %3$s.’, ‘kubrick’), get_bloginfo(‘url’), get_bloginfo(‘name’), get_the_time(__(‘l, F jS, Y’, ‘kubrick’))); ?></p>

      <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
      <p><?php printf(__(‘You are currently browsing the %2$s blog archives for %3$s.’, ‘kubrick’), get_bloginfo(‘url’), get_bloginfo(‘name’), get_the_time(__(‘F, Y’, ‘kubrick’))); ?></p>

      <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
      <p><?php printf(__(‘You are currently browsing the %2$s blog archives for the year %3$s.’, ‘kubrick’), get_bloginfo(‘url’), get_bloginfo(‘name’), get_the_time(‘Y’)); ?></p>

      <?php /* If this is a monthly archive */ } elseif (is_search()) { ?>
      <p><?php printf(__(‘You have searched the %2$s blog archives for ‘%3$s’. If you are unable to find anything in these search results, you can try one of these links.’, ‘kubrick’), get_bloginfo(‘url’), get_bloginfo(‘name’), get_search_query()); ?></p>

      <?php /* If this is a monthly archive */ } elseif (isset($_GET[‘paged’]) && !empty($_GET[‘paged’])) { ?>
      <p><?php printf(__(‘You are currently browsing the %2$s blog archives.’, ‘kubrick’), get_bloginfo(‘url’), get_bloginfo(‘name’)); ?></p>

      ご指導ありがとうございました。

2件の返信を表示中 - 1 - 2件目 (全2件中)
  • トピック「アーカイブとカテゴリのページについて」には新たに返信することはできません。