Creating a search with tag variable also added for more detailed results

Add a new input to the form, the name is key, you can easily access query vars that match a paremeter supporter by WP_Query using the function get_query_var. For example, you could try to generate an URL like this: http://example.com/?s=test&tag=5-personas,4-personas And with get_query_var(tag), you get the values, and the you create a custom WP_Query using … Read more

Replace code in plugin template

<?php $currentlang = get_bloginfo(‘language’); if($currentlang==”en-US”) $link_text=”All Products”; else $link_text=”Dummy Text”; ?> $return_string .= ‘<li class=”wpc-category ‘ . $class . ‘”><a href=”‘. get_option(‘catalogue_page_url’) .'”>’ . $link_text . ‘</a></li>’;

Pulling posts into static site (wordpress as subdirectory)

There are several ways to do it: SQL query to the wp database Using a Restfull API plugin: https://wordpress.org/plugins/json-api/ you will get the json of the posts. Using the RSS Feed (check this tutorial http://code.tutsplus.com/articles/how-to-read-an-rss-feed-with-php-screencast–net-1272) To be very light you can cache the results will all options. You can grab the results and cache that … Read more

Where should I put this custom data?

Supposing that each food item is treated as a post (perhaps even a custom post type), and the parameters (name/calories/etc.) are attributes of this post, you would do well to treat them as post meta fields. Various means exist to grant end-users the ability to maintain custom fields; my preferred option is Developer’s Custom Fields, … Read more

media-uploader insert into post is not inserting

I have found the solution with this change this $html=”<input id=”” . esc_attr( ‘eo_theme_options[‘ . $id . ‘]’ ) . ‘” to this $html=”<input id=”” . esc_attr( ‘eo_theme_options_’ . $id ) . ‘” and it worked, that do the trick