Opened 17 years ago
Closed 15 years ago
#4595 closed enhancement (wontfix)
Format of feed (RSS, Atom) should be an option
Reported by: | terraces | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 2.3 |
Component: | Feeds | Keywords: | needs-patch close |
Focuses: | Cc: |
Description
Summary
Currently, WordPress uses RSS 2.0 as the default format for its syndication feeds
In case anyone wants a different default format, he must hack Wordpress core (or tell users to use /feed/type rather than /feed, but he still needs to change any page / template that links to the feeds).
This patch allows users to choose default RSS type in the admin interface, in the Options / Reading page.
Version
This patch has been created from the current 2.3 SVN code (trunk).
Modified files
- wp-includes/feed.php: Adds a wp_dropdown_feeds() method, that lists available feed types within <option> items to be used in a <select> list
- wp-admin/options-reading.php: Displays the <select> list in the RSS options form to let user choose default type. Chosen type is saved as 'rss_format' in the wp_options table
- wp-includes/functions.php: Use get_options('rss_format') rather than 'rss2' default for feed type
Attachments (6)
Change History (24)
#2
@
17 years ago
Hi,
Whant do you mean exactly ? I can't see anything that can be directly set in options.php ? Is there another way to save this "RSS type" option in database ? (which is what my patch tries to do)
Thanx
#3
@
17 years ago
foolswidon proposes a solution that's somewhere between the current situation and your solution.
Make the feed type an option, but don't add a UI for it to Options - Reading. More options equals more difficult to use, especially with settings that don't mean anything to a large part of our userbase. The power users that do care can change the option through options.php. Not as easy to use, but we're talking about power users anyway.
You could even create a plugin on top of that, which integrates with the GUI, so people that are interested in their feed type can change it easily as well.
#6
@
17 years ago
+1 for hidden option, but I would use default_rss_format as the name of the option.
Complete patch for trunk attached.
#9
@
17 years ago
- Summary changed from Allow users to choose type of RSS feeds to Format of feed (RSS, Atom) should be an option
#10
@
17 years ago
I understand the naming used by Otto42, it's consistent with other options that begin rss, but time to move fwd ;-) And 'default' seems unnecessary in option name, particularly when sometime it means can be over written by post specific options.
#12
follow-up:
↓ 13
@
17 years ago
lloyd: I would have no problem with "default_feed_format", however it is actually a default, because it can be overridden by the user requesting the feed (not on a per-post basis). If the user gets /feed/atom, then they get an atom feed, regardless of the setting.
Will refresh this for trunk if anybody is interested.
#13
in reply to:
↑ 12
;
follow-up:
↓ 14
@
16 years ago
Replying to Otto42:
however it is actually a default, because it can be overridden by the user
requesting the feed (not on a per-post basis). If the user gets /feed/atom,
then they get an atom feed, regardless of the setting.
Default in the context of options seems to be when it can be overriden on a per post basis, or otherwise in the UI.
#14
in reply to:
↑ 13
@
16 years ago
Replying to lloydbudd:
Default in the context of options seems to be when it can be overriden on a per post basis, or otherwise in the UI.
Bah, but in the context of the functions it is default_feed, so you win ;-)
#15
@
15 years ago
- Component changed from Administration to Feeds
- Keywords needs-patch close dup added; has-patch removed
- Milestone changed from 2.9 to Future Release
I'm pretty sure there is a dup of this one in the Feeds component.
#16
follow-up:
↓ 17
@
15 years ago
- Keywords dup removed
the UI should be done in a plugin imo. suggesting wontfix.
see #5802 for the rest.
Hi terraces,
Thank you for contributing to WordPress!
I didn't think this option should be part of the UI, because for almost all people the option is not useful. I would suggestion adjusting the patch to leave it as something that can be set in wp-admin/options.php if really desired.