/** * Assign necessary Smarty variables and return a template name to * load in order to display image popup. * * @param int $index Index of image to display * * @return string Name of Smarty template file to display. * @access public */ public function getImagePopup($index) { global $interface; $tpl = parent::getImagePopup($index); if ($dates = $this->getResultDates()) { if ($dates[1] && $dates[1] != $dates[0]) { $interface->assign('dates', $dates[0] . '—' . $dates[1]); } else { $interface->assign('dates', $dates[0]); } } else { $interface->assign('dates', null); } return $tpl; }