issue120, parse_user_friendly_url() did an unwanted session cleanup
[phpfspot.git] / phpfspot.class.php
index d2bb907009a9a29d98809247f7699b1aecb65425..54308aa25ca3e109e2e4d7c7ada4e958b72a1b44 100644 (file)
@@ -778,17 +778,10 @@ class PHPFSPOT {
                   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;
@@ -3119,14 +3112,14 @@ class PHPFSPOT {
    {
       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]);
                }
@@ -3186,6 +3179,7 @@ class PHPFSPOT {
       $this->resetTagSearch();
       $this->resetNameSearch();
       $this->resetDateSearch();
+      $this->resetTags();
 
    } // session_cleanup()