Inline documentation for hooks in wp-links-opml.php.

props netweb.
see #25229.
Built from https://develop.svn.wordpress.org/trunk@25480


git-svn-id: http://core.svn.wordpress.org/trunk@25401 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2013-09-18 17:31:08 +00:00
parent d4672e7f2c
commit ccc0719f03
1 changed files with 24 additions and 3 deletions

View File

@ -28,7 +28,14 @@ echo '<?xml version="1.0"?'.">\n";
<head>
<title><?php printf( __('Links for %s'), esc_attr(get_bloginfo('name', 'display')) ); ?></title>
<dateCreated><?php echo gmdate("D, d M Y H:i:s"); ?> GMT</dateCreated>
<?php do_action('opml_head'); ?>
<?php
/**
* Fires in the OPML header.
*
* @since 3.0.0
*/
do_action( 'opml_head' );
?>
</head>
<body>
<?php
@ -38,14 +45,28 @@ else
$cats = get_categories(array('taxonomy' => 'link_category', 'hierarchical' => 0, 'include' => $link_cat));
foreach ( (array)$cats as $cat ) :
$catname = apply_filters('link_category', $cat->name);
/**
* Filter the OPML outline link category name.
*
* @since 2.2.0
*
* @param string $catname The OPML outline category name.
*/
$catname = apply_filters( 'link_category', $cat->name );
?>
<outline type="category" title="<?php echo esc_attr($catname); ?>">
<?php
$bookmarks = get_bookmarks(array("category" => $cat->term_id));
foreach ( (array)$bookmarks as $bookmark ) :
$title = apply_filters('link_title', $bookmark->link_name);
/**
* Filter the OPML outline link title text.
*
* @since 2.2.0
*
* @param string $title The OPML outline title text.
*/
$title = apply_filters( 'link_title', $bookmark->link_name );
?>
<outline text="<?php echo esc_attr($title); ?>" type="link" xmlUrl="<?php echo esc_attr($bookmark->link_rss); ?>" htmlUrl="<?php echo esc_attr($bookmark->link_url); ?>" updated="<?php if ('0000-00-00 00:00:00' != $bookmark->link_updated) echo $bookmark->link_updated; ?>" />
<?php