Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Radoslav Georgiev

    (@radogeorgiev)

    Hi Dreamwire,

    Ultimate Fields has an alternative of the_field() and it’s uf(). In your case, it would be <?php uf( ‘titel’ ) ?>, but this does not work for repeaters yet.

    For example, you can have a repeater with a single group (like ACF Repeater, not Flexible content). The group would be Person and the fields would be First Name (first_name) and Last Name(last_name). With Ultimate Fields, you will need something like this:

    <?php foreach( get_uf( 'people' ) as $person ): extract( $person ) ?>
    	<p><?php echo $last_name ?>, <?php echo $first_name ?></p>
    <?php endforeach ?>

    I’ve got an easier way on my list, I hope this works for you right now.

    Thread Starter SomebodyWithAName

    (@dreamwire)

    Hi Radoslav,

    Great, it works!

    I think i found a bug!:
    – I select a ‘File’ field.
    – Said to the Output Type – The URL of the file (it’s for a screenshot to show so i use it between the img tag in de HTML) <img src="<?php echo $screenshot ?>" alt="" />

    But i still get the ID of the image (with all the three options i get only the ID back)

    Plugin Author Radoslav Georgiev

    (@radogeorgiev)

    It’s not a bug I didn’t want to go deeper in the previous post, but a part of the whole issue is that repeater inner values don’t exactly get processed yet.

    Because of that, when you use that echo, the saved value is displayed. In this case, it’s the attachments’ ID.

    So for now, please change
    <img src="<?php echo $screenshot ?>" alt="" />
    to
    <?php echo wp_get_attachment_image( $screenshot, 'full' ) ?>

    Thread Starter SomebodyWithAName

    (@dreamwire)

    Thank you, it is working again. Now the whole repeater works like a charm!

    I hope you will update the plugin and stuff because i really digg it, good job!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How to implant?’ is closed to new replies.