Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Show rating in search results › Reply To: Show rating in search results
Hi Jaime,
..It is not a custom field which the user enters but more the score that different users give to a certain post (like reviews of a certain item?) I would like to show that score on the description text..
From the code you are trying to use just actually gets the value of the rating, nothing else. The get_post_meta() function is to get a custom field value.
However, from the screenshot, I see you have an error there. You cannot use any PHP code within those fields, so the line, where the rating is, should look like this:
[<p><strong>Rating: {ratings_average}</strong></p>]
..and it will print out the numeric value of the rating. Ajax Search Pro will automatically call the get_post_meta() function for the field within the {..} brackets.
Best,Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)