Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
WPBカップ
25 Million+
Websites using our plugins
16+
Years of WordPress experience
3000+
WordPress tutorials
by experts

WordPressの投稿から投稿者名を削除する方法(3つの簡単な方法)

編集メモ: WPBeginner のパートナーリンクから手数料を得ています。手数料は編集者の意見や評価に影響を与えません。編集プロセスについて詳しく知る。

WordPressブログ投稿から投稿者名を削除したいですか?

複数著者のWordPressブログを運営している場合、各ブログ投稿の次の著者名を表示したくない場合があります。しかし、WordPressには著者名を削除するビルトインの方法はなく、投稿を公開するには著者を選択する必要があります。

この投稿では、WordPressブログ投稿から投稿者名を削除する方法をご紹介します。

Remove author name from WordPress posts

なぜ投稿者名を削除したいのか?

WordPressはすべての投稿に、公開日、カテゴリーやタグ、カスタマタクソノミー、投稿者名などのメタデータを追加します。これにより、読者は投稿に関する有益な情報を得ることができ、関連するコンテンツを見つけやすくなります。

しかし、投稿者名を非表示にしたい場合もあるだろう。

例えば、複数のスタッフが共同で投稿した場合、個別投稿者をクレジットするのは不公平かもしれません。複数著者によるWordPressブログを運営していたり、ゲストブロガーを管理している場合は、投稿者名を削除することで、サイトに一貫性を持たせることができます。

それでは、WordPressで投稿者名を削除する方法を見ていきましょう。クイックリンクからお好きな方法にジャンプしてください:

方法1:WPCodeで投稿者名を非表示にする(推奨)

投稿者名を非表示にする最も簡単な方法は、WordPressにカスタムコードを追加することです。

多くの場合、サイトのfunctions.phpファイルにカスタマイザーのコードを追加する手順を記載したガイドを見つけることができます。しかし、コードにエラーがあるとWordPressの一般的なエラーが発生したり、サイトが完全に壊れてしまう可能性があるため、これはお勧めできません。

そこでWPCodeの 出番だ。

この無料プラグインを使えば、サイトを危険にさらすことなく、WordPressにカスタムCSS、PHP、HTMLなどを簡単に追加できる。

はじめに、WPCodeをインストールし、有効化する必要があります。詳しくは、WordPressプラグインのインストール方法のステップバイステップガイドをご覧ください。

始める前に、WordPressテーマで投稿者名をどのように表示するかをコントロールするクラスを知っておく必要があります。この情報を得るには、著者名を含むページや投稿を開いてください。

次に、画面上で右クリックまたはコントロール・クリックし、「検査」を選択する。

Getting the author name code in WordPress

WordPressサイトを構成するすべてのコードを表示する新しいパネルが開きます。

パネルで矢印のアイコンをクリックする。

Example of li class with author in it

投稿者名にマウスオーバーできるようになりました。

すると、右側のパネルのコードの一部がハイライトされるので、そこで投稿者コードを探します。WordPressのテーマによって異なりますが、divクラスやliクラスに「author」という文字があるか探してください。

適切なクラスが見つかったら、次のステップで必要になるので、安全な場所にメモしておくこと。

これで、カスタムCSSを使って投稿者名を非表示にする準備ができたので、コード・スニペット ” + 新規追加.

次に、コードスニペットライブラリの「カスタムコードを追加(新規スニペット)」オプションにマウスオーバーし、「スニペットを使用」ボタンをクリックします。

Adding a custom CSS snippet to WordPress

その後、カスタム・コード・スニペットのタイトルを入力します。これは参考用なので、好きなものを使ってください。

次に、「コードタイプ」のドロップダウンを開き、「CSSスニペット」を選択する。

How to hide the author using WPCode

li.meta-authorを前のステップで取得したクラスに置き換えてください:

li.meta-author {
display:none;
}

ただ、WordPressテーマの投稿者名の表示方法によっては、クラス名にli.または.divを追加する必要があることに注意してください。

コードを有効化する準備ができたら、画面を一番上までスクロールし、「Inactive」トグルをクリックして「Active」に変更します。

最後に、「スニペットを保存」をクリックするだけで、スニペットが有効になります。

Hiding the author name using custom code

これで、WordPressブログの投稿日に投稿者名が表示されなくなります。

この方法はフロントエンドで投稿者名を非表示にしますが、投稿者アーカイブページは無効化しません。

これらのページは、特定の著者が書いた投稿をすべてリストアップしたもので、通常www.example.com/author/authorname のようなURLを持っています。

An example of an author archive in WordPress

