loop inside loop stops working on the 2nd page and after

3 posts by 2 authors in: Forums > CMS Builder
Last Post: December 4, 2009   (RSS)

By yusuke - December 3, 2009

Please take a look and let me know what's going on.

At the below url, images are showing up properly as i planed.
http://milza.net/TEST/favoriteList.php

but the below url which is "next" page, images won't show up...
http://milza.net/TEST/favoriteList.php?page=2

In the above case, i used images but it doesn't have to be images.
i've attached files (favoriteList.php & favoriteDetail.php)

Please HELP!!
Attachments:

test.zip 4K

Re: [yusuke] loop inside loop stops working on the 2nd page and after

By Damon - December 3, 2009

Hi Yusuke ,

I took a look at your template. There is a lot of nested foreach loops which makes it tricky to follow.

The first thing I suggest is using this code:
<?php showme( $milmoRecords ); ?>
at the very bottom of your template to show you all the variable contents of $milmoRecords.

View the first page and the second page to see which variables are available.

The next step is to copy your favoriteList.php file, save as favoriteList2.php, for example, and strip down the code in it to only display the images and record names. This will make it easier to debug.

Give this a shot and let me know how you make out.
Cheers,
Damon Edis - interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/