Rewrite API logic and flush_rules
|Reported by:||here||Owned by:|
It is not clear if or how visiting the Settings -> Permalinks calls flush_rules. It is referenced occasionally as an apparent alternative to $wp_rewrite->flush_rules() in Documentation. This should be explicitly confirmed in the admin interface and/or a button based action.
Documentation for the Rewrite API functions do not point at $wp_rewrite->flush_rules() effectively. (Updated some codex links, but seems worth including a pointer inline in function definitions.)
I was confused while editing an existing theme why duplicating existing add_feed() structures in functions.php did not produce duplicated behaviour in the permalinks. ?feed=atom1 worked , but /feed/atom1/ didn't, until calling flush_rules()
Logic seems broken between these functions. Why call Rewrite API add_feed() every init, but still require a flush_rules reset to activate? They should be more explicitly linked / combined / triggered. See prior conversation in #21335