Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Feed search problem
- This topic has 7 replies, 2 voices, and was last updated 6 years, 5 months ago by
Ernest Marcinko.
-
AuthorPosts
-
December 18, 2019 at 9:28 pm #25083
Bertnick69
ParticipantHi,
I have an Ajax search plugin for searching the entire site, but when I search on some feeds the result is always a page of error.
How can I solve this problem?–—-I have already contacted the wp rss aggregator plugin developers and they answered this—
Hi Nicola,There seems to be a bug in the Ajax Search Plugin that causes it to display result page that are meant to be visible only on the admin back end side.
For example, when I search a term using the field provided and then simply click in the field , I get the below results:
IMAGE1As you can see, the feed sources you’ve set up on your site under RSS Aggregator > Feed Sources are listed here. This also explains why searching ‘riscaldamento’ yields the below result, which is in fact a link to https://papertel.eu/?post_type=wprss_feed_item&p=909. This link is meant to be accessed only internally, and not for your site’s visitors, thus yielding a 404 Not Found error page.
IMAGE2You will need to get in touch with the developers of Ajax Search Pro with these observations and request them to provide a resolution.
December 19, 2019 at 8:52 am #25094Ernest Marcinko
KeymasterYou cannot access this content.
December 19, 2019 at 10:28 am #25096Bertnick69
ParticipantYou cannot access this content.
December 19, 2019 at 10:47 am #25097Ernest Marcinko
KeymasterHi,
I see what was wrong there, the developer didn’t mention, that the feed link URLs are not the default permalinks, but stored in a custom field. I have applied a custom code into the functions.php file in your theme, based on this knowledge base.
For future reference, this is the code applied:
add_filter( 'asp_results', 'asp_custom_link_meta_results', 10, 1 ); function asp_custom_link_meta_results( $results ) { // Change this variable to whatever meta key you are using $key = 'wprss_item_permalink'; // Parse through each result item foreach ($results as $k=>$v) { if ( function_exists('get_field') ) $new_url = get_field( $key, $v->id, true ); // ACF support else $new_url = get_post_meta( $v->id, $key, true ); // Change only, if the meta is specified if ( !empty($new_url) ) { $results[$k]->link = $new_url; } } return $results; }December 19, 2019 at 10:54 am #25098Bertnick69
ParticipantYou cannot access this content.
December 19, 2019 at 10:57 am #25099Ernest Marcinko
KeymasterIf I search feed diritto, and click on “Feed Diritto” it gives me the same URL as the back-end, see my previous post:
– Back-end: https://i.imgur.com/0zVX9z1.png
– Search: https://i.imgur.com/PrJwv3w.png
That seems to me the correct URL, as it is the same as on the wordpress dashboard.December 19, 2019 at 11:53 am #25103Bertnick69
ParticipantIn truth the slash http://www.papertel.eu/wprss_feed_categories/feed-economia/.
I think the problem is generated by the slash after papertel.eu/, but I can’t modify it. From the back end I can only edit ‘feed-diritto’ and not /wprss_feed_categories/December 19, 2019 at 12:37 pm #25104Ernest Marcinko
KeymasterHi,
That cannot be changed in WordPress, that is automatically added. If it does not work, you probably have a misconfigured .htaccess rule or mod_rewrite rule in the apache server configuration.
-
AuthorPosts
- You must be logged in to reply to this topic.