888 reputation
615
bio website
location Devon, United Kingdom
age 33
visits member for 3 years, 2 months
seen 1 hour ago

2h
comment Use 'parse_query' filter to show posts that from multiple criteria
Good spot, I've removed the one from the global scope.
2h
revised Use 'parse_query' filter to show posts that from multiple criteria
Remove filter
19h
comment Display posts by month
Thanks :) I do tend to go all out on my answers, I always assume that the user is starting from scratch (unless some code is provided).
19h
answered How to show a gloabl message on a user profile page (in back end)?
20h
comment How to add “back to top button” in wordpress backend product list page and order page?
There are many plugins that can do this. Check out this one, for example - wordpress.org/plugins/scroll-back-to-top/screenshots.
20h
comment Display posts by month
@PieterGoosen - I realise that, just thought it worth mentioning for anyone else who may come across this answer in the future. I know I'm easily confused so I assume everyone else is also!
20h
comment Plugin settings not saving and 404 is generated on submit
How many fields do you have on the page? Typically you'd only have 1x setting (created via the WP function register_setting()) per page. You'd then add sections to the page (using add_settings_section()), and fields to the sections (using add_settings_field()). It looks like your sanitize_callback is $validation, which is the function/method that WP will use to sanitize/save your setting from options.php, before directing you back. I'm not sure exactly what that is referencing, but I suspet this is your issue.
20h
comment Display posts by month
One thing I will say though is that a month may be split across pages. If the OP doesn't care then happy days, just though it worth pointing out.
20h
comment Display posts by month
Good answer, and a similar concept for your custom query section as in my updated answer, just a different way of checking if the title has been output. I guess it's up to the OP if they want to incorporate the date_query or not :)
20h
revised Display posts by month
Added missed `wp_reset_query()' call
21h
comment Display posts by month
@PieterGoosen I've had a bash at a single query method, but I'd be grateful for any (constructive) criticisms that you may have!
21h
revised Display posts by month
Added a single query method
22h
comment Display posts by month
Hmm, I'm intrigued… I suppose you could grab all the posts newer than X using date_query, and then break them out in to a multi-dimensional array. I may have a go at that, but I’m looking forward to a super-simple answer from you later ;-)
23h
revised Checkbox Undefined index error in Plugin
Fixed missing '$' variable symbol
23h
comment Checkbox Undefined index error in Plugin
One thing you can try - you have checked="checked" in your code, even though you are using the checked() function. And how did you get on with checking if $iwmp_settings['single_images_zoom'] was set to fix the other error?
23h
comment Display posts by month
Really? What are you thinking? I did think about GROUP BY, but the OP want's headings for the month/year, so my tiny brain can't see past multiple queries :-/
23h
revised Display posts by month
added 65 characters in body
23h
answered Display posts by month
1d
comment Display posts by month
To achieve this structure you'd need multiple queries. First you'd need to identify the months to display, and then you'd loop through the results and grab the relevent posts. I will attempt an answer shortly...
1d
comment Query posts from multiple post types sorted by overarching menu order
Ok, fair enough on the post types. For menu_order, it is possible to add a secondary orderby parameter, such as post_type - so if all 3 types add the order 10 you could still control wich of those is displayed first. If that's no good, what exactly is the problem? You've identifed that you can add overarching_menu_order as a custom value, and you know how to manipulate the query using the pre_get_posts hook and the $query->set() method...