• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Notice: Constant Names Already Defined

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › General Discussion › Notice: Constant Names Already Defined

This topic is: not resolved
  • This topic has 3 replies, 2 voices, and was last updated 7 years, 5 months ago by Victor Font.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • August 18, 2015 at 1:28 am #162696
    rougebaby
    Participant

    Hello there,

    Recently I just reinstalled my wordpress, while importing the genesis theme over, it shows these error on my frontpage. Anyone? Thanks!

    Notice: Constant CHILD_THEME_NAME already defined in /home/xtinaweb/public_html/wp-content/themes/diamonds/lib/init.php on line 46

    Notice: Constant CHILD_THEME_URL already defined in /home/xtinaweb/public_html/wp-content/themes/diamonds/lib/init.php on line 49

    http://www.xtina-web.com
    August 18, 2015 at 4:54 am #162708
    Victor Font
    Moderator

    I'm not seeing the errors when I visit the site.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    August 18, 2015 at 8:46 am #162746
    rougebaby
    Participant

    Hi Victor!

    Thanks for getting back to me! I removed these lines in function.php

    //* Child theme (do not remove)
    define( 'CHILD_THEME_NAME', 'Diamonds' );
    define( 'CHILD_THEME_URL', 'http://www.studiopress.com/' );
    define( 'CHILD_THEME_VERSION', '2.1.2' );
    
    Somehow, im getting error after updating post.
    Notice: genesis_save_custom_fields was called with an argument that is deprecated since version 2.0.0 with no alternative available. in /home/xtinaweb/public_html/wp-includes/functions.php on line 3510
    
    Warning: Cannot modify header information - headers already sent by (output started at /home/xtinaweb/public_html/wp-includes/functions.php:3510) in /home/xtinaweb/public_html/wp-admin/post.php on line 237
    
    Warning: Cannot modify header information - headers already sent by (output started at /home/xtinaweb/public_html/wp-includes/functions.php:3510) in /home/xtinaweb/public_html/wp-includes/pluggable.php on line 1196

    Thanks!

    August 19, 2015 at 10:04 pm #162948
    Victor Font
    Moderator

    There's a reason the comment says don't remove these lines. What's on line 3510 of functions.php? The genesis_save_custom_fields() function is used to save post meta / custom field data for a post or page. It is used as follows:

    $mixed = genesis_save_custom_fields( $data, $nonce_action, $nonce_name, $post, $deprecated );

    Your code must be passing the fifth parameter, which has been deprecated since version 2.0.0 of the framework.

    Here's a link to an article explaining nonce: https://www.tipsandtricks-hq.com/introduction-to-wordpress-nonces-5357


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘General Discussion’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble