ACF under category name in shop page [closed]

If i understand you correctly here you want to display some text under each of the category titles on your shop page. Instead of editing the template i would suggest using a hook. To do this you should move your code into functions.php. The complete code would look something like this: add_action(‘woocommerce_after_subcategory_title’, ‘wpse_add_custom_text_under_category_title’, 10); function … Read more

edit.php all post not working

finally found the solution when i enter all the custom post status to public it declare the post_type to default post as global so applied filter to change the global post_type based what type request get in URL function publishPress_allPost_pre_get_posts( &$wp_query ) { if ( is_admin() && array_key_exists( ‘post_type’, $_GET ) ) { $wp_query->set( ‘post_type’, … Read more

How to access custom post meta data from JavaScript

Your script should looks like this. function js_enqueue_scripts() { global $post; $text2 = get_post_meta( $post->ID, ‘_load_speed_field’, true ); $text3 = get_post_meta( $post->ID, ‘_tyre_brand_field’, true ); $text4 = get_post_meta( $post->ID, ‘_brand_model_field’, true ); $text5 = get_post_meta( $post->ID, ‘_run_flat_field’, true ); //Put your variables inside a array $arrayname = array( ‘text3’ => $text3, ‘text2’ => $text2 ); … Read more