|
1 <?php |
|
2 /** |
|
3 * RSS 1 RDF Feed Template for displaying RSS 1 Posts feed. |
|
4 * |
|
5 * @package WordPress |
|
6 */ |
|
7 |
|
8 header('Content-Type: ' . feed_content_type('rdf') . '; charset=' . get_option('blog_charset'), true); |
|
9 $more = 1; |
|
10 |
|
11 echo '<?xml version="1.0" encoding="'.get_option('blog_charset').'"?'.'>'; ?> |
|
12 <rdf:RDF |
|
13 xmlns="http://purl.org/rss/1.0/" |
|
14 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" |
|
15 xmlns:dc="http://purl.org/dc/elements/1.1/" |
|
16 xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" |
|
17 xmlns:admin="http://webns.net/mvcb/" |
|
18 xmlns:content="http://purl.org/rss/1.0/modules/content/" |
|
19 <?php do_action('rdf_ns'); ?> |
|
20 > |
|
21 <channel rdf:about="<?php bloginfo_rss("url") ?>"> |
|
22 <title><?php bloginfo_rss('name'); wp_title_rss(); ?></title> |
|
23 <link><?php bloginfo_rss('url') ?></link> |
|
24 <description><?php bloginfo_rss('description') ?></description> |
|
25 <dc:date><?php echo mysql2date('Y-m-d\TH:i:s\Z', get_lastpostmodified('GMT'), false); ?></dc:date> |
|
26 <?php the_generator( 'rdf' ); ?> |
|
27 <sy:updatePeriod><?php echo apply_filters( 'rss_update_period', 'hourly' ); ?></sy:updatePeriod> |
|
28 <sy:updateFrequency>1</sy:updateFrequency> |
|
29 <sy:updateBase>2000-01-01T12:00+00:00</sy:updateBase> |
|
30 <?php do_action('rdf_header'); ?> |
|
31 <items> |
|
32 <rdf:Seq> |
|
33 <?php while (have_posts()): the_post(); ?> |
|
34 <rdf:li rdf:resource="<?php the_permalink_rss() ?>"/> |
|
35 <?php endwhile; ?> |
|
36 </rdf:Seq> |
|
37 </items> |
|
38 </channel> |
|
39 <?php rewind_posts(); while (have_posts()): the_post(); ?> |
|
40 <item rdf:about="<?php the_permalink_rss() ?>"> |
|
41 <title><?php the_title_rss() ?></title> |
|
42 <link><?php the_permalink_rss() ?></link> |
|
43 <dc:date><?php echo mysql2date('Y-m-d\TH:i:s\Z', $post->post_date_gmt, false); ?></dc:date> |
|
44 <dc:creator><?php the_author() ?></dc:creator> |
|
45 <?php the_category_rss('rdf') ?> |
|
46 <?php if (get_option('rss_use_excerpt')) : ?> |
|
47 <description><?php the_excerpt_rss() ?></description> |
|
48 <?php else : ?> |
|
49 <description><?php the_content_rss('', 0, '', get_option('rss_excerpt_length'), 2) ?></description> |
|
50 <content:encoded><![CDATA[<?php the_content('', 0, '') ?>]]></content:encoded> |
|
51 <?php endif; ?> |
|
52 <?php do_action('rdf_item'); ?> |
|
53 </item> |
|
54 <?php endwhile; ?> |
|
55 </rdf:RDF> |