hi there,
whenever i do a search it will display the text "Sorry, no image matches. Try refining your search." even when image matches do come up.
the search actually works fine - it's just i can't figure out how to get rid of this text when search gives positive results.
i am using zenphoto 1.4.0.1.
my code looks like this:
`
<?php if (($total = getNumImages() + getNumAlbums()) > 0) {
if ($_REQUEST['date']){ $searchwords = getSearchDate();
} else { $searchwords = getSearchWords(); }
echo "
Total matches for ".$searchwords.": $total
"; } $c = 0; ?>
<?php if ($c == 0) { echo "<p>Sorry, no image matches. Try refining your search."; } ?>
`
i have read the theme tutorial & have done a search on google and the zenphoto support forum & could not find anything to help me...
http://pennystewartdesigns.com/merrepen/gallerypositive search result would be to search "emu" for example. negative search would be "Jamaica".
Comments
Do you see $c++ in the album or image loops?
my album & image loops on search.php look like this:
`
<?php while (next_album()): ?>
title="<?php echo getAlbumTitle();?>">
<?php printAlbumThumbImage(getAlbumTitle()); ?>
"
title="<?php echo getAlbumTitle();?>">
<?php printAlbumTitle(true); ?>
<?php while (next_image(false, $firstPageImages)): ?>
"
title="<?php echo getImageTitle();?>">
<?php printImageThumb(getImageTitle()); ?>
`
where do i put this $c?
<?php while (next_album()): $c++; ?>
`
and
`
<?php while (next_image(false, $firstPageImages)): $c++; ?>
`
and make sure your "no results" code is below these two loops.