url rewriting – Rewrite custom post type URL in search
Now, the authors are correctly shown in search results. Although, they are linked to a wrong page, /?post_type=guest-author&p=2148, which brings to a 404.
I’d like to be able to get the URL, interprete it, and redirect to the correct page (which is in the form of /archives/author/name-surname/.
I’m trying to get it working with a rewrite URL, but I’m not able to catch the data and formulate the rewrite.