New Landing How can we help? Themeforest Theme Support Dante How to disable Meta Options

Viewing 15 posts - 1 through 15 (of 18 total)
  • Posted in: Dante
  • #63058
    abo
    Member
    Post count: 41

    Hello

    We would like to disable the “Meta Options” on the Product and Pages, so no one can edit them.
    How can we achieve this?

    Thanks
    Aldo

    #63137
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    HI,
    Hi,
    Please open to edit meta-boxes.php at /dante/swift-framework/
    Find this code at line 269

    'pages' => array( 'post', 'portfolio', 'page', 'product', 'team', 'galleries' ),
    Replace with 
    'pages' => array( 'post', 'portfolio', 'team', 'galleries' ),
    
    Find this code at line 554
    'pages' => array( 'post', 'portfolio', 'page' ),
    Replace with
    'pages' => array( 'post', 'portfolio' ),

    Hope it help you and please take a backup of file before making any changes

    Thanks ๐Ÿ™‚
    With Best Regards
    Swift Ideas

    #64496
    abo
    Member
    Post count: 41

    Hi Mohammad

    Thanks for your feedback.
    Is there another way without editing core?

    Thanks,
    Aldo

    #64509
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please put this code at functions.php under theme directory

    remove_meta_box( 'page_heading_meta_box' , 'page' , 'normal' );
    remove_meta_box( 'page_heading_meta_box' , 'product' , 'normal' );
    remove_meta_box( 'page_background_meta_box' , 'page' , 'normal' );

    Hope it will help you sure .

    Thanks

    #64516
    abo
    Member
    Post count: 41

    Hi,

    Thanks, but unfortunately I get this error:
    Fatal error: Call to undefined function remove_meta_box() in /www/htdocs/wp-content/themes/dante-child/functions.php on line 354

    Aldo

    #64535
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please remove that one code and use new one code

    add_action( 'admin_head', 'remove_my_meta_boxen' );
    function remove_my_meta_boxen() {
    	remove_meta_box( 'page_heading_meta_box' , 'page' , 'normal' );
    remove_meta_box( 'page_heading_meta_box' , 'product' , 'normal' );
    remove_meta_box( 'page_background_meta_box' , 'page' , 'normal' );
    }

    Thanks

    #64536
    abo
    Member
    Post count: 41

    Hi Mohammad

    Thanks.
    No error, but the Swift Meta Options are still here.

    Thanks
    Aldo

    #64539
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please check on product and page edit screen and need marked screenshots .

    Thanks

    #64540
    abo
    Member
    Post count: 41
    This reply has been marked as private.
    #64552
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please remove that one code and use new one code complete code

    add_action( 'admin_head', 'remove_my_meta_boxen' );
    function remove_my_meta_boxen() {
    remove_meta_box( 'page_heading_meta_box' , 'page' , 'normal' );
    remove_meta_box( 'page_heading_meta_box' , 'product' , 'normal' );
    remove_meta_box( 'page_background_meta_box' , 'page' , 'normal' );
    remove_meta_box( 'product_meta_box' , 'product' , 'normal' );
    remove_meta_box( 'slider_meta_box' , 'page' , 'normal' );
    remove_meta_box( 'page_meta_box' , 'page' , 'normal' );
    }

    Thanks

    #64564
    abo
    Member
    Post count: 41

    Perfect!

    Thanks a lot.

    Cheers
    Aldo

    #64566
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    You welcome . Glad ๐Ÿ™‚ that issue resolved .
    Thanks
    With Best Regards
    Swift Ideas

    #94985
    alemarengo
    Member
    Post count: 695
    This reply has been marked as private.
    #95009
    alemarengo
    Member
    Post count: 695

    Hi support.
    In the meantime, unless you were trying to fix my issue within the latest 15 mins, I got something upside-down. Home page broke > had to restore it > ok.
    Backed up Dante settings > done.
    I got into a product page > title messed up > before going to permalinks settings I noticed “Product Meta” was enable and working.
    Once fixed title length through permalinks, “Product Meta” disappeared again.
    Very weird………
    Hope you can help me!

    #95026
    Swift Ideas – Ed
    Keymaster
    Post count: 15264

    Hi @puntobiancosnc

    Check in the Screen Options tab at the top right of the page, and ensure you have it checked?

    – Ed

Viewing 15 posts - 1 through 15 (of 18 total)

You must be logged in and have valid license to reply to this topic.

License required for the following item
Login and Registration Log in · Register