Creating Testimonials Layout with CPT and Beaver Builder

In this article I am showing how you will dynamically display the custom post types content in page builder. I created a custom post type “Testimonials” and some custom fields like name, photo, testimonial with Advanced Custom Fields plugin. Later I created a Testimonials page with Beaver Builder and displayed the testimonials. Here is my testimonials page:

Testimonials Layout


I am using the following tools:

  1. Beaver Builder Plugin (paid version)
  2. Advanced Custom Fields plugin

I did pretty simple things and choose the testimonials page. But I am trying to show you how you will interact the custom post type’s content and custom fields data with Beaver Builder page layout without Beaver Themer add-on.

I am sharing the full steps at below.

Creating Testimonials Post Type

I am using manual code. But you can use any free tools for it. There have lot of free tools in WordPress plugin’s repo. So you can easily make the custom post type from Dashboard (without code). Open the functions.php file of your active theme and add this PHP snippets there. I used the register_post_type action.

 * CPT: Testimonials
add_action( 'init', 'probb_register_cpt_testimonials' );
function probb_register_cpt_testimonials()
	$args = array(
		'public'            => true,
		'labels'            => array(
			'name'               => _x( 'Testimonials', 'Custom post type label.', 'fl-builder' ),
			'singular_name'      => _x( 'Testimonial', 'Custom post type label.', 'fl-builder' ),
			'menu_name'          => _x( 'Testimonials', 'Custom post type label.', 'fl-builder' ),
			'name_admin_bar'     => _x( 'Testimonial', 'Custom post type label.', 'fl-builder' ),
			'add_new'            => _x( 'Add New', 'Custom post type label.', 'fl-builder' ),
			'add_new_item'       => _x( 'Add New', 'Custom post type label.', 'fl-builder' ),
			'new_item'           => _x( 'New', 'Custom post type label.', 'fl-builder' ),
			'edit_item'          => _x( 'Edit', 'Custom post type label.', 'fl-builder' ),
			'view_item'          => _x( 'View', 'Custom post type label.', 'fl-builder' ),
			'all_items'          => _x( 'All', 'Custom post type label.', 'fl-builder' ),
			'search_items'       => _x( 'Search', 'Custom post type label.', 'fl-builder' ),
			'parent_item_colon'  => _x( 'Parent:', 'Custom post type label.', 'fl-builder' ),
			'not_found'          => _x( 'Nothing found.', 'Custom post type label.', 'fl-builder' ),
			'not_found_in_trash' => _x( 'Nothing found in Trash.', 'Custom post type label.', 'fl-builder' ),
		'supports'          => array(
		'menu_icon'		=> 'dashicons-id',
		'menu_position'		=> 34,
		'publicly_queryable' 	=> true,
		'exclude_from_search'	=> true,

	register_post_type( "testimonials", $args );

After adding the code you will get new menu “Testimonials” at left side panel in your dashboard.

Creating Custom Fields

Creating the following custom fields: name, photo, position and testimonial. I used the Advanced Custom Fields plugin. If you have not pro version,  download the free version from WordPress repository and install it on your site. Now navigate to dashboard->custom fields->add new and add the fields like attached image.

Custom Fields for Testimonials

Rest of the contents are only available to members. You must subscribe the MEMBERSHIP plan. You already subscribe the plan? Login at below.


Creating the Testimonials Page

See the video:

Leave a Comment

You must be logged in to post a comment.


Get free weekly PRO Beaver Builder Tutorials