Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Quickfinders among search results
- This topic has 8 replies, 2 voices, and was last updated 5 years, 11 months ago by
Ernest Marcinko.
-
AuthorPosts
-
June 17, 2020 at 10:47 am #27914
dg-servizi48
ParticipantI’m building a website for a company
https://home.datamars.com/This site has integrated Office 365 authentication, so to be able to enter to see it you can do it with the credentials that I put and that I report below but first by entering the administration page.
PROBLEM
We would like to obtain quickfinders in the search results, so that they are directly clickable.As an example, if you search for the term “Academy”, the page entitled “Quick links LMS” appears as a search result, which contains 2 quickfinders that contain this word.
With what settings do I make these quickfinders appear directly on the search results page, so that clicking on them will lead directly to their link?
Thanks
DG Services
-
This topic was modified 5 years, 11 months ago by
dg-servizi48.
June 17, 2020 at 12:35 pm #27923Ernest Marcinko
KeymasterHi,
Thanks for the details, but I cannot log-in with the details. The microsoft login says, that there are no such user.
Unless these quick links are available as either custom post types for some sort, or taxonomy terms, then I’m afraid that is not possible. Optimally, each result should be a separate post type object.
June 20, 2020 at 10:48 am #27986dg-servizi48
ParticipantYou cannot access this content.
June 22, 2020 at 12:01 pm #28001Ernest Marcinko
KeymasterYou cannot access this content.
June 22, 2020 at 12:24 pm #28005dg-servizi48
ParticipantYou cannot access this content.
June 22, 2020 at 12:35 pm #28009dg-servizi48
ParticipantYou cannot access this content.
June 22, 2020 at 2:20 pm #28013Ernest Marcinko
KeymasterThe “Quickfinder Items” post type seems to be the one you are looking for: https://i.imgur.com/IzbKJti.png
However it looks like it’s a sort of “private” post type, with a different structure, and no permalinks, so it may not work.June 22, 2020 at 3:02 pm #28018dg-servizi48
ParticipantYou cannot access this content.
June 22, 2020 at 3:16 pm #28024Ernest Marcinko
KeymasterWell, that the plugin cannot affect unfortunately. Looks like that post type stores the URL in a custom field or somewhere else, however WordPress will always display the original permalink.
Form the page editor, it looks like the custom field isthegem_quickfinder_item_dataYou can try a custom code, but you might have to ask the theme/plugin author as well, which implements this post type, to suggest how to get the correct URL.
Try adding this custom code to the functions.php in your theme/child theme directory. Before editing, please make sure to have a full site back-up just in case!add_filter('post_type_link', 'asp_get_link_cf', 9999999999, 2); function asp_get_link_cf( $url, $post ) { $data = get_post_meta($post->ID, 'thegem_quickfinder_item_data', true); if ( !empty($data) ) { $data = maybe_unserialize($data); if ( isset($data->link) ) { return $data->link; } } return $url; }This may not work, but should be close to a possible solution.
-
This topic was modified 5 years, 11 months ago by
-
AuthorPosts
- You must be logged in to reply to this topic.