Can’t override cvit-functions.php (in inc folder) on my child theme

  • Home
  • Topics
  • Can’t override cvit-functions.php (in inc folder) on my child theme
  • Support OnlineSat-Thu / 9:30am - 5:30pm (GMT +6)
  • Your Time Our Time

Support Home Support Home CVIT Can’t override cvit-functions.php (in inc folder) on my child theme

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #9818
    morin sophie
    Participant

    Hi,

    I want to replace the <h1> by <p> in the template header for better SEO targetting.
    I know this part is generated by the cvit_theme_profile function in cvit-functions.php in my parent theme (at the inc folder).

    I tried to override it by copy pasting the inc folder in my child theme then modify the function but it doesn’t work.

    What should I do to change it (without modify the parent theme if possible) ?

    Thanks in advance for your prompt return,
    Best regards

    #9819

    Dear Morin,

    Please check this out and find out what did you missing https://developer.wordpress.org/themes/advanced-topics/child-themes/#referencing-or-including-other-files

    Best Regards,
    ThemeLooks Support Team

    #9820
    morin sophie
    Participant

    When I write this require_once( get_stylesheet_directory(). '/inc/cvit-functions.php'); on my functions.php file on my child theme, I have this error :
    Cannot redeclare cvit_preloader() (previously declared in wp-content/themes/cvit-child/inc/cvit-functions.php:62)

    I still have the inc folder on my child theme, I don’t know if I need to delete it.

    What can I do to solve this issue ?

    #9821

    Dear Morin,

    Please check this out https://stackoverflow.com/a/1953870

    Best Regards,
    ThemeLooks Support Team

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