Code

Discussion on Templatera - Template Manager for WPBakery Page Builder

Discussion on Templatera - Template Manager for WPBakery Page Builder

Cart 11,552 sales

wpbakery supports this item

Supported

This author's response time can be up to 1 business day.

614 comments found.

Is it possible that there are some compatibility issues with Templatera and wpbakery 7.6? The design options > css box settings are not taken to the page where the template is located. If I turn back to 7.5 it is ok again.

Hello, Yes, this issue has been identified as a bug and it is on our bug fix list.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

erapop

erapop Purchased

Hi Rohan and the WPBakery Team,

I’ve modified the function outputShortcode in the file vc_template_manager.php so that post/page specific shortcodes now show the correct content based on the post or page id rather than the templates id. I’ve tested it with WPBakery shortcodes (Custom Headings, Single Image set to featured, and several post grids) and found no conflicts.

Here is the updatred outputShortcode function that allows page/post specific shortcode content to work in Templatera templates:

//revised outputShortcode

public function outputShortcode($atts, $content = ’’) { $id = ’’; $el_class = ’’; $output = ’’; extract(shortcode_atts(array( ‘el_class’ => ’’, ‘id’ => ’’, ), $atts)); if (empty($id)) { return $output; } $my_query = new WP_Query(array( ‘post_type’ => self::postType(), ‘p’ => (int)$id, )); WPBMap::addAllMappedShortcodes(); global $post; $backup = $post; while ($my_query->have_posts()) { $my_query->the_post(); if (get_the_ID() === (int)$id) { $output .= ‘ ’; ob_start(); visual_composer()->addFrontCss(); $content = get_the_content(); }

// Modify the content only if we're within vc_column shortcodes
        $content = preg_replace_callback('/(\[vc_column[^\]]\])(.?)(\[\/vc_column\])/s',
            function($matches) {
                global $wp_query, $post;
                $original_post = $post; // Save the original global post object
}
$post_id = $wp_query->post->ID; // the ID of the current post
            $post = get_post($post_id); // Set the global post object to the current post
            setup_postdata($post); // Setup post data for template tags
}
wp_reset_postdata();
$column_content = do_shortcode($matches[2]); // Process the content within the current post context
);
$post = $original_post; // Restore the original post object
    setup_postdata($original_post); // Setup postdata for original post
},
$content
return $matches[1] . $column_content . $matches[3]; // Return the modified content
print $content;
$output .= ob_get_clean();
$output .= ' ';
$output = do_shortcode($output);
$post = $backup;
wp_enqueue_style('templatera_inline', $this->assetUrl('css/front_style.css'), false, '2.1');
return $output;

Hi, Thanks for sharing. I will add it onto our list so that it can be tested further.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hi, are there any plans to update the plugin soon?

Hello, The plugin will be updated as soon as any bug is identified within it. At present there is no bug with it’s functionality and compatibility with latest WordPress or WPBakery Page Builder plugin.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Can a templatera template be used to display in a sidebar widget? Looking at the comments you referred to a third party plugin that no longer exists. Surely there is a way to use a template in a Wordpress widget?

Hello, The templatera itself does not have a widget that can be used in widget area such as sidebar. It might be possible to achieve this by adding template shortcode from templatera in the widget. However, the page where the widget area is displayed needs to use WPBakery Page Builder.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

First of all I want to apologize because I have no idea how to recreate the issue.

But I’ve seen it happen on a few sites before where the Templatera icon was missing even though the plugin was installed and you could add templates under WPB > Templatera, but the icon for inserting templates wouldn’t show up anywhere.

To fix, I had to go to WPB > Role Manager and I had to change the Administrators “Post types” setting from “Pages Only” to “Custom” and then select the post types and save. This fixes the issue and then switching back to “Pages Only” the issue remained fixed.

As an Adminstrator it seems like you should always have permissions for everything, so I’m not quite sure why the settings even exist.

Not sure if you’ve experience the issue before or how you would go about trouble-shooting it. But maybe if there was a “reset roles” button on the admin page that cleared everything back to a fresh install it would be very handy for troubleshooting, especially if it can also validate the admin roles on reset to ensure they are working otherwise spit out a warning.

Thank you for your time and consideration!

- AJ

Hello, The issue is quite strange. We have not encountered it. Please drop us a message via profile contact form if you come across it again, so that the support team can check it further.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hello. Is this plugin actively maintained? I noticed that it hasn’t been updated since the 14th of October 2022 (almost a year ago)

Hello, Yes, the plugin is actively maintained and supported. We release updates when any bugs are identified.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hello,

I have a pre-sale question.

After creating a re-usable component(block) or vc template. Is it possible to use this block on different pages with different content?

Thanks

Hello, Yes, the template that is created can be added to different pages using the templatera element.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

I think you misunderstood my question, do I mean that the content of the element can be changed on any page or can it only be changed from the templatera element?

Thanks

