[wp-hackers] Getting comment-template.php from a plugin? (comments outside the loop)

John Eckman eckman.john at gmail.com
Tue Apr 29 17:16:47 GMT 2008


I'm working on the wp-book plugin, which lets people pull blog posts  
into Facebook, and lets Facebook users comment on those blog entries.

In order to display comments currently - see http://apps.facebook.com/openparenthesis/ 
   - I am using:
	comments_template('comments_facebook.php');

And putting a customized comments_facebook.php file inside the theme  
directory.

What I'd prefer to do is keep the comments_facebook.php in the plugin  
directory, and point to it via the comments_template(); call,
or,
just include comment-template.php (and all the functions it defines)  
in my plugin - but I don't think I can include outside the template  
directory.

I could just copy all those functions inside the plugin folder and  
include from there, but that seems a nasty hack.

Any recommendations?

The 0.6 version of the plugin which I am current using at http://apps.facebook.com/openparenthesis/ 
  should be posted to the plugin directory shortly, or you can grab it  
from here:
	http://www.openparenthesis.org/code/wp



----------------------------------------
John Eckman
eckman.john at gmail.com
http://www.johneckman.com/
http://www.openparenthesis.org/








More information about the wp-hackers mailing list