MIGX randomize not working with pthumb

I am using getPage to get an overview of pages from which the parent that have a migx image gallery.

In the chunk that contains the overview I have this code:
[[getImageList? &docid=[[+parent]] &limit=1 &randomize=1 &tvname=werkgever_fotogalerij &tpl=gr.vacatureImgOverview]]

The image that I load from the gallery in the chunk gr.vacatureImgOverview is:

The problem is that on the overview page it always loads the same images for every item.

Is there something I am missing?

Does it work if you call the snippet uncached (with a ![[!...]]) ?

Hi thanks for helping out. It did not work, I added it to the MIGX and pThumb

Can you maybe supply the whole code you’re using to output the images?
(For example from what you posted above, it’s unclear where and how pThumb is even used.)

Also, does it work correctly, if you output the images without using pThumb?


First of all it also does not work without pthumb.

This is the code that I use in the overview page:

&totalVar=resultaten ]]

&else=<div class="col-12 pt-2 [[*werkgever_video:notempty=pb-5]]">[[$[[++oops_no_results_chunk]]]]</div>

In the tpl (gr.vacatures2023) I call the random image like this:

[[getImageList? &docid=[[+parent]] &limit=1 &randomize=1 &tvname=werkgever_fotogalerij &tpl=gr.vacatureImgOverview]]

The tpl gr.vacatureImgOverview contains this code (I have added a space before img because otherwise it is not displayed well in this editor):

< img class=“w-100 h-auto” src=“[[!pthumb? &input=[[+werkgever_fotogalerij_afbeelding]] &options=w=696&h=460&aoe=1&zc=1]]” alt=“[[+pagetitle:htmlent]]”>

If you could edit your post and put all your code in code blocks, that would be helpful (and show all the back-ticks).
For a code block, put lines with three back-ticks at the start and at the end of your code.

```//line with 3 back-ticks at the beginning
//your code here
```//line with 3 back-ticks at the end

Also, try calling “getImageList” uncached → [[!getImageList?

you will need to call getImageList uncached and you need a unique snippet call each time, so try:


otherwise, you will allways get the result from the first call