Support

Account

Home Forums Front-end Issues wp localize script and jquery Reply To: wp localize script and jquery

  • Perhaps this is not the case. The first message shows that you created a field for a specific post. If you are trying to access this field from another template, then you need to use additionally the id of this post.

    in post
    <h4>Somme text: <?php the_field('custom_filed'); ?></h4>

    outside this post
    <h4>Somme text: <?php the_field('custom_filed', $post_id); ?></h4>

    e.g.
    <h4>Somme text: <?php the_field('custom_filed', 10); ?></h4> where 10 is ID of post