Closed singpolyma closed 8 years ago
i don't want to add stuff to the feed-body element. instead i created an event in https://github.com/hannesmannerheim/qvitter/commit/885ca8b80125362f8233d6af480e61e4184a5851 that you can use to insert html from your plugin.
e.g.:
function onQvitterHiddenHtml($action) {
if($action->arg('notice')) {
echo '<ol class="notices xoxo">';
$notice = Notice::getKV('id', $action->arg('notice'));
if($notice instanceof Notice) {
$widget = new NoticeListItem($notice, $action);
$widget->show();
$action->flush();
}
echo '</ol>';
}
}
This particular change isn't for any one plugin, but to enable scraping/microformats/search engines generally. Could this markup be added to the hidden html event as a default?
hm, i don't feel this is a solution i want to build upon. in the future i might make a proper effort to make qvitter output all html directly, but that's a much bigger issue. if qvitter is going to support microformats, it should be in a proper way, with metadata tied to the visible elements.
I agree that doing the markup directly would be better, but that's a much longer-term change. I can add the snippet you suggest to a plugin or something, it just seems like the content being present in the shownotice page is applicable generally (even if no additional plugins are enabled) and not too much of a code burden. It certainly is necessary for pingback/webmention to work at all, but is useful in many other cases.
Since this is pretty Qvitter-specific, maybe I should produce a plugin, like "searchable qvitter" or something that just adds minimal bits of markup like this? The only problem with maintaining it outside qvitter is that slows adoption by qvitter-using sites.
okay okay i'll add it to qvitter...... but i don't like it! :)
Sorry for being such a nag. And thank you :)
This is needed for pingback and webmention to work properly and should improve search engine results, etc.
Re-use the mainline notice show code to get all the microformats goodness, etc.