検索エンジンはこれらのページを見つけることができ、検索結果に含めることができます。そのため、All In One SEOプラグインを使って投稿者アーカイブを無効化することをお勧めします。

プラグインを有効化した後、All In One SEO ” 検索外観に行き、「アーカイブ」タブをクリックするだけです。

Hiding the author archive pages using AIOSEO

投稿者アーカイブ」の下にある「検索結果に表示」設定を見つける。

これで『いいえ』をクリックできる。

The AIOSEO SEO WordPress plugin

その後、「変更を保存」をクリックして設定を保存します。これで、投稿者アーカイブページは検索結果に表示されなくなり、これらのページへのトラフィックがなくなるはずです。

WordPressのSEOを改善する方法の詳細については、All In One SEO for WordPressを正しく設定する方法のガイドをご覧ください。

方法2:WordPressのメタ情報を編集して投稿者名を非表示にする(ブロックテーマ)

新しいブロック対応のWordPressテーマを使用している場合、どのテンプレートからも投稿者名を削除することができます。

始めるには、WordPressダッシュボードのテーマ ” エディターへ向かいます。

Opening the WordPress full-site editor (FSE)

デフォルト設定では、フルサイトエディターはテーマのホームテンプレートを表示しますが、どのテンプレートからも投稿者名を削除することができます。

左側のメニューで『テンプレート』を選択する。

Hiding the author name using the full-site editor (FSE)

編集したいテンプレートをクリックしてください。

通常、WordPressテーマによっては、インデックス、個別投稿、アーカイブのテンプレートから投稿者名を削除したい場合があります。

Editing a blog post template using the full-site editor (FSE)

テンプレートを選択すると、WordPressはそのデザインのプレビューを表示します。

投稿者名を削除するには、小さな鉛筆のアイコンをクリックします。

Customizing a block-based WordPress template

投稿日: ブロックをクリックします。

そして、キーボードの「Delete」キーを押して、このブロックをテンプレートから削除する。

Removing the author name using the WordPress full-site editor (FSE)

変更を有効にするには、「保存」ボタンをクリックしてください。これで、このページや投稿にアクセスすると、投稿者名が消えているのがわかります。

テーマによっては、WordPressサイトの他のエリアから投稿者名を削除する必要があるかもしれません。これを行うには、上記と同じ手順を踏むだけですが、今回は別のWordPressテンプレートを選択します。

方法3:投稿者名を一般的な投稿者名に置き換える(回避策)

もう一つの方法は、一般的な投稿者名を作成し、すべての投稿に使用することです。この方法では投稿者名を非表示にすることはできませんが、小規模なブログで迅速な回避策が必要な場合には良い設定かもしれません。

それはともかく、始めよう。

まず、WordPressサイトに新規投稿者を追加し、「editorialteam」などの一般的なユーザー名をつける必要があります。

Add new user

次に、Users ” All Usersページに進みます。

ここで、先ほど作成したユーザー名にマウスオーバーし、「Edit」リンクが表示されたらクリックします。

Edit user

ユーザープロフィール画面で、「ニックネーム」設定オプションまでスクロールし、「編集チーム」など、訪問者に表示したい名前を入力してください。

その後、’Display name publicly as’の隣にあるドロップダウンメニューをクリックし、先ほど入力したニックネームを選択します。

Select display name

また、一般的な経歴を追加したり、ユーザーアカウントのグラビアを作成することもできます。

アカウントの設定に問題がなければ、「更新」をクリックして変更を保存します。

さて、すでに公開したすべての投稿にこの新しい投稿者を追加する必要があります。一番簡単な方法は、投稿日 ” すべての投稿に行き、一番上の画面設定メニューをクリックすることです。

ここで、’Number of items per page…’を見つけ、投稿タイプをすべて個別画面に表示できるように大きな数字を入力する。例えば、以下の画像では’999’を使用しています。

Show all posts on screen

これで「適用」をクリックすると、WordPressはすべての投稿を個別画面に表示する。

これらの投稿をすべて一度に編集するには、初期設定では「一括操作」と表示されているドロップダウンメニューを開き、「編集」を選択します。

では、『Apply』をクリックしてください。

Select all posts for bulk editing

WordPressはこれらの投稿の一括編集オプションをすべて表示します。

投稿者」ドロップダウンを開き、作成したばかりの一般的なアカウントを選択するだけです。

Bulk change author name

この変更を実行する準備ができたら、更新ボタンをクリックしてください。WordPressはすべての投稿を更新し、新しい投稿者名を表示します。

WordPressの投稿から投稿者名を削除する方法について、この投稿がお役に立てれば幸いです。また、オンラインでブログを書いてお金を稼ぐ方法についてのガイド、またはドラッグ&ドロップでWordPressページビルダーを選ぶ方法についてもご覧ください。

