• I have designated my blog page to hold all of my post. When I write a post only one is showing in the feed when in the reader I have it shower that 10 should. Also I am getting this error at the bottom of each of my post:
    Fatal error: Call to undefined function twentyten_posted_in() in /home/content/18/8032218/html/wp-content/themes/coburns/single.php on line 35

    The site is http://www.coburnsexclusive.com/blog

    Here is the code for single.php: Any help would be great!

    [ Code moderated. For more than 10 lines of code please use pastebin.com instead. ]

Viewing 6 replies - 1 through 6 (of 6 total)
  • It looks like you copied some code from 2010 theme? In 2010’s loop, it references

    twentyten_posted_in, which is a function defined in 2010 functions.php

    If you copied over the call to that function, but not the actual function, it will blow up like that

    Thread Starter Meganswage

    (@meganswage)

    How do I upgrade the single.php to Twentyelven? I have a custom page done outside so I can’t just apply the whole theme to my site.

    Don’t know what you mean by upgrade to 2011.

    Have you made this single.php file in your coburns theme?

    You basically either need to delete the call to twentyten_posted_in from your single.php

    Or you need to copy the twentyten_posted_in function into your theme’s functions.php

    Either action would get rid of that error

    Thread Starter Meganswage

    (@meganswage)

    I took out the twentyten_posted_in and put in the twentyeleven_posted_in for single.php

    It still isn’t functioning right. I’m not sure where to put it into teh theme functions.php

    if you are calling to twentyeleven_posted_in, then you must include that function! lol

    If you have a call, you must have a corresponsing function within your own theme… just because the function exists in 2010, or 2011, and those themes are uploaded to your site, you can’t call functions from them. The function must exist in your active theme (or possibly the parent theme if you are using a child theme)

    if ( ! function_exists( 'twentyeleven_posted_on' ) ) :
    function twentyeleven_posted_on() {
    	printf( __( '<span class="sep">Posted on </span><a href="%1$s" title="%2$s" rel="bookmark"><time class="entry-date" datetime="%3$s" pubdate>%4$s</time></a><span class="by-author"> <span class="sep"> by </span> <span class="author vcard"><a class="url fn n" href="%5$s" title="%6$s" rel="author">%7$s</a></span></span>', 'twentyeleven' ),
    		esc_url( get_permalink() ),
    		esc_attr( get_the_time() ),
    		esc_attr( get_the_date( 'c' ) ),
    		esc_html( get_the_date() ),
    		esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),
    		esc_attr( sprintf( __( 'View all posts by %s', 'twentyeleven' ), get_the_author() ) ),
    		get_the_author()
    	);
    }
    endif;

    This is the function in question….

    Thread Starter Meganswage

    (@meganswage)

    Thanks for the help…I’m still not understanding. I’ll eventually figure it out.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Fatal Error- Call to Undefined Function’ is closed to new replies.