• Resolved berttervoert

    (@berttervoert)


    Hi @jori,

    I have a pod with a image upload field that allows for 5 images to be uploaded. I created a template for this pod which is working fine expect the multiple image part. I uploaded 2 images to the pod, but the template only outputs one. I checked the html being output with the element inspector (firefox developer) and found that the div for the image <div class="wdtv_route-foto"> is output twice, but the first one is empty. The template part I use is:

    	[if fotos]
    		<div class="wdtv_route-row-container clear">
    			<p>Foto's van de route:</p>
    			[each fotos]
    				<div class="wdtv_route-foto">
    					{@fotos._img.thumbnail}
    				</div>
    			[/each]
    		</div>
    	[/if]

    If needed, I can post the entire template. Do you have any ideas why the first div is empty?

    i have another question about the images:
    – is it possible to display the thumbnail as a link to the image in full size? So when you click on the thumbnail, the full size image gets shown.

    Thanks in advance,
    Bert

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

    (@berttervoert)

    add:

    I’ve tried it with three images. Result: First div empty like before and then the first images is shown twice. So, looks like I made a mistake in the [each][/each] section.

    Thread Starter berttervoert

    (@berttervoert)

    Hi @jori,

    after searching around some more, I found the solution for the problem:

    instead of {@fotos._img.thumbnail} I use {_img.thumbnail}. Now all images are shown. Must have been to late yesterday, to long staring at it.

    Thanks,
    Bert.

    Plugin Author Jory Hogeveen

    (@keraweb)

    Hello @berttervoert

    Correct, good to hear you’ve solved it!

    Cheers, Jory

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Showing multiple images in pods template’ is closed to new replies.