WordPress.org

Ready to get started?Download WordPress

Forums

Custom Post Type UI
[resolved] Custom Post Types & Pages (3 posts)

  1. sarahn
    Member
    Posted 2 years ago #

    I have a page called "Press Releases" whose parent is "Press". So the URL structure is this:
    http://www.mydomain.com/press/press-releases

    I used the plugin to create a new post type called "Press Releases". The goal is that I want to have a list of press releases on the "Press Releases" page.

    However, after posting the first Press Release, the URL is this:
    http://www.mydomain.com/press releases/this-is-the-post-url

    My question is this:
    Can I associated the posts with in the post type "Press Relases" to my existing page structure of "Press" > "Press Releases"

    Please let me know if you need more information to clarify this!!

    http://wordpress.org/extend/plugins/custom-post-type-ui/

  2. Brad Williams
    Member
    Plugin Author

    Posted 2 years ago #

    You could make a page template for the Press Releases page that displays all posts in the Press Releases CPT.

    $query = new WP_Query( array( 'post_type' => 'cpt_press_releases' ) );

    Check out http://codex.wordpress.org/Class_Reference/WP_Query

  3. Daedalon
    Member
    Posted 2 years ago #

    You may also try a plugin designed for this. Eg. Custom Post Type Archives, Simple Custom Post Type Archives or Custom Post Type List Shortcode, which mentions specifically supporting Custom Post Type UI.

Topic Closed

This topic has been closed to new replies.