This patch adds a microformat date/time (abbr) tag around the date in the theme_node_submitted() function. Because FireFox adds a dotted border to all abbr tags, I've also added a CSS declaration to node.css which removes this.

More about this microformat: http://microformats.org/wiki/datetime-design-pattern

Comments

dman’s picture

Yay microformats everywhere!
I do things this to my themes when I can remember - for user profiles and events usually. Good move.

jjeff’s picture

StatusFileSize
new1.33 KB

Here's a new patch that uses "published" instead of "postdate" for eventual compatibility with the hatom microformat.

dries’s picture

Cool. For people that want to help add support for Microformats to Drupal, make sure to implement this Firefox plugin: https://addons.mozilla.org/en-US/firefox/addon/2240 ...

dries’s picture

https://addons.mozilla.org/en-US/firefox/addon/4106 is also a good plugin and makes it easier to debug/test microformats (they have some special debug tools built-in).

dries’s picture

This patch alters theme_node_submitted() but it doesn't seem to be used in chameleon and Garland overwrites it in phptemplate_node_submitted($node). In other words, it's not actually easy to test with the core Drupal themes. :)

Bluemarine uses it though, although that single tag is not enough to get the tag recognized by the Microformat tools mentioned above. Why not take it a step further? :)

dman’s picture

I thought it was intended that a microformatted page would have a 'profile' meta, stating the fact. ... but on trawling the wiki I see no real progress has been made on that in the last year or two.

Anyway, next is getting microformats into user profiles ... :-B
How cool is this? see the paragraph on how Satisfaction use HCard to pre-populate all your sign-up data from other social networking sites! Drupal can do this! (Yeah, new issue, off topic, slightly, I know...)

moshe weitzman’s picture

That Satisfaction signup is real slick. It does seem though that OpenID+Simple registration does Satisfaction stuff and more ... hopefully someone will enhance this so more core themes use it and Firefox sees the microformat.

dman’s picture

Yup, openid is a more fully-featured version of the same goal, and is a good thing. I just liked the way that the microformat/hcard approach absorbed info you'd allowed to be public to be re-used in a way that was actually useful ... without the authentication/trust overhead.

Having recently signed up with linkedin and been both impressed and disturbed by the way it grabbed your other identities, the innocuous, self-published hcard approach felt better to me.

I don't see any reason why both are not compatible. It's just a matter of how much you trust the brokers to distribute your 'identity'. If a random blog site wants my identity password, that's a "no". If they want permission to view and re-use my public identity, then it's OK.
... for me...

catch’s picture

Version: 6.x-dev » 7.x-dev
Status: Needs review » Needs work

bumping to D7. And code needs work for the garland implementation requested in #5

catch’s picture

Status: Needs work » Closed (won't fix)

Going to mark this won't fix, because we'll have RDFa in core soon, and becuase it's a lot easier to do stuff like this in contrib now, and because theme_node_submitted() no longer exists in D7.