I had some custom code (which didn’t work) then cycled through the Codex examples (which didn’t work) and now I’m wondering what I’m doing wrong. The code I originally used worked properly on a different site, but it wasn’t translating. In any case, here’s what I have now.
// Remember to flush_rules() when adding rules
// Adding a new rule
$newrules = array();
$newrules['(project)/(\d*)$'] = 'index.php?pagename=$matches&id=$matches';
return $newrules + $rules;
// Adding the id var so that WP recognizes it
There is no “id” elemt in the wp_query array. I’ve reset my permalinks, logged in, logged out, refreshed, cleared cache, etc etc. Something’s not right. So…Where am I going wrong?