Skip to main content
12 events
when toggle format what by license comment
Aug 17, 2017 at 15:35 answer added Monkey Monk timeline score: 1
Aug 16, 2017 at 15:44 comment added Milo It's difficult and sometimes impossible to convert one type of request to another in pre_get_posts. You need to hook before query parsing if you are doing anything major, or you need to set the correct query vars in your rule to let wp know you intend this to be a single post view rather than archive.
Aug 16, 2017 at 15:11 comment added Monkey Monk @birgire I've renamed "term_slug" to "foo", is it less confusing as it? And yes, the whole thing works as expected until the post selection. I think I have to manually do the query to select the right post to display under the rewrited URL... but don't know how and where to do it.
Aug 16, 2017 at 15:09 history edited Monkey Monk CC BY-SA 3.0
added 28 characters in body
Aug 16, 2017 at 14:56 comment added birgire @MonkeyMonk I meant the term_sulg typo (should be term_slug) Maybe that's just in this example and alright in your code?
Aug 16, 2017 at 13:42 history edited Monkey Monk CC BY-SA 3.0
corrected spelling
Aug 16, 2017 at 13:38 comment added Monkey Monk Oh ! That's a mistake when writing the question... I fix that right now! ;-)
Aug 16, 2017 at 13:05 comment added Milo You use $args but don't set it anywhere.
Aug 16, 2017 at 12:37 comment added Monkey Monk hello @birgire, the "term_slug" string is only an example... but what did you mean exactly?
Aug 16, 2017 at 10:51 comment added birgire You've used term_sulg in one place
Aug 16, 2017 at 10:43 review First posts
Aug 16, 2017 at 11:02
Aug 16, 2017 at 10:42 history asked Monkey Monk CC BY-SA 3.0