| @@ -2,17 +2,17 @@ | ||
| 2 | 2 | header( 'Content-Type: ' . feed_content_type( 'atom' ) . '; charset=' . get_option( 'blog_charset' ), true ); |
| 3 | 3 | printf( '<?xml version="1.0" encoding="%s"?>', esc_attr( get_option( 'blog_charset' ) ) ); |
| 4 | 4 | ?> |
| 5 | 5 | |
| 6 | -<feed xmlns="http://www.w3.org/2005/Atom" xmlns:thr="http://purl.org/syndication/thread/1.0" xml:lang="<?php echo esc_attr( bloginfo_rss( 'language' ) ) ?>" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" <?php do_action( 'atom_ns' ) ?>> | |
| 7 | - <title><?php bloginfo_rss( 'name' ) ?> - <?php esc_html_e( 'Stream Feed', 'stream' ) ?></title> | |
| 8 | - <link href="<?php self_link() ?>" rel="self" type="application/rss+xml" /> | |
| 9 | - <link href="<?php echo esc_url( $records_admin_url ) ?>" /> | |
| 10 | - <subtitle type="html"><?php esc_html( bloginfo_rss( 'description' ) ) ?></subtitle> | |
| 11 | - <updated><?php echo esc_html( mysql2date( 'c', $latest_record, false ) ) ?></updated> | |
| 12 | - <id><?php echo esc_url( $latest_link ) ?></id> | |
| 13 | - <sy:updatePeriod><?php echo esc_html( 'hourly' ) ?></sy:updatePeriod> | |
| 14 | - <sy:updateFrequency><?php echo absint( 1 ) ?></sy:updateFrequency> | |
| 6 | +<feed xmlns="http://www.w3.org/2005/Atom" xmlns:thr="http://purl.org/syndication/thread/1.0" xml:lang="<?php echo esc_attr( bloginfo_rss( 'language' ) ); ?>" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" <?php do_action( 'atom_ns' ); ?>> | |
| 7 | + <title><?php bloginfo_rss( 'name' ); ?> - <?php esc_html_e( 'Stream Feed', 'stream' ); ?></title> | |
| 8 | + <link href="<?php self_link(); ?>" rel="self" type="application/rss+xml" /> | |
| 9 | + <link href="<?php echo esc_url( $records_admin_url ); ?>" /> | |
| 10 | + <subtitle type="html"><?php esc_html( bloginfo_rss( 'description' ) ); ?></subtitle> | |
| 11 | + <updated><?php echo esc_html( mysql2date( 'c', $latest_record, false ) ); ?></updated> | |
| 12 | + <id><?php echo esc_url( $latest_link ); ?></id> | |
| 13 | + <sy:updatePeriod><?php echo esc_html( 'hourly' ); ?></sy:updatePeriod> | |
| 14 | + <sy:updateFrequency><?php echo absint( 1 ); ?></sy:updateFrequency> | |
| 15 | 15 | <?php |
| 16 | 16 | /** |
| 17 | 17 | * Action fires during RSS head |
| 18 | 18 | */ |
| @@ -18,9 +18,9 @@ | ||
| 18 | 18 | */ |
| 19 | 19 | do_action( 'atom_head' ); |
| 20 | 20 | |
| 21 | 21 | foreach ( $records as $record ) : |
| 22 | - $record_link = add_query_arg( | |
| 22 | + $record_link = add_query_arg( | |
| 23 | 23 | array( |
| 24 | 24 | 'record__in' => $record->ID, |
| 25 | 25 | ), |
| 26 | 26 | $records_admin_url |
| @@ -29,20 +29,20 @@ | ||
| 29 | 29 | $author = get_userdata( $record->author ); |
| 30 | 30 | $display_name = isset( $author->display_name ) ? $author->display_name : 'N/A'; |
| 31 | 31 | ?> |
| 32 | 32 | <entry> |
| 33 | - <title type="html"><![CDATA[[<?php echo esc_html( $domain ) ?>] <?php echo esc_html( $record->summary ) // xss ok ?> ]]></title> | |
| 34 | - <link href="<?php echo esc_url( $record_link ) ?>" /> | |
| 35 | - <updated><?php echo esc_html( mysql2date( 'c', $record->created, false ) ) ?></updated> | |
| 33 | + <title type="html"><![CDATA[[<?php echo esc_html( $domain ); ?>] <?php echo esc_html( $record->summary ); // xss ok ?> ]]></title> | |
| 34 | + <link href="<?php echo esc_url( $record_link ); ?>" /> | |
| 35 | + <updated><?php echo esc_html( mysql2date( 'c', $record->created, false ) ); ?></updated> | |
| 36 | 36 | <author> |
| 37 | - <name><?php echo esc_html( $display_name ) ?></name> | |
| 37 | + <name><?php echo esc_html( $display_name ); ?></name> | |
| 38 | 38 | </author> |
| 39 | - <category term="connector" label="<?php echo esc_html( $record->connector ) ?>" /> | |
| 40 | - <category term="context" label="<?php echo esc_html( $record->context ) ?>"/> | |
| 41 | - <category term="action" label="<?php echo esc_html( $record->action ) ?>" /> | |
| 42 | - <category term="ip" label="<?php echo esc_html( $record->ip ) ?>" /> | |
| 43 | - <id><?php echo esc_url( $record_link ) ?></id> | |
| 44 | - <summary type="html"><![CDATA[- <?php echo esc_html( $display_name ) ?> ]]></summary> | |
| 39 | + <category term="connector" label="<?php echo esc_html( $record->connector ); ?>" /> | |
| 40 | + <category term="context" label="<?php echo esc_html( $record->context ); ?>"/> | |
| 41 | + <category term="action" label="<?php echo esc_html( $record->action ); ?>" /> | |
| 42 | + <category term="ip" label="<?php echo esc_html( $record->ip ); ?>" /> | |
| 43 | + <id><?php echo esc_url( $record_link ); ?></id> | |
| 44 | + <summary type="html"><![CDATA[- <?php echo esc_html( $display_name ); ?> ]]></summary> | |
| 45 | 45 | <?php |
| 46 | 46 | /** |
| 47 | 47 | * Action fires during Atom item |
| 48 | 48 | */ |