フォーラムへの返信
-
投稿者投稿
-
ありがとうございます!
修正を確認できました。♥ 0Who liked: No user>WordPress はデフォルトではカスタム投稿タイプの日付アーカイブページはサポートされていなかったと思います。
そうだったのですね!知らなかったです。
ありがとうございます。対応していただかなくても大丈夫ですが、今後他の方でも同じことがあったときのためのどのように作ったか記載いたします。
カスタム投稿の作り方
Custom Post Type UIプラグインで以下の設定にしました。
{“scrap_hub”:{“name”:”scrap_hub”,”label”:”\u5ec3\u6750HUB”,”singular_label”:”\u5ec3\u6750HUB”,”description”:””,”public”:”true”,”publicly_queryable”:”true”,”show_ui”:”true”,”show_in_nav_menus”:”true”,”delete_with_user”:”false”,”show_in_rest”:”true”,”rest_base”:””,”rest_controller_class”:””,”has_archive”:”true”,”has_archive_string”:””,”exclude_from_search”:”false”,”capability_type”:”post”,”hierarchical”:”false”,”rewrite”:”true”,”rewrite_slug”:””,”rewrite_withfront”:”false”,”query_var”:”true”,”query_var_slug”:””,”menu_position”:””,”show_in_menu”:”true”,”show_in_menu_string”:””,”menu_icon”:”dashicons-admin-tools”,”supports”:[“title”,”editor”,”thumbnail”,”author”],”taxonomies”:[],”labels”:{“menu_name”:””,”all_items”:””,”add_new”:””,”add_new_item”:””,”edit_item”:””,”new_item”:””,”view_item”:””,”view_items”:””,”search_items”:””,”not_found”:””,”not_found_in_trash”:””,”parent_item_colon”:””,”featured_image”:””,”set_featured_image”:””,”remove_featured_image”:””,”use_featured_image”:””,”archives”:””,”insert_into_item”:””,”uploaded_to_this_item”:””,”filter_items_list”:””,”items_list_navigation”:””,”items_list”:””,”attributes”:””,”name_admin_bar”:””,”item_published”:””,”item_published_privately”:””,”item_reverted_to_draft”:””,”item_scheduled”:””,”item_updated”:””},”custom_supports”:””}}
パーマリンクの変更
Custom Post Type Permalinksプラグインで
/%post_id%/
を設定し、「カスタマイズされたカスタムタクソノミーのパーマリンクを使用する。」にチェックしています。
サイドバーに月別アーカイブウィジットの表示
Custom Post Type Widgetsプラグインを使用しています。
パーマリンクが「ドメイン/scrap_hub/date/scrap_hub/2019/11/」になってしまったので、後ろの方の「scrap_hub/」を削除してアクセスした状態です。よろしくお願いいたします。
♥ 0Who liked: No user -
投稿者投稿