If you liked this article, then please subscribe to our YouTube Channel for WordPress video tutorials. You can also find us on Twitter and Facebook.

情報開示 私たちのコンテンツは読者支援型です。これは、あなたが私たちのリンクの一部をクリックした場合、私たちはコミッションを得ることができることを意味します。 WPBeginnerの資金源 をご覧ください。3$編集プロセスをご覧ください。

Avatar

Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.

究極のWordPressツールキット

ツールキットへの無料アクセス - すべてのプロフェッショナルが持つべきWordPress関連製品とリソースのコレクション!

Reader Interactions

36件のコメント返信を残す

  1. Syed Balkhi says

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. Jiří Vaněk says

    I have a blog as a sole author and on my own domain. That’s why I thought it was unnecessary to display the author’s name. I used your procedure with the CSS code and it works perfectly. Thanks, you saved me another plugin space. This solution works perfectly with minimal demands on the website’s performance.

  3. Jay says

    We went with method #2 … perfect. However, do you know if there is a way to remove the other names from the author select dropdown list when editing or adding a post. We want only our genergic author to be listed as an option. Thanks!

    • WPBeginner Support says

      We do not have a recommended method for forcing the author to be assigned at the moment.

      管理者

  4. Chris says

    Wouldn’t copying and pasting the folder and file into your child theme, and then deleting or commenting out this snippet, be the best solution?

    Versus recommending editing the parent theme files directly.

    • WPBeginner Support says

      If possible, that would be a good option but not all themes can be easily added into a child theme like that without issues.

      管理者

  5. Mark Toney says

    I took all the steps outlined – but when I got to the BULK edit – it would not show the new name of Editorial Team in the dropdown. I logged out and back in again and it still does not allow that name. Any ideas on why or a fix?

    • WPBeginner Support says

      You would want to check the role permissions for the user you created that they would be able to have posts on your site for a likely culprit

      管理者

  6. daveF says

    One thing to be aware of with the second method – when you bulk update the posts with the new ‘author’, the “last updated’ date is changed to the current date. If your theme displays the “last updated” metadata, it will appear that all your post happened on the same day. I did this on a church blog that was only a week old and had only a few posts, so it was not a big deal. If you have hundreds of existing posts over a long period of time, it might be a big deal to you. I wish that had been pointed out in the article. It makes perfect sense in retrospect, but I didn’t think about it until the deed was done. Maybe this comment will help someone else contemplating making this change.

    • WPBeginner Support says

      Thank you for sharing this, we’ll look into clarifying that in the future with this article :)

      管理者

  7. praveen says

    How to change a label name in a wordpress theme? For example am working on a education theme , and on the top of the course the author label is show as “Teacher”. I want to change the label as “Instructor”. Please help.

    • WPBeginner Support says

      It would depend on what added that label. If it was added by your theme you would need to reach out to the theme’s support for example

      管理者

    • WPBeginner Support says

      Not always, hiding the text with CSS means it’s not visible to most users but site crawlers can still find the author name

      管理者

  8. Angelo says

    I’ve been able to edit the author url from the homepage to the author page by going to seo by yoast under “search appearance”. Thank you God bless you!

    • WPBeginner Support says

      That would only hide the name until someone inspected the page at which point the name would be simple to find :)

      管理者

  9. Glen Appleton says

    And then there’s the CSS method, which you covered partially in the first (plugin) method. Use the same element inspector to find the CSS class (byline in Twenty Seventeen theme), and use the CSS selector to set the display to “none”. For example:

    article.type-post .byline {
    display: none;
    }

    NOTE: This only removes it from the rendered page, and not the page source. You should create a separate editor account for posting articles on your site, and make sure that account doesn’t have admin privileges.

    Hope this helps.

  10. joe says

    just another security flaw in outdated wordpress. every post shows my login admin name. why someone wont update wordpress to fix the known issues hackers use to hack it just boggles my mind.

  11. Ireneusz says

    Hi,

    I used Show Hide Author plugin, but not working. I removed author, but left “by”. I cannot remove “by” in theme FitWP in posts. There’s no class “byline” in code.

    I try put by in field Regular expressions, but not working.

    Please help me.

    • Kevin says

      You can try method 1 and use this code instead, that worked for me :-)

      Code:
      .single-post .author.vcard {
      display: none;
      }

返信を残す

コメントありがとうございます。すべてのコメントは私たちのコメントポリシーに従ってモデレートされ、あなたのメールアドレスが公開されることはありませんのでご留意ください。名前欄にキーワードを使用しないでください。個人的で有意義な会話をしましょう。