Hello, The content of template can either be locked by adding it via templatera element in which case it will reflect the changes made to the original template onto the pages where it is added, or it can be edited on the page in which case it will not reflect the changes that are made to original template.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hello, I bought the plugin but actually I cannot reflect the template changes on the other page / post or portfolio items. A few days ago I wrote a message on your support about this problem, but there seems to be no one to answer it. Could someone help me? Thanks!

Hello, Apologies for the delay in responding due to weekend. Please make sure that the template is added using templatera element. This will lock the template content and hence will reflect the changes made to it.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Looks like the plugin is loading a front_style.css file always, but the only code in there is code needed for the front-end editor:

body.compose-mode .vc-templatera .templatera_shortcode,
body.compose-mode .vc_templatera .templatera_shortcode {
    opacity: 0.5;
    filter: alpha(opacity=50);
}

Perhaps the script should only be loaded only if vc_is_inline() returns true to prevent unneeded scripts on the live site ;)

Also opacity works in all modern browsers (for a long time now), no need for the added filter property – https://caniuse.com/?search=opacity

- AJ

Hello, I have added these onto our list so that they can be checked in the future release.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

I bought the templatera version but now it tells me that it is not compatible with the version of BACKERY that my website has. I have version 6.2.0. Is there a solution or previous version of the compatible plugin?

Hello, The 6.2 is a very old version of WPBakery Page Builder. We would recommend updating it to the latest version which is 6.10.0 to avoid any bugs and security issues.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hello Team,

Pre-Purchase Query

I want to purchase this plugin can you please share the demo URL and Demo plugin, also is this plugin work on the bridge theme?

Best

Hello, Unfortunately we do not have a demo available for the plugin. However, we do have a 15 days refund tenure and can refund the purchase if you are not happy with it. The plugin works fine with any theme which is coded as per the WordPress theme development guidelines.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hi, pre sale question: is it possible to create a template and use it via PHP code as a shortcode (with the do_shortcode() function)? Thanks

Hello, Yes, the template shortcode can be rendered via do_shortcode.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hey

Templatera plugin is not compatible with Ultimate Addons plugin. For example, if we want to place template by do_shortcode [templatera id = “CUSTOM_ID”] in custom single post in source code, we get only html without working css and js libraries.

Here is workaround, you must put code manualy in functions.php and modify it dependent on Ultimate Addons modules used in custom page source code.

For example I used Content box and Info box modules, so here is ready code (for functions.php) for that worked in custom single post:

