got it, created two snippets each with php code to randomize the output of an image from a set of images in folder like this:
<?php
// images named 1.jpg, 2.jpg etc
// total number of images in the folder
$total = "11";
// type of image file eg. .jpg or .gif
$file_type = ".jpg";
// location of folder containing images
$image_folder = "assets/templates/your_template/images/name_of_folder_containing_your_images";
$start = "1";
$random = mt_rand($start, $total);
$image_name = $random . $file_type;
echo "<img src=\"$image_folder/$image_name\" alt=\"$image_name\" />";
?>
of course for each snippet changed the name of the folder with the images i.e. folder one for one page and folder two for page two for example [[randomimage1]] and [[randomimage2]]
next I created a new snippet [[ifsnippet]]using this:
<?php
$id = $modx->documentObject['id'];
if ($id=="33")
$output="{{firstchunk}}";
elseif ($id=="32")
$output="{{secondchunk}}";
else
$output="{{firstchunk}}";
return "$output";
?>
noticed I put the pages id....I then created two chunks the first and second chunk referenced above like this:
<div class="photo" id="photo">[[randomimage1]]</div>
notice that it calls the actual snippet that changes images of one folder.
then FINALLY I CREATED A TV [*subheaderimages*]
and put the [[!ifsnippet!]]
as its default value, assigned it to one template and then assigned that template to two separate pages which were exactly the same except for the images there were to display randomly.
pheeeeew! seems like a lot of work, there has to be a better way, but it works now I can rid myself of different templates just for the need of one single change in the element....and I know for a fact that if I was a php guru I would be able to combine both the if snippet and random snippet and half my headaches would be over, but I just don’t have the mind to be that level of a coder, I just paint pretty pictures
modx forums definitely needs not just a newbie area but an area that holds designer’s hands and puts things in layman’s terms