- if ($format eq 'rss') {
- print "<item>\n" .
- "<title>" . esc_html($co{'title'}) . "</title>\n" .
- "<author>" . esc_html($co{'author'}) . "</author>\n" .
- "<pubDate>$cd{'rfc2822'}</pubDate>\n" .
- "<guid isPermaLink=\"true\">$co_url</guid>\n" .
- "<link>" . esc_html($co_url) . "</link>\n" .
- "<description>" . esc_html($co{'title'}) . "</description>\n" .
- "<content:encoded>" .
- "<![CDATA[\n";
- } elsif ($format eq 'atom') {
- print "<entry>\n" .
- "<title type=\"html\">" . esc_html($co{'title'}) . "</title>\n" .
- "<updated>$cd{'iso-8601'}</updated>\n" .
- "<author>\n" .
- " <name>" . esc_html($co{'author_name'}) . "</name>\n";
- if ($co{'author_email'}) {
- print " <email>" . esc_html($co{'author_email'}) . "</email>\n";
- }
- print "</author>\n" .
- # use committer for contributor
- "<contributor>\n" .
- " <name>" . esc_html($co{'committer_name'}) . "</name>\n";
- if ($co{'committer_email'}) {
- print " <email>" . esc_html($co{'committer_email'}) . "</email>\n";
- }
- print "</contributor>\n" .
- "<published>$cd{'iso-8601'}</published>\n" .
- "<link rel=\"alternate\" type=\"text/html\" href=\"" . esc_attr($co_url) . "\" />\n" .
- "<id>" . esc_html($co_url) . "</id>\n" .
- "<content type=\"xhtml\" xml:base=\"" . esc_url($my_url) . "\">\n" .
- "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n";
- }
+ print "<entry>\n" .
+ "<title type=\"html\">" . esc_html($co{'title'}) . "</title>\n" .
+ "<updated>$cd{'iso-8601'}</updated>\n" .
+ "<author>\n" .
+ " <name>" . esc_html($co{'author_name'}) . "</name>\n";
+ if ($co{'author_email'}) {
+ print " <email>" . esc_html($co{'author_email'}) . "</email>\n";
+ }
+ print "</author>\n" .
+ # use committer for contributor
+ "<contributor>\n" .
+ " <name>" . esc_html($co{'committer_name'}) . "</name>\n";
+ if ($co{'committer_email'}) {
+ print " <email>" . esc_html($co{'committer_email'}) . "</email>\n";
+ }
+ print "</contributor>\n" .
+ "<published>$cd{'iso-8601'}</published>\n" .
+ "<link rel=\"alternate\" type=\"text/html\" href=\"" . esc_attr($co_url) . "\" />\n" .
+ "<id>" . esc_html($co_url) . "</id>\n" .
+ "<content type=\"xhtml\" xml:base=\"" . esc_url($my_url) . "\">\n" .
+ "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n";