Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Custom URL Result Page Not Working
This topic contains 2 replies, has 2 voices, and was last updated by kid_a2 6 years, 8 months ago.
- AuthorPosts
- March 14, 2017 at 6:24 am #12279
Hi, I’m having trouble setting up the search form to show the results in the proper layout. Essentially, we’re using archive pages to display post results from a category. We have your search form in the widget sidebar for the archive page. What we want is for the search results to display in the same archive page layout instead of the default search page.
Just to test it, I’ve setup a page called “test” that has the results shortcode in it, but all that seems to be returned is a 404 when using the search form.
Here’s a page with the search sidebar: http://cleanlabel001.staging.wpengine.com/category/magnified-list/baby-food/
And this is where I tried to setup a result page: http://cleanlabel001.staging.wpengine.com/test-page
I’ve attached the FTP info in an .xml if you need that.Also, in order to view the site you’ll need to enter different credentials before the standard WordPress login:
user: cleanlabel001
pwd: 943caff3Thanks for any help you can give!
-
This topic was modified 6 years, 8 months ago by
kid_a2.
March 15, 2017 at 12:16 am #12323Hi!
I believe you will have to edit the search.php file in the currently active theme directory for that, as that is the one that’s invoked when WordPress passes the results. I believe it’s not possible to simply bypass the search results to a different page, I’m almost sure they will be overridden with the default page content.
To change the URL of the search page, you will have to use .htaccess rules (or other methods) to resolve the redirections, I beileve this is a good tutorial on how to do that: http://wpengineer.com/2258/change-the-search-url-of-wordpress/
Best,
Once the desired redirection works, you can change the redirection in options in ajax search pro to the same URL and pattern.
In this case, still the search.php file in the theme directory will handle the layout, but will be ‘covered’ under a different URL, as a page.
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
March 17, 2017 at 12:42 am #12364You cannot access this content. -
This topic was modified 6 years, 8 months ago by
- AuthorPosts
You must be logged in to reply to this topic.