WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Incomprehensible warnings related to function.include and Twenty Twelve theme (5 posts)

  1. ojedapaco
    Member
    Posted 1 year ago #

    Greetings from Puerto Vallarta Mexico!

    I'm almost embarrassed to post here, given the fact that just about everything related to WordPress has worked so nicely for me!

    I'm trying Twenty Twelve in my self-hosted Word press installation at http://www.paco-ojeda.com/blog and whenever I select Twenty Twelve (version 1.1) I get these two lines appearing at the top of my admin interface and the actual website:

    Warning: include_once(includes/custompost.php) [function.include-once]: failed to open stream: No such file or directory in /data/17/0/95/103/95755/user/97165/htdocs/blog/wp-content/themes/twentytwelve/functions.php on line 453
    
    Warning: include_once() [function.include]: Failed opening 'includes/custompost.php' for inclusion (include_path='.:/usr/services/vux/lib/php') in /data/17/0/95/103/95755/user/97165/htdocs/blog/wp-content/themes/twentytwelve/functions.php on line 453

    I have tried re-installing WordPress and the theme to no avail. If anybody can help me figure out why they are there, and how to remove them, I would be eternally grateful.

    (Yes, I know there are many image broken links. I'm in the process of consolidating three wordpress blogs into one, so I'll be eventually importing entries from them all...)

    Muchas gracias in advance!

    Paco

  2. alchymyth
    Forum Moderator
    Posted 1 year ago #

    an unedited functions.php of Twenty Twelve only has 451 lines; ending with:
    add_action( 'customize_preview_init', 'twentytwelve_customize_preview_js' );

    what is the code at the end of functions.php of your Twenty Twelve?

    your site might have been compromized;
    there is a topic with a similar problem:
    http://wordpress.org/support/topic/problem-occurred-right-after-i-install-some-themes?replies=13

  3. ojedapaco
    Member
    Posted 1 year ago #

    Hola!

    Thank you so much for you quick suggestions. I went in and looked at functions.pho on my Twenty Twelve and found this:

    /**
     * Binds JS handlers to make Theme Customizer preview reload changes asynchronously.
     *
     * @since Twenty Twelve 1.0
     */
    function twentytwelve_customize_preview_js() {
    	wp_enqueue_script( 'twentytwelve-customizer', get_template_directory_uri() . '/js/theme-customizer.js', array( 'customize-preview' ), '20120827', true );
    }
    add_action( 'customize_preview_init', 'twentytwelve_customize_preview_js' );
    ?>
    <?php
    include_once ('includes/custompost.php');
    ?>

    If it is not supposed to be there, I can easily delete it. But leaves me wondering how it got there in the first place... Any thoughts?

    Again, thanks!

    Paco

  4. alchymyth
    Forum Moderator
    Posted 1 year ago #

    have you read the related link at the end of my first reply?

  5. ojedapaco
    Member
    Posted 1 year ago #

    Yes I have. I, too, had the Photum theme installed, so I deleted the code at the end of functions.php and the offending theme. Everything seems to be back to normal.

    Thanks for touching base with me!

    Paco

Topic Closed

This topic has been closed to new replies.

About this Topic