| @@ 71-83 (lines=13) @@ | ||
| 68 | /** |
|
| 69 | * This is a bit of a hack used to buffer feed content. |
|
| 70 | */ |
|
| 71 | function do_atom() |
|
| 72 | { |
|
| 73 | ob_start(); |
|
| 74 | // Nasty hack! In the future it would better to leverage do_feed( 'atom' ). |
|
| 75 | global $post; |
|
| 76 | try { |
|
| 77 | @include ABSPATH . 'wp-includes/feed-atom.php'; |
|
| 78 | $out = ob_get_clean(); |
|
| 79 | } catch ( Exception $e ) { |
|
| 80 | $out = ob_get_clean(); |
|
| 81 | throw( $e ); |
|
| 82 | } |
|
| 83 | return $out; |
|
| 84 | } |
|
| 85 | ||
| 86 | /** |
|
| @@ 80-92 (lines=13) @@ | ||
| 77 | /** |
|
| 78 | * This is a bit of a hack used to buffer feed content. |
|
| 79 | */ |
|
| 80 | function do_rss2() |
|
| 81 | { |
|
| 82 | ob_start(); |
|
| 83 | // Nasty hack! In the future it would better to leverage do_feed( 'rss2' ). |
|
| 84 | global $post; |
|
| 85 | try { |
|
| 86 | @include ABSPATH . 'wp-includes/feed-rss2.php'; |
|
| 87 | $out = ob_get_clean(); |
|
| 88 | } catch (Exception $e) { |
|
| 89 | $out = ob_get_clean(); |
|
| 90 | throw($e); |
|
| 91 | } |
|
| 92 | return $out; |
|
| 93 | } |
|
| 94 | ||
| 95 | /** |
|