This blog script is sorting posts alphabetically when it's supposed to sort by creation…
- User
This blog script is sorting posts alphabetically when it's supposed to sort by creation date with newest first. Any ideas why that might be?
- Assistant
The issue you're experiencing stems from the way you're comparing objects in your function. In PHP, you . When you try to do so, it doesn't perform the comparison as expected, and the sorting doesn't work, leaving your posts in their original order—which is the alphabetical order returned by .