I wrote this plugin because I was feeling lazy. I did not want to track down the titles for all the pages I have linked to, so I wrote a plugin to do it for me. Introducing MTLinkTitles.
Download one of the following files, unpack it, and place link_titles.pl in your plugins/ directory.
Usage example:
<MTEntryBody link_titles="1">
link_titles
- When this filter is applied, any anchor tag (i.e. <a href="blah blah">) that appears in the resulting text will be visited to gather the title of the page, which will then be added to the tag itself (e.g. title="Page Title").
- The titles will be cached with MT::PluginData so that once a title is found, no further HTTP requests need to be made. If the title has changed and you would like to get the new one, just browse through the mt_plugindata table and delete the row with MTLinkTitles as the plugin value and the URL as the key.
- If that doesn't work well for everybody, I'd be willing to work up another cache-clearing method.
Update (2003-06-08 11:27)
- No, this will not override existing title attributes.
Posted by rayners | Comments (8) | TrackBack