Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #1439405

    Hi

    2 questions

    1: how / where do I delete page template on the template list?

    2. A template I built is not showing the content (title / blog) it should: Meinung Seite ist the template name.
    See: https://jmbuettner.ch/meinung/?preview_id=101&preview_nonce=c38b70099c&preview=true&_thumbnail_id=559
    the same content is visible if I to set the page on standart template.

    please note that php has been modified by you on my request for full content of blog (see last thread).
    regards
    Dominic

    #1439410

    screenshot of template I can not delete.
    see screenshot of templates I can’t delete:
    https://www.picdrop.com/buettner/JPdWMtQHhH

    • This reply was modified 7 months, 2 weeks ago by dbuettner.
    #1439437

    Hi,
    These are the default template options:
    Enfold_Support_5358.jpeg
    the Default Template is the file template-builder.php and can not be removed.
    To remove the other ones:
    Archives
    Blank – No Header, no Footer
    LayerSlider Blank Template

    Add this code to the end of your child theme functions.php file in Appearance ▸ Editor:

    function remove_layerslider_template( $templates, $theme, $post ) {
      unset( $templates['layerslider-blank'] );
    unset( $templates['template-archives.php'] );
    unset( $templates['template-blank.php'] );
      return $templates;
    }
    
    function adjust_template_filter() {
      remove_filter( 'theme_page_templates', [ 'LayerSliderClass', 'add_templates' ], 10, 3 );
      add_filter( 'theme_page_templates', 'remove_layerslider_template', 10, 3 );
    }
    
    add_action( 'init', 'adjust_template_filter' );

    when you add this the meta box will not show in the backend because there is no choice to be made, the Default template will be used.
    If you add your own template the meta box will then show, for example I created a file named my-template-blank.php with the Template Name: My Blank Template:
    Enfold_Support_5360.jpeg
    and now the meta box shows with this option:
    Enfold_Support_5362.jpeg
    If you also want to remove the LayerSlider blank template meta box:
    Enfold_Support_5364.jpeg
    Add this code to the end of your child theme functions.php file in Appearance ▸ Editor:

    function remove_layerslider_meta_box() {
      remove_meta_box( 'ls-page-meta-box', 'post', 'side' );
      remove_meta_box( 'ls-page-meta-box', 'page', 'side' );
    }
    add_action( 'add_meta_boxes', 'remove_layerslider_meta_box', 11 );

    Best regards,
    Mike

    #1439449

    Hi,

    ok, quite complicated for me…
    in fact I do just want to remove one of the template I did by mistake (Meinung template) and my 2. question is more relevant:

    The template I built (Meinung_seite) is not showing the content (title / blog) it should:
    See: https://jmbuettner.ch/meinung/?preview_id=101&preview_nonce=c38b70099c&preview=true&_thumbnail_id=559
    the same content is visible if I to set the page on standart template.

    What do I have to change to use my own template for the blog?
    regards
    Dominic

    #1439489

    Hi,
    You are using a blog element on a page to show your bolg. you are not using a “template” you don’t need to remove the other “templates” and you don’t need to “add” templates.
    The reason you page doesn’t show correctly is because to set the page as the default blog:
    Enfold_Support_5366.jpeg
    this is not the setting you want, I correct it for you:
    Enfold_Support_5368.jpeg
    I corrected your “template” error and now you page shows correctly.
    Please remove your “templates” this is not the correct approach.

    Best regards,
    Mike

    #1439527

    Hi Mike

    thanks for your help. Unfortunately I’m afraid to make a mess or kill the page by deleting myself the wrong templates with the php code you gave me. So if it is necessary to delete them, please do it vor me.

    You may delete the following template: MEINUNG template and Meinung_Seite.
    see screenshot: https://www.picdrop.com/buettner/JPdWMtQHhH

    Danke !
    regards
    Dominic

    #1439536

    Hi,
    I don’t know how you added the MEINUNG and Meinung_Seite templates, I don’t see them as I would expect, so you will need to remove them, not with the function above but however you added them in the first place. If you don’t remember how you added them then nevermind.

    Best regards,
    Mike

    #1439561

    Hi Mike
    Just for your info. I managed to add templates through the link to standard-template right of a page on the enfold theme (as it was in the beginning). This option does not exist on the child theme. BUT: there is no: undo. You can create a template but not delete…
    I aded you 3 screenschots from another WP page I’m working on. https://www.picdrop.com/buettner/JPdWMtQHhH
    You may download the screenshots as I will deactivate the link within one week.

    Now you know something new in enfold even you know probably everything.. :-)

    greetings and many THANKS for your support.
    Dominic

    • This reply was modified 7 months, 1 week ago by dbuettner.
    #1439573

    Hi,
    Thanks this seems to be a WordPress Block Editor feature, but after much research I didn’t find a way to remove it.
    I have asked the rest of the team for ideas on removing it, for now you can ignore it.

    Best regards,
    Mike

Viewing 9 posts - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.