Post Type Builder (PTB) has been a great tool for non-coders to add custom post types without writing any code. It allows users to build custom advanced sites such as property listing, movie reviews, classified listing, user submission sites, etc. Today we are excited to announce a major update of PTB v2. The new version has added many new features and improvements. It has been improved with better compatibility between the addons and third-party themes/plugins, especially Builder Pro. You can use PTB to add custom post types, taxonomies, and custom fields; then use Builder Pro to design the templates and display the custom fields using the dynamic content feature. This new version is much better than before. We highly recommend you try the update on a staging site before rolling to the live site as it is a major update. If you've built something cool with PTB, please submit it to our showcase or comment in this post. We are planning to feature some user sites created with PTB.
New PTB Demos
We've built a new PTB demo. The new demo consists of 3 sample post types: Property, Movie and Restaurant. You can import them at WP-Admin > Post Type Builder > Import/Export along with the demo posts.
Multiple Archive Templates
The old PTB was limited to only one archive template. Now you can create additional PTB archive templates which you can display them using the [ptb] shortcode. This new feature is extremely useful if you want to display different archive post layouts on different pages.
Once the additional PTB archive templates are created, you can select them on the [ptb] shortcode generator (requires Classic Editor for the shortcode generator) or write the 'template' attribute manually like the sample below.
[ptb type="property" template="Property Archive2" orderby="date" order="desc" masonry="0" posts_per_page="10" style="grid3" logic="or"]
Add Custom Fields to Other Post Types
With PTB v2, you can add custom fields to any post type including other custom post types registered by third-party plugins. For example, you can add extra custom fields such as product measurements, materials, etc. on WooCommerce product post type.
After the custom fields are added to third-party post types, you can use Builder Pro to create templates to display them. You can also display the custom fields with the Advanced Products module's dynamic content feature.
Generate PHP
If you are a developer and need to export the post types to a child theme or plugin, you can use the Generate PHP feature to export the code. To export the post-type registration code, go to WP-admin > Post Type Builder > Import/Export. Once you exported the code, you can paste them into your child theme functions.php or as a plugin. This feature is strictly for developers with coding knowledge. If you are not a coder, you should use the PTB import/export tool instead.
PTB Field Shortcode
The [ptb_field] is a new shortcode that allows you to display the custom field value in the post. To display the custom field value, write the shortcode [ptb_field] and the name of the custom field. Note that the ptb_field shortcode must be inserted in the post loop to be displayed (ie. the shortcode must be present in the content where the post has the custom field value).
[ptb_field name="field_name"]
You can also use the shortcode generator to create the shortcode. On the WordPress Classic Editor, click "PTB Field", select the post type and then the field name.
Important Changes
- Extra Fields Merged in PTB
- The PTB Extra Fields addon has been merged into the core PTB. Now you don't need to install it as a separate addon.
- Icon Font Removed
- To improve performance, PTB no longer loads the entire icon font. The icons are loaded as individual SVG icons. If you have custom CSS that uses the icon font, it will no longer work. We can help you fix this if you need assistance, please post on our support forum.
- PTB Search
- PTB search result page now requires the [ptb-search-results] and/or the [ptb] shortcode to render the search results. They are like the placeholder where you want to display the search results. Refer to PTB Search documentation for more info.
Fernando
March 2, 2023 @ 4:17 pm
Amazing, especially the “PTB Field Shortcode.” I’ve been waiting for this for a long time.
One feature request: the ability to add a dynamic color field.
Jonathan Rhein
March 7, 2023 @ 10:18 am
Yes the color field would be great! I agree :-)
Nick
March 2, 2023 @ 4:20 pm
The Post Type Builder plugin is the reason I started using Themify more than 5 years ago. Now I have built 10+ websites with PTB and I’ve already had the chance to work with PTB2. The improvements are fantastic! I love how I can now use multiple archive templates per post type.
Thanks guys!
Robin Hollington
March 2, 2023 @ 4:29 pm
Does this work with variable products (and any other sort)?
Nick @ Themify
March 6, 2023 @ 10:03 pm
Yes, you can add custom fields to WooCommerce variable products and use Builder Pro to design the templates for WooCommerce products.
makis
March 2, 2023 @ 5:44 pm
Great news.
I want to know about PTB price and addons.
Nick @ Themify
March 6, 2023 @ 10:02 pm
You can find them here: https://themify.me/post-type-builder
notjustcode
March 3, 2023 @ 10:22 am
This is brilliant.
Having multiple archive templates makes a very powerful feature even more powerful.
Please do the same for the the PTB-Relation plugin so that we can create multiple templates per relation. At the moment we can only create one relation-template, it would be very useful to be able to create multiple templates.
Jörg Spieler
March 4, 2023 @ 5:08 pm
The update has broken all my Post types because auto-update was enabled. It is saturday evening and i’m repairing all the customer sites with PTB
Nick @ Themify
March 6, 2023 @ 7:47 pm
Sorry to hear about your experience. Updating PTB shouldn’t affect the post types. Could you send us an email or post on the support forum (include your site URL and details of the issue please).
Cristián Uribe
March 4, 2023 @ 8:37 pm
The search results stopped working after the update. This is time consuming and frustrating.
Nick @ Themify
March 6, 2023 @ 7:46 pm
We can look into this. Please send us an email or post on the support forum (include your site URL and details of the issue please).
Marcelo Lazarte
March 6, 2023 @ 3:39 pm
Hello the “search shortcode” has been working for a long time, what is the update, what is new?
Please, what we need is that a custom template (Advanced Posts) can be applied to the results for the “search forms”.
Many thanks for the constant work
Marcelo Lazarte
March 6, 2023 @ 3:41 pm
Please, another thing that would be great to have updated, is the documentation of functions such as: Dynamic Query
Alex Caravaca
March 8, 2023 @ 4:48 pm
It’s good news that you can add custom fields to other types of posts and be able to do without other plugins
thank you!
Atis
March 13, 2023 @ 10:56 am
Is it possible to load posts from CSV?
judyhicks
March 15, 2023 @ 8:29 pm
I have PTB Bundle (expires Sep 21, 2023). If this doesn’t automatically upgrade to v2, what is the cost?
Nick @ Themify
March 16, 2023 @ 9:14 pm
It doesn’t automatically renew your membership. You would need to renew your PTB membership by purchasing another year: https://themify.me/post-type-builder
James Emetu
May 13, 2023 @ 12:32 am
Wow awesome! this certainly helps speed up the process of creating post types without coding newbies are going to love this
Reptus
June 8, 2023 @ 8:34 am
Fantastic Update. Kudos to Themify Team.
We are using Themify Themes for more than 20+ websites for our clients. We love Themify Themes because ease of usage, and simplicity.
Peter
March 3, 2024 @ 3:27 pm
Is it possible for you to add attribute facilities to PTB Field Shortcode which make it possible to alter the appearance of the displayed field. Such as “Color”, “Font-size”, “Date-Format”, e.a.
Nick @ Themify
March 4, 2024 @ 2:39 am
The PTB shortcode doesn’t have styling attributes. For styling, it is better to use CSS. Is there a specific task that you want to achieve? How can we help you?