/** * Builds a list of all additional images * * @param int $product_id * @param array $images * @return string */ function vmlistAdditionalImages($product_id, $images, $title = '', $limit = 1000) { global $sess; $html = ''; $i = 0; foreach ($images as $image) { $thumbtag = ps_product::image_tag($image->file_name, 'class="browseProductImage"', 1, 'product', $image->file_image_thumb_width, $image->file_image_thumb_height); $fulladdress = $sess->url('index2.php?page=shop.view_images&image_id=' . $image->file_id . '&product_id=' . $product_id . '&pop=1'); if ($this->get_cfg('useLightBoxImages', 1)) { $html .= vmCommonHTML::getLightboxImageLink($image->file_url, $thumbtag, $title ? $title : stripslashes(htmlentities($image->file_title, ENT_QUOTES)), 'product' . $product_id); } else { $html .= vmPopupLink($fulladdress, $thumbtag, 640, 550); } $html .= ' '; if (++$i > $limit) { break; } } return $html; }