Tweetbacks and Templates
Posted: Sat Jun 20, 2009 3:25 pm
After playing a while with tweetbacks, I am thinking about, how to add them more properly to s9y. I really would like to have a new comment type beside NORMAL, TRACKBACK and PINGBACK: TWEETBACK. At the moment I am saving tweetbacks as trackbacks, but this doesn't match it exactly..
When adding PINGBACK as a new comment type to the s9y core, it was easy, because pingbacks are not handled by a plugin but by the s9y core itself. Viewing from templates it doesn't matter, if a comment is a trackback or a pingback, so s9y can deliver both for the templates trackback section.
Of course I would like to have a new "comment section" now, so we have trackbacks, tweetbacks and normal comments, because tweetbacks are something in between of trackbacks and normal comments in my opinion.
I could easily add a new comment type "TWEETBACK" to the s9y core, but how to handle this? What to do with the templates? If the template doesn't support the extra tweetback section, s9y has to deliver tweetbacks as trackbacks. If the template supports it, the core has to deliver TWEETBACKs separately. But where should the core know the template feature from?
Hmm.. I could add a property to the plugins configuration, but then the blog owner has to know, if the template supports tweetbacks.
Or better: The core continues to deliver tweetbacks as TRACKBACKs but with a new extra flag on it, that is set or not. Newer templates could evaluate this extra flag. Hmm.. Perhaps this would be the most compatible solution? Old templates would fetch tweetbacks and trackbacks together, as they don't know the "extra flag". New templates could seperate tweetbacks from trackbacks by evaluating this extra flag.
Any ideas on this?
When adding PINGBACK as a new comment type to the s9y core, it was easy, because pingbacks are not handled by a plugin but by the s9y core itself. Viewing from templates it doesn't matter, if a comment is a trackback or a pingback, so s9y can deliver both for the templates trackback section.
Of course I would like to have a new "comment section" now, so we have trackbacks, tweetbacks and normal comments, because tweetbacks are something in between of trackbacks and normal comments in my opinion.
I could easily add a new comment type "TWEETBACK" to the s9y core, but how to handle this? What to do with the templates? If the template doesn't support the extra tweetback section, s9y has to deliver tweetbacks as trackbacks. If the template supports it, the core has to deliver TWEETBACKs separately. But where should the core know the template feature from?
Hmm.. I could add a property to the plugins configuration, but then the blog owner has to know, if the template supports tweetbacks.
Or better: The core continues to deliver tweetbacks as TRACKBACKs but with a new extra flag on it, that is set or not. Newer templates could evaluate this extra flag. Hmm.. Perhaps this would be the most compatible solution? Old templates would fetch tweetbacks and trackbacks together, as they don't know the "extra flag". New templates could seperate tweetbacks from trackbacks by evaluating this extra flag.
Any ideas on this?