• Resolved df50

    (@df50)


    I need to add an additional image field into events manager so that multiple images can be rendered on an event page. I couldn’t see a way to do this with Events Manager, so am using the Advanced Custom Fields plugin. I’ve been able to create the field and get the id of the image showing on the front end but not the actual image. I believe I have to amend the query for Events Manager to include get_field() to retrieve this field correctly, but am struggling to find where/which file to amend. Any help would be much appreciated

    Thanks

    https://www.ads-software.com/plugins/events-manager/

Viewing 8 replies - 1 through 8 (of 8 total)
  • Can you share the code you’re using at the moment?

    Thread Starter df50

    (@df50)

    No problem, at the moment, I haven’t amended any code, simply using the EM outputs

    For a SINGLE EVENT, I’m using the fields below being a mixture of the default ones and some custom fields. The SINGLE EVENT uses the featured image but need to display a different image when it comes to the EVENT LIST page.

    Using the events list shortcode and editing the settings in the EM admin, all I need the events list to do is return another custom field being #_ATT{whats_on_image}. At the moment it will simply return an ID and not the actual image. So doing some research, I could see that get_field was needed to be included in the query loop, but couldn’t quite figure out where to do for the event list output

    #_EVENTIMAGE
    #_EVENTNAME
    #_EVENTDATES
    Doors #_ATT{doors_open}
    Show #_ATT{show_time}
    Tickets #_ATT{cost}
    #_ATT{buy_tickets_link}
    #_EVENTNOTES

    Thread Starter df50

    (@df50)

    Hi @caimin_nwl

    I can provide admin access to the site if that would help?

    Plugin Support angelo_nwl

    (@angelo_nwl)

    to access your acf custom fields, maybe you can use placeholder like #_ATT{acf-field-name} eg. #_ATT{acf-image}, #_ATT{acf-featured_image}

    Thread Starter df50

    (@df50)

    Hi @angelo ,

    Thanks, but becauase the image field type in Advanced Custom Fields is being used, when i use #_ATT{whats_on_image} I simply get an id returned not the actual image that correlates to that id. From research i need to include a get_field call in the query, but not sure where to place this for the events list

    What’s stored in the field? The ID or something else?

    Did this issue was solved? I get the same ID from the image field.

    I have an ACF field ‘event_summ’
    but when I add it to my events list (at the bottom), it displays blank

    <?php
        echo do_shortcode('[events_list]
    		<div class="event-item">
    		{has_image}#_EVENTIMAGE{400, 300}{/has_image}
    		{no_image}<img src="/wp-content/themes/CMF/images/logo400x300v2.jpg" alt="cowbridge music festival"/>{/no_image}<br/>
    		<div class="concert">#_EVENTLINK<br/></div>
    		<div class="e-date">#_EVENTDATES,
    		#_EVENTTIMES<br/></div>
    
    		<div class="e-more"><a href="#_EVENTURL">More ></a></div>
    		<div class="conc-ex">#_ATT{event_summ}</div>
    		</div>
    		[/events_list]'); ?>
    <?php } ?>

    Am I missing something?

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Using Image field type with Events Manager’ is closed to new replies.