Digital experiences for all disciplines
New Landing › How can we help? › Cardinal › Page templates
New Landing › How can we help? › Cardinal › Page templates
- This topic has 25 replies, 2 voices, and was last updated 8 years by David Martin – Support.
-
Posted in: Cardinal
-
March 8, 2016 at 9:06 am #254050
Hello
Since the framework update – there is 17 pre set / saved ‘swift’ templates.
How can I remove these – I’ve a set for my client… and they now see ‘About (Agency Four)’ and confused.Also – future request: would be great to ‘lock’ our templates (like you’ve locked your 17 pre set).
Many thanks
David
March 9, 2016 at 12:50 pm #254371Hi,
Please activate your child theme, within the child theme functions.php file, please add or uncomment this if it already exists:
Please also rename the below templates to match the ones you want to remove.
/* ADD/EDIT PAGE BUILDER TEMPLATES ================================================== */ function custom_prebuilt_templates($prebuilt_templates) { /* * You can uncomment the lines below to remove default templates */ unset($prebuilt_templates['home-1']); unset($prebuilt_templates['home-2']); return $prebuilt_templates; } add_filter( 'spb_prebuilt_templates', 'custom_prebuilt_templates' );
March 9, 2016 at 12:55 pm #254373Thanks David
I’ll add this now.
As mentioned – would be good to lock our own templates.
D
March 9, 2016 at 1:01 pm #254377Ah sorry, yes – do you mean add your templates as pre-set like we do?
Thanks.
March 9, 2016 at 1:06 pm #254380Ok – added the code / uncomment – and got a 500 error.
Attached is a screenshot – I’d like to remove all the swift ones – like ‘About (Agency four)’
How do I name these?If I can then be able to lock my own – like the swift ones – that’ll be ace
Attachments:
You must be logged in to view attached files.March 9, 2016 at 1:13 pm #254383Hi,
Please add your FTP details I’ll take a look.
Did you do this within your child theme?
Thanks.
March 9, 2016 at 2:36 pm #254419Hello
Yes, did this with my child theme – got the error – and then reverted back.
you say:Please also rename the below templates to match the ones you want to remove.
So can you give me an example on how to remove About (Agency four)?
Thanks
D
March 9, 2016 at 2:54 pm #254425Hi,
Sorry, can I confirm which Swift Framework plugin version you are running?
Thanks.
March 9, 2016 at 5:00 pm #254458Hey – using the latest v2.0.3
also the latest wordpress 4.4.2 / cardinal theme 2.4.2D
March 9, 2016 at 5:38 pm #254472Hi,
The below is how you remove Home (Agency Four) and About (Agency Four).
If you get a 500 error, it could mean there is a missing PHP closing bracket, I’d need your FTP details to see that.
/* ADD/EDIT PAGE BUILDER TEMPLATES ================================================== */ function custom_prebuilt_templates($prebuilt_templates) { /* * You can uncomment the lines below to remove default templates */ unset($prebuilt_templates['agency-four-home']); unset($prebuilt_templates['agency-four-about']); return $prebuilt_templates; } add_filter( 'spb_prebuilt_templates', 'custom_prebuilt_templates' );
March 9, 2016 at 7:04 pm #254495Ok – It returns a 500.
I can’t provide FTP – due to access being only granted via Cisco VPN
SO I have this in my child functions:
<?php /* * * Cardinal Functions - Child Theme * ------------------------------------------------ * These functions will override the parent theme * functions. We have provided some examples below. * * */ /* LOAD PARENT THEME STYLES ================================================== */ function cardinal_child_enqueue_styles() { wp_enqueue_style( 'cardinal-parent-style', get_template_directory_uri() . '/style.css' ); } add_action( 'wp_enqueue_scripts', 'cardinal_child_enqueue_styles' ); /* LOAD THEME LANGUAGE ================================================== */ /* * You can uncomment the line below to include your own translations * into your child theme, simply create a "language" folder and add your po/mo files */ // load_theme_textdomain('swiftframework', get_stylesheet_directory().'/language'); /* REMOVE PAGE BUILDER ASSETS ================================================== */ /* * You can uncomment the line below to remove selected assets from the page builder */ // function spb_remove_assets( $pb_assets ) { // unset($pb_assets['parallax']); // return $pb_assets; // } // add_filter( 'spb_assets_filter', 'spb_remove_assets' ); /* ADD/EDIT PAGE BUILDER TEMPLATES ================================================== */ function custom_prebuilt_templates($prebuilt_templates) { /* * You can uncomment the lines below to remove default templates */ unset($prebuilt_templates['agency-four-home']); unset($prebuilt_templates['agency-four-about']); return $prebuilt_templates; } add_filter( 'spb_prebuilt_templates', 'custom_prebuilt_templates' ); ?>
And it returns a 500 error
I passed it into my local site – same issue.Any help?
David
March 9, 2016 at 7:16 pm #254503Pretty hard without any form of access or error log.
– If you enable error reporting in your wp-config.php what is the output?
define('WP_DEBUG', true);
?
– Can you access the error logs?Thanks.
March 9, 2016 at 7:16 pm #254504Ok – Its the new swift page builder that is trying to do too much.
Before: clear, simple:
Attachments:
You must be logged in to view attached files.March 9, 2016 at 7:17 pm #254506March 9, 2016 at 7:25 pm #254508This reply has been marked as private. -
Posted in: Cardinal
You must be logged in and have valid license to reply to this topic.