Where does the redirect from shortlink to permalink happen?

That’s handled by the redirect_canonical function, set up as a default template_redirect filter. So it can be customized either by : a template_redirect filter, with a priority value lower than 10, so it runs before the redirect_canonical function (which will eventually skip the next filters by making a redirect). a redirect_canonical filter called by the … Read more

How to Set Both Category and Sub-Category Level at Root. It should also obey post rule as /category/sample-post and /sub-catgeory/sample-post?

You’ll need to define your own rewrite tag, and add the tag into the permalink structure. add_rewrite_tag() to register the new structure tag available_permalink_structure_tags filter to add to Permalinks interface post_link filter to change the URL of posts Below is untested and incomplete code, but should get you pretty far. add_action( ‘init’, static function () … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)