How to display comments in an entry (why not static page ?)

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
Post Reply
Frandy

How to display comments in an entry (why not static page ?)

Post by Frandy »

Hi,

How is it possible to display all comments in an entry (static page) with same comments format like in serendipity_plugin_comments ?

i'd like to do it using a link, for example at the bottom of serendipity_plugin_comments....

Thanks for help

Frandy
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: How to display comments in an entry (why not static page

Post by garvinhicking »

I don't know what you mean - a static page does not have any comments. That's what makes a static page different than an entry...?!

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Frandy

Post by Frandy »

I'd like to display all comments of all entries of the blog into a page, sorted by date or category.

Is it possible to do that esasily ?

thanks

Frandy
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi!
Frandy wrote:I'd like to display all comments of all entries of the blog into a page, sorted by date or category.
Ah, okay. This would be no static page then, but a plugin.

You can do that with 2-3 lines of PHP code, by calling the s9y api serendipity_fetchComments(). Or you can write up your own SQL to fetch the comments in about 10 lines of SQL and 2-3 lines of PHP code.

Then you need the surrounding plugin framework, maybe about 100 lines. Take a simple plugin that has permalink page support, like the serendipity_event_wrapurl plugin.

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Maximilian

Post by Maximilian »

Ah, okay. This would be no static page then, but a plugin.

You can do that with 2-3 lines of PHP code, by calling the s9y api serendipity_fetchComments(). Or you can write up your own SQL to fetch the comments in about 10 lines of SQL and 2-3 lines of PHP code.

Then you need the surrounding plugin framework, maybe about 100 lines. Take a simple plugin that has permalink page support, like the serendipity_event_wrapurl plugin.

Regards,
Garvin
i could be interrested with that functionnality too but i don't know PHP.
does somebody could help me ?

it should be so nice

thanks a lot for your help

max
Post Reply