[wp-testers] 'link' post format
dougal at gunters.org
Wed Dec 8 20:22:44 UTC 2010
In the description for the 'link' post format in the Codex, it says:
"The first <a href=""> tag in the post content will be considered the
external link for that post. Alternately, if the post consists of only a
URL, that will be the URL and the title (post_title) will be the name."
Is that just a suggestion, or do we actually have utility functions
available to help with this? I poked around a little bit in the source,
Codex, and Trac, but didn't spot anything.
Some sort of "extract_first_link_url()" and "extract_first_link_title()"
functions in core might be nice here. Unless the Codex quote is just a
*suggestion* of a possible usage, in which case, does somebody have code
for the previously mentioned functions that I can borrow? :)
Dougal Campbell <dougal at gunters.org>
More information about the wp-testers