How to return Custom text/DB values in a search
-
Hi, I wonder if anyone can help me please, I’m new to WordPress and I’ve been passed all over the place looking for support. On this, then where I get directed to they say it’s not them.
My Setup:
* I have a Synology WordPress site on my internal network
* I’m using the Theme “Organic Farm”
* I’m using the plugin “WP Recipe Manager” to store my recipes, this I believe using the database table “wp_postmeta” to store the information I want to display in my results, some being “wprm_nutrition_calories”, “wprm_total_time”, “wprm_cost” and “wprm_servings”
* I try using the plugin “Relevanssi”, and this enables for me the “excerpts” where the text of my recipes are displaying, but it just grabs the first parts of the page, including the “print” button label etc. (Do I need this??)My question is, how will I be able to get the text in my results to show the details I want as below, please?
———————————————-
Title (Clickable through to article) – (This is achieved by default)Picture (Clickable through to article) – (I achieved by editing the themes functions.php)
(I want to display the below)
Calories: %meta_value%
Time: %meta_value%
Servings: %meta_value%
Cost: %meta_value%
———————————————-At the moment I have achieved:
———————————————-
Title (Clickable through to article)Picture (Clickable through to article)
A snippet of a random part of Instructions (only shows if I enable “Create custom search result snippets” in the Relevanssi plugin)
———————————————-Any help would be much appreciated, please.
- The topic ‘How to return Custom text/DB values in a search’ is closed to new replies.