orderby_last_activity not working
-
The option “orderby_last_activity” was not working for me;
but “orderby_last_comment” was.After some debugging I fixed by quoting the the 0 in the GREATEST function call.
return $sql.', GREATEST(
‘.$wpdb->posts.’.
post_date, IFNULL(
last_comment.
date, "0")) AS
last_activity';
At this point I cannot precisely explain the reason of this (but probably with casting). On my MySQL
select greatest('2013-01-01 00:00:00', 0)
return a BLOB while “0” returns the date.Thats it, thank you for the plugin and have a good day ??
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘orderby_last_activity not working’ is closed to new replies.