yesterday – UX, URLs are your currency it’s how the world sees us, and gives us incredible flexibility to direct/guide users
SQL_CALC_FOUND_ROWS limits the number of returned rows via the LIMIT clause, and ensures that you don’t tax MySQL, Perform immense queries (SMOF has 600 post entries)
WHERE 1=1 is for building compound where clauses; ensures there’s no degenerate case
Type=post versus revision; status publish/private versus draft, trash
Look at rewrite.php, and canonical.php (more on that later) Default terms of “tag” and “category” can be changed in the Settings/Permalinks section of the Dashboard
Separate namespaces for pages and posts What about parent pages? In this example the permalink structure is %year%/%title%
Three joins needed to build the full cartesian product of related tables.
Get all of the terms that have a slug of “premio”, and find out what taxonomies they’re in Get the taxonomies that are post tags, and find all taxonomy object ids (that are post tags of slug “premio”) Get all of the posts that have this object id associated with them from term_relationships Order the final table by post date,starting with the most recent (0) and getting 10 of them.
Don’t want multiple URLs pointing to the same page, so canonical parsing cleans them up