Create a redirect from a view using parameters

By: Vicky Tosh-Morelli | Asked: 09/06/2022
ForumsCategory: How-toCreate a redirect from a view using parameters
Vicky Tosh-Morelli asked 2 years ago
I have a faculty directory that used a view to create a profile page using a passed parameter. Each faculty member ended up with a URL that looks like https://site.name/people/faculty-profile/?id=123. We realized that not only was this terrible for branding but the profile pages weren't indexed by google. So we redid the profile pages as new custom post types.  We still use FF for creating the directly listing and in some other areas on the site we we added a filed to the directory form where we could add the new profile page URL. The problem I'm having is figuring out if there is a way to set up a redirect from https://site.name/people/faculty-profile/?id=123 to https://site.name/faculty/professor-sample. I'm using the Redirection plugin in WordPress and when I enter in the FF url with parameters I end up with a 404 result.  I tried changing the source url to Regex match so it became ^/people/faculty-profile/\?id=123 but then no redirect happens. Figured I'd start here since it may be something someone else has dealt with in Formidable.  
1 Answers
Best Answer
Vicky Tosh-Morelli answered 2 years ago
Figured out the problem. I had imported the source URL and target URL into Redirection. It doesn't take in much more than that so it had set them up as a URL and server match since I had used the full path in the source URL instead of the relative path. Once I deleted those and could go back and change them to  source: /people/faculty-profile/?id=123 Exact match URL Only Target: https://site.name/faculty/professor-sample They started working! As usual, no sooner did I post in a forum but then the solution popped up!

Making the Best WordPress Plugin even better - Together

Take on bigger projects with confidence knowing you have access to an entire community of Formidable Experts and Professionals who have your back when the going gets tough. You got this!
Join the community
crossarrow-right