Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //attaches in-reply-to classes to the first link in the post
- function the_content_in_reply_to_filter($content) {
- return preg_replace('`\<[aA] (.*?)>(.*?)\@(.*?)</[aA]>`','<a class="u-in-reply-to" rel="in-reply-to" $1>$2@$3</a>',$content,1);
- }
- add_filter( 'the_content', 'the_content_in_reply_to_filter' );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement