if(isset($_SESSION['begin_with']) && $this->cfg->thumbs_per_page == 0)
unset($_SESSION['begin_with']);
+ // if user-friendly-url's are enabled, set also a flag for the template handler
+ if($this->is_user_friendly_url()) {
+ $this->tmpl->assign('user_friendly_url', 'true');
+ }
+
} // __construct()
public function __destruct()
$this->tmpl->assign('current_img', $photo);
if($previous_img) {
- $this->tmpl->assign('previous_url', "javascript:showImage(". $previous_img .");");
+ $this->tmpl->assign('previous_url', "javascript:showPhoto(". $previous_img .");");
$this->tmpl->assign('prev_img', $previous_img);
}
if($next_img) {
- $this->tmpl->assign('next_url', "javascript:showImage(". $next_img .");");
+ $this->tmpl->assign('next_url', "javascript:showPhoto(". $next_img .");");
$this->tmpl->assign('next_img', $next_img);
}
$this->tmpl->assign('mini_width', $this->cfg->mini_width);
break;
case 'img':
$output.= "
- <div style=\"display: table-cell;\">
- <div style=\"display: table-row; text-align: center;\">
- <a href=\"javascript:Tags('del', ". $tag .");\" title=\"". $this->tags[$tag] ."\">
- <img src=\"". $this->cfg->web_path ."/phpfspot_img.php?tagidx=". $tag ."\" />
- </a>
- </div>
- <div style=\"display: table-row; text-align: center;\">
- <a href=\"javascript:Tags('del', ". $tag .");\" title=\"". $this->tags[$tag] ."\">
- <img src=\"". $this->cfg->web_path ."/resources/underbar.png\" />
- </a>
- </div>
+ <div class=\"tagresulttag\">
+ <a href=\"javascript:Tags('del', ". $tag .");\" title=\"". $this->tags[$tag] ."\">
+ <img src=\"". $this->cfg->web_path ."/phpfspot_img.php?tagidx=". $tag ."\" />
+ </a>
</div>
";
break;
} // resetTags()
/**
- * returns the value for the autocomplet tag-search
+ * returns the value for the autocomplete tag-search
* @return string
*/
public function get_xml_tag_list()
{
if(preg_match('/\/photoview\/|\/photo\/|\/tag\//', $request_uri)) {
- unset($_SESSION['start_action']);
- unset($_SESSION['selected_tags']);
-
$options = explode('/', $request_uri);
switch($options[1]) {
case 'photoview':
if(is_numeric($options[2])) {
+ $this->session_cleanup();
+ //unset($_SESSION['start_action']);
+ //unset($_SESSION['selected_tags']);
$_GET['mode'] = 'showp';
return $this->showPhoto($options[2]);
}
$this->resetTagSearch();
$this->resetNameSearch();
$this->resetDateSearch();
+ $this->resetTags();
} // session_cleanup()