Title: get_recent_posts
Last modified: August 18, 2016

---

# get_recent_posts

 *  Anonymous
 * [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/)
 * Howdy ho,
    I have this script: <?php c2c_get_recent_posts(3); ?> currently on
   my blog index page, it works fine and dandy. But now I want it on my whole _website_
   index page. When I try and do so, Recent Posts Fatal error: Call to undefined
   function: c2c_get_recent_posts() in /public_html/beta/index.php on line 64 Line
   64 : <?php c2c_get_recent_posts(3); ?> So what do I change to make this thing
   work? Ta.

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

 *  [dmclark](https://wordpress.org/support/users/dmclark/)
 * (@dmclark)
 * [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/#post-95513)
 * did you activate the plugin?
 *  Thread Starter Anonymous
 * [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/#post-95657)
 * Yes I did.
    It works fine on the blog index, but not my website index. I want
   it to be displayed here: index.php its currently displayed in my blog: /blog/
   index.php
 *  [digitalgrape](https://wordpress.org/support/users/digitalgrape/)
 * (@digitalgrape)
 * [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/#post-95670)
 * Nobody has any ideas?
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/#post-95677)
 * I don’t know about this specific plugin, so I’m making just a(n educated?) guess
   by analogy…
    Whenever I want to call a template tag in a file that is _outside_
   the blog directory, I have to put at the top the wp-blog-header call! = you know,
   the lines that say “do not remove this” 🙂
 *  [digitalgrape](https://wordpress.org/support/users/digitalgrape/)
 * (@digitalgrape)
 * [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/#post-95729)
 * Thankyou, Thankyou, Thankyou!
    That’s fixed it!! Thankyou very much.
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/#post-95731)
 * Pleased that my “guess” worked 🙂

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

The topic ‘get_recent_posts’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 6 replies
 * 4 participants
 * Last reply from: [moshu](https://wordpress.org/support/users/moshu/)
 * Last activity: [21 years, 8 months ago](https://wordpress.org/support/topic/get_recent_posts/#post-95731)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