function add_custom_css_js(){
    // check if post is single and load libraries only here
    if( is_single() && get_post_type()=='post' ){
    // loading css files from Ultimate Addons modules
    wp_enqueue_style( 'ultimate-vc-addons-style', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-css/style.min.css');
    wp_enqueue_style( 'ultimate-vc-addons_content_box_css', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/assets/min-css/style.min.css');
    wp_enqueue_style( 'ultimate-vc-addons-animate', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-css/animate.min.css');
    wp_enqueue_style( 'ultimate-vc-addons-info-box-style', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-css/info-box.min.css');
    // loading js files from Ultimate Addons modules
    wp_enqueue_script( 'ultimate-vc-addons-params', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-js/ultimate-params.min.js', array(), '', true );
    wp_enqueue_script( 'ultimate-vc-addons-appear', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-js/jquery-appear.min.js', array(), '', true );
    wp_enqueue_script( 'ultimate-vc-addons-custom', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-js/custom.min.js', array(), '', true );
    wp_enqueue_script( 'ultimate-vc-addons_content_box_js', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-js/content-box.min.js', array(), '', true );
    wp_enqueue_script( 'ultimate-vc-addons-info_box_js', plugin_dir_url('') . 'Ultimate_VC_Addons/assets/min-js/info-box.min.js', array(), '', true );
    }
}
add_action('wp_enqueue_scripts', 'add_custom_css_js');

Hello. Ultimate Addons support helped me to solve the problem.You need to go to the debug mode plugin options (Ultimate Addons) and switch on “load scripts globally”. After that all is work correctly.

Release Notes and Changlog for both Templatera and WP Bakery have not been updated, can you please get those updated so that we may see what has been changed prior to updating? Thanks.

Hello, The changelog of WPBakery Page Builder is as follows:
Changelog: 
13.10.2022 - ver 6.10.0 3
• New: Option to use Google Fonts locally - used fonts will be downloaded to comply with the GDPR policies
• Compatibility: Compatibility for WooCommerce Tab Manager
• Update: Pie chart legend positions improved
• Update: Translations updated
• Fix: Full-width logic for rows is working properly
• Fix: Frontend editor does not contain unneeded notices
• Fix: Controls work properly in the Frontend editor
• Fix: WooCommerce Post Grid works properly with translate keys
• Fix: Flexslider overflow in the image gallery works properly
• Fix: Round chard legend position works properly
• Fix: WooCommerce Shop page CSS works properly
• Fix: Unused CSS prefixes removed
• Fix: addPageCustomCss and custom ID work properly
• Fix: Custom accent colors work properly in the Separator with Text
• Fix: Youtube Video background autoplay works properly
• Fix: License check logic works properly
• Fix: Edit form loading for async scripts
• Fix: Warning on the removed default template
• Fix: Automapper removing elements work properly
• Fix: get_the_excerpt filter arguments support WordPress 5.5
• Fix: Admin access in multisite works properly
• Fix: Edit-form initialization works properly
For templatera:
 - Update: Template rendering scope now is rendered page scope
  - Fix: Advanced Custom Fields now is properly displayed on the page

This will be updated soon.

Hey,

This is a suggestion for the dev team since I don’t have access to the Github repo to suggest a pull request…

Currently the templatera shortcode creates a new WP_Query when rendering the shortcode which can cause issues if you have any elements inside the template that reference the global post. For example if you have a custom field shortcode inside templatera it’s going to try and get the custom field of the template and not the current post.

There is also no need for a new WP_Query to render a template. I would recommend modifying the shortcode to instead use something more simple like this:

extract( shortcode_atts( array(
    'el_class' => '',
    'id' => '',
), $atts ) );
if ( empty( $id ) || 'templatera' !== get_post_type( $id ) ) {
    return $output;
}
$content = get_post_field( 'post_content', $id );
if ( ! $content ) {
    return;
}
$output = '';
ob_start();
    visual_composer()->addPageCustomCss( $id );
    visual_composer()->addShortcodesCustomCss( $id );
$output .= ob_get_clean();
$output .= do_shortcode( $content );
return $output;

Which won’t pollute the global $post it’s also much cleaner and simpler ;)

Thanks!!

- AJ

Hi, Thanks for sharing. I have added this onto our backlog so that it can be checked further during an update.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Great idea for a plugin, shame it does not work with “Ultimate Addons for WPBakery Page Builder” properly.

Mainly the “Headings” shordcode when set to use page or post title. It still displays template name on pages using the template.

Hello, We are not exactly sure of how the headings work as it is a custom element of the addon. However, to display post-related data the element code will have to be modified to check for posts instead of template in which it is added.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

I create 2 tickets or the same issue since 22/0708 : no solution. Or the plug bug, or you’re on holidays. Im working, I buy and renew my support, I expect to work as template promise. Thank you to solve ticket #122415 as expected > thank you

Hello, Apologies for the delayed response due to the weekend. The previously shared password within the ticket did not work. However we were able to login using the new one shared by you and have responded to the ticket.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hello, I’m interested in buying this plugin. Is development still alive? I can see last update was in April 2020. Is it compatible with latest versions of WP?

Hello, The plugin actively maintained and supported. The last updated was released in Dec 2021: https://i.imgur.com/hmPQILR.png It is compatible with recent WordPress.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Any news on ACF field being automatically inserted into templatera when used on custom post type etc.?

I can see multiple people suggested this, and also, some guy posted a change to the plugin so we could use [post_title id=”#templatera_calling_post_id#’]

Is this possible now, since it is over 6 years ago, this feature was requested?

Hello, Unfortunately this feature was not implemented in past. It was recently requested by a few users and we have it on our list to check it’s implementation in the future release.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Hi Rohan.

Thanks for the reply – damn it. I was hoping that this was already implemented. I have been in contact with ACF, that provided me with a script for checking ID, and templatera is not passing that ID through.

Would there be any chance for a custom solution or, that the template are also providing post-id ?

For exampe a post ID is 8880 and templatera is 10790. If 8880 could be provided, ACF would work out of the box?

This is really something that we need for maintaining our website. Please do let me know, if this can be achieved or when it will be achieved. We are also (as a company) in a position, where we can dedicate time/money for a developer (maybe for supporting you on building this feature) ?

Hello, This might be possible with some customization but it will be a complex implementation. The logic will be to parse the ACF shortcode before rendering and then pass the post id instead of template id to it. You can check enavto studio as developers there might be able to customise it. Please do make sure to re-confirm it with them before hiring anyone.



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

Do I need a full iicense (not just a theme-based license) to use Templateria? I purchased Templatera stand-alone as I have a theme-based WP Bakery license but I can’t see the Templatera add new template option and I don’t see any license registation options for Templetera? Will it only function with a full/regular license of WP Bakery Page builder? Thanks

I think I have solved my issue. It appears that the Templatera templates reside within the Templates menu, a little confusing as I thought they operated independently. It they are added a general page template then they can be modified, but if the same template is added using the Templatera function within a page then it keeps the parent settings?

It would be good if there was a bit more documentation available within the plugin package or via your website for new users.

The video link on your CodeCanyon page is broken searching via Youtube brings up a video from 2018 however it looks like some of the menu functions have changed with makes it less clear.

Thanks

Hello, If the template is added via templatera element, it’s content is locked and it will reflect any changes made to the original template onto the page where it is added. We have a documentation for templatera which can be accessed here: https://kb.wpbakery.com/docs/add-ons/templatera/



Knowledge Base · Official Support · Facebook · Twitter

Don’t forget to join our newsletter. Be first to get news and inside secrets from WPBakery team.

by
by
by
by
by
by

Tell us what you think!

We'd like to ask you a few questions to help improve CodeCanyon.

Sure, take me to the survey