Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Show author name in search results
- This topic has 3 replies, 2 voices, and was last updated 9 years, 11 months ago by
Ernest Marcinko.
-
AuthorPosts
-
July 8, 2016 at 5:02 am #9433
Jimtowner
ParticipantMy search results show the name Steve (my WP login name) and not the name of the author associated with a post. For example is post titled Test 2 has author Bob Jones on http://www.jamestownspeaks.org/pages/jimflix/. A search on “short” lists Test 2 but the name Steve is displayed. Is there a way to have author name displayed?
Also, when I search on the title “Test 2” I get no results instead of the Test 2 result. Why would that be?
Thanks.
July 8, 2016 at 10:25 am #9449Ernest Marcinko
KeymasterHi Jim!
The “test 2” issue was related to the fact that the index table engine does not index words below the length of 3 by default. It most cases that is optimal, but in yours it might not be the best option. I’ve changed the minimal word length to 1 on the index table options panel and re-created the index table: http://i.imgur.com/SByLmvO.png
Now it should return the correct result.I’m guessing when a user submits a post, it’s still stored as if your account was the author, and the real author is stored within a custom field. When the search requests the author, wordpress returns your name.
Luckily there is a way to get around that. I’ve put together a quick code snippet for you to get the author name from the custom field.:You can put this code into the functions.php file in your active theme directory. I hope it will work.
July 9, 2016 at 2:35 am #9455Jimtowner
ParticipantThat works. Thank you!!
In another response you invited me to summit a review which I would like to do. Should I do that on your WP plugin page or elsewhere. The reason I ask is that I would like to comment (positively) on the pro version but the WP page is for the free version.
July 9, 2016 at 8:08 am #9457Ernest Marcinko
KeymasterYou are welcome!
You can do that here on the codecanyon item page: https://codecanyon.net/item/ajax-search-pro-for-wordpress-live-search-plugin/3357410
By clicking on the stars on the sidebar (by the Rate the item text) I think it should bring up a dialog, where you can enter a text as well.Or on your codecanyon downloads page: https://codecanyon.net/downloads
Similarly, there should be a list there of your purchased products, and clicking on the stars should bring up the same dialog.The WP plugin page only stands for the free version, which is a different plugin 🙂
-
AuthorPosts
- You must be logged in to reply to this topic.