use with class file into wp_ajax hook

Use include (yourclass.php) only if the file yourclass.php is on the same folder. Otherwise you will need to put the full path to your file or use a variable for the plugin path: public $plugin_path; $this->plugin_path = plugin_dir_path( dirname( dirname( FILE ) ) ); and include the file using plugin_path.

How to change the structure/order of sections in a WordPress theme? [closed]

I’m looking at the free version. The relevant code is in inc/extras.php, and it looks like there are filters to enable / disable sections (business_one_page_ed_<section>_section) and to change the titles of sections (business_one_page_<section>_section_menu_title), but not reorder them: function business_one_page_get_sections(){ $sections = array( ‘about’, ‘services’, ‘cta1’, ‘portfolio’, ‘team’, ‘clients’, ‘blog’, ‘testimonial’, ‘cta2’, ‘contact’ ); $enabled_section = … Read more

Import Instagram post as WordPress post

Install the Instagram feed plugin Set up the plugin, go to plugin list, then under instagram feed press settings and set it up. To customize it, use customize bar Go to display feed bar, and copy then [instagram feed] code go on wordpress editor, press add block and search for shortcode Paste the copied code … Read more

form submission reverts to index.php template

I did some testing locally with your code. I think the problem is your form input names clashing with names reserved by WP. Also redirecting to success/error page should happen before get_header() to avoid any headers sent errors. So, add some prefix/suffix to your input names, like so <input type=”text” name=”my-name” placeholder=”Your Name” class=”input” id=”name” … Read more

Search for single post by 2 tags

Using the tax_query param in your args (and replacing the dot with a comma) should get you what you’re looking for: $args = array( ‘tax_query’ => array( ‘relation’ => ‘AND’, array( ‘taxonomy’ => ‘post_tag’, ‘field’ => ‘slug’, ‘terms’ => ‘fetch’, ), array( ‘taxonomy’ => ‘post_tag’, ‘field’ => ‘slug’, ‘terms’ => ‘agirt’, ) ) );