You should register the post type from the old theme, all the posts are still there in the database WordPress just doesn’t know to look for them.
Use the register_post_type
with the same slug/post type name, and your old portfolio posts will reappear, no need to detach and re-attach to new pages
Related Posts:
- Creating a metabox to upload multiple images, Ignoring The Featured Image
- How to Removing fields from the Media Uploader/Gallery on a Custom Post Type Edit Page
- Duplicate Custom Header Functionality into the post edit screen
- Media library – Limit images to custom post type
- Correct Post Count ( All | Published | Drafts | Pending | Trash ) for Custom Post Type when restricting to view own posts
- How to hide CPT files from media library programmatically
- Add metabox with media uploader in a custom post type [duplicate]
- How do I add media to a custom post type?
- How to make a page template to list all galleries?
- Too much recursion error when chosing image from image library for two different meta boxes in one post
- Using Default WordPress Custom Header Image Crop Feature in a Post Type / MetaBox
- Image size filtering in Media uploader according to custom post type
- Should I use custom post types for a front page video feature (vimeo)?
- How do I organize photos for multiple galleries?
- Delete all associated media when custom post type removed
- Remove fields on media uploader for custom page type – not working for “From Computer” or “From Url” tabs?
- Force documents to appear in Featured Image dialogue
- how to get URL of media uploaded to WordPress via media_handle_sideload()
- uploading images to specified directories
- WordPress 3.5 Media Uploader – Only allow 1 upload and certain file types
- Hide editor while keeping add media button in custom post type
- File sharing platform for user contributions? [closed]
- Cannot upload featured image to a custom post type
- Custom Attachment Type
- Insert into post button missing on custom post type
- Save data is post using php front end
- Attaching more than 1 parent (Post) to a media file
- Help Adding filter to Add Media button for custom post type
- Cant move file after media_handle_upload
- Custom post type media upload error with custom user role
- Custom post type Featured Image popup not working
- upload image with rest API to the media library
- Media Library empty or only 1 item when invoked from custom post type set featured image button
- How to add a post page from a button without reloading
- How to add a custom post type in child theme? (WordPress > 3.0)
- Query Posts From Multiple Post Types
- Displaying wp post categories into my custom metabox
- Permalink Trouble with Custom Post Type
- Add auto increment value to custom meta
- category_name not working in WP_Query
- Custom post type submenu sorted by specific meta_key & meta_value
- Custom Post Type Rewrite Rule
- Thumbnails for custom post not showing up in query
- custom post type for custom talbe
- custom post types, pre_get_posts, wp_list_categories
- Post being scheduled that shouldnt be schedulded
- Custom post types working in functions.php but not in plugin
- custom_post_type with umlaut in name
- WordPress nested loop not working
- Custom Post Type Permalinks Problem
- How to internationalize the sub menu name “categories” in Custom post type?
- Change column of row action (Quick Edit) links in WP_List_Table
- How can I retrieve the slug for a custom post type via name?
- Order by custom field attribute
- paging is not working properly on news archives page [duplicate]
- Custom Post Type Author Array Problem
- Pop up showing same content on all posts display.
- Updating User Meta from Custom Post Field Upon Publish Not Working
- Show list of categories in post editor only from current custom post type
- Front end Submit not posting to Custom Post type
- Collection of fields in a single post
- Display and Allow users to edit their own profiles
- Yearly Archive from a custom date metabox (Event Start Date)
- Problems with custom post type and hierarchical permalinks
- WordPress Custom Permalink Structure with Custom Post Type and Taxonomies
- Get result from Custom Field in Custom Post type
- Custom options for a Custom post type
- Need to build custom metabox select prev posts by category
- Issue on Adding Taxonomy to Custom Post Type Using Function
- Add Excerpt On Quicksand Plugin
- Tags results not displaying for post types
- Remove space when post title is blank
- How can I add a Description column to the media library browser screen?
- Author profile comments system
- Rewrite Rule & Regex – Extract ‘cat-name’ and ‘page-number’ from http://domain.com/custom-post-type/category/cat-name/page/page-number
- Can’t open Custom Post Types Link in navigation
- Show custom taxonomies in admin panel under custom post type
- Custom post type child of custom post type
- Problem querying new custom post type while old display fine
- Remove custom taxonomy ‘post-type’ from post URL
- Using pagination with specific custom post type [duplicate]
- delete custom post type using a submit form
- List a custom taxonomy’s terms, with links, on the taxonomy page
- Modifying and Displaying URL’s in a Post Template using parse_url
- How to get child taxonomies
- Custom Post Types in plugins?
- WordPress multi-query not returning as expected
- Trying to combine multiple WordPress queries
- Change Taxonomy Permalinks
- using post_type with meta_query
- wp_get_archives(); Change output of link
- Display Custom Taxonomy of custom post type
- Display Custom Post Type in Custom Taxonomy URL
- adding a shortcode into a custom post type
- WP Query Post Type with same Taxonomy name
- WP Query WordPress Post Type with the same Taxonomy name
- Return only custom post types for the page, not all
- Custom Post within a custom post
- Post_per_page -1 returns only half the results
- CPT Template Not Showing – Getting 404