• Post your working code snippets here, so that Eliot or Peter Berger doesn’t have to respond to everything!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter dmunaretto

    (@dmunaretto)

    Use: This passes an agent ID from the field property_agent on a page with post type PROPERTY and returns data from the custom post type AGENT-

    [pass field=property_agent]
    Agent Email:
    [loop type=agent id={FIELD}]
    [content type=agent field=agent_email]
    [/loop]
    [/pass]

    Thread Starter dmunaretto

    (@dmunaretto)

    This returns the list of all items within a taxonomy – In my case it returns a list of all cities within the taxonomy city:

    [for each=property-city]
    [each name]
    [/for]

    Thread Starter dmunaretto

    (@dmunaretto)

    I use this code to change the header based of a widget based on the property type –

    [if field=acf_property_type value=”Land”]
    Vacant Land
    [/if]

    [if field=acf_property_type value=”Single Family”]
    Single Family
    [/if]

    [if field=acf_property_type value=”Rental”]
    Rental Properties
    [/if]

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WORKING CODE SNIPPETS’ is closed to new replies.