Post Custom Field Data

Home Forums MapPress Support Post Custom Field Data

Tagged: ,

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #11445
    thedudem4n
    Participant

      So I have each of my locations as individual posts and I am able to mashup my posts very well using the meta field types, however, I am running into trouble displaying the meta information on the actual pages.

      I tried for example $poi->get_post_meta($post->ID, 'post-class', true);

      But that just threw tons of ajax errors. How do I go about getting the contents of the customfield types to display with the poi content?

      Any help is appreciated.

      #11448
      Chris
      Keymaster

        Hi,

        There’s no ‘get_post_meta’ method for POIs, that’s a WordPress function.  You can see the POI methods in file ‘mappress_poi.php’.  There are several ways to do what you want, but I think the easiest is to use:

        $poi->get_custom('post-class', true);

        If that doesn’t help please send me a note with the contact form, in case I need to ask for a copy of your template.

      Viewing 2 posts - 1 through 2 (of 2 total)
      • You must be logged in to reply to this topic.