Index: /trunk/admin/include/functions.php
===================================================================
--- /trunk/admin/include/functions.php	(revision 2477)
+++ /trunk/admin/include/functions.php	(revision 2478)
@@ -357,4 +357,5 @@
         }
       }
+      closedir($contents);
     }
   }
@@ -1497,5 +1498,5 @@
 {
   global $page;
-  
+
   $tag_name = trim($tag_name);
   if (isset($page['tag_id_from_tag_name_cache'][$tag_name]))
@@ -1618,5 +1619,5 @@
   $query = 'OPTIMIZE TABLE '.implode(', ', $all_tables).';';
   $mysql_rc = $mysql_rc && pwg_query($query);
-  if ($mysql_rc) 
+  if ($mysql_rc)
   {
     array_push(
Index: /trunk/include/ws_core.inc.php
===================================================================
--- /trunk/include/ws_core.inc.php	(revision 2477)
+++ /trunk/include/ws_core.inc.php	(revision 2478)
@@ -345,10 +345,8 @@
   var $_responseFormat;
 
-  var $_methods;
-  var $_methodSignatures;
+  var $_methods = array();
 
   function PwgServer()
   {
-    $methods = array();
   }
 
@@ -436,7 +434,4 @@
   function addMethod($methodName, $callback, $params=array(), $description, $include_file='')
   {
-    $this->_methods[$methodName] = $callback;
-    $this->_methodDescriptions[$methodName] = $description;
-
     if (!is_array($params))
     {
@@ -470,5 +465,11 @@
       }
     }
-    $this->_methodSignatures[$methodName] = $params;
+
+    $this->_methods[$methodName] = array(
+      'callback'    => $callback,
+      'description' => $description,
+      'signature'   => $params,
+      'include'     => $include_file,
+      );
   }
 
@@ -480,5 +481,5 @@
   function getMethodDescription($methodName)
   {
-    $desc = @$this->_methodDescriptions[$methodName];
+    $desc = @$this->_methods[$methodName]['description'];
     return isset($desc) ? $desc : '';
   }
@@ -486,5 +487,5 @@
   function getMethodSignature($methodName)
   {
-    $signature = @$this->_methodSignatures[$methodName];
+    $signature = @$this->_methods[$methodName]['signature'];
     return isset($signature) ? $signature : array();
   }
@@ -518,7 +519,7 @@
   function invoke($methodName, $params)
   {
-    $callback = @$this->_methods[$methodName];
-
-    if ( $callback==null )
+    $method = @$this->_methods[$methodName];
+
+    if ( $method==null )
     {
       return new PwgError(WS_ERR_INVALID_METHOD, 'Method name "'.$methodName.'" is not valid');
@@ -526,5 +527,5 @@
 
     // parameter check and data coercion !
-    $signature = @$this->_methodSignatures[$methodName];
+    $signature = $method['signature'];
     $missing_params = array();
     foreach($signature as $name=>$options)
@@ -571,5 +572,9 @@
     if ( strtolower( get_class($result) )!='pwgerror')
     {
-      $result = call_user_func_array($callback, array($params, &$this) );
+      if ( !empty($method['include']) )
+      {
+        include_once( $method['include'] );
+      }
+      $result = call_user_func_array($method['callback'], array($params, &$this) );
     }
     return $result;
Index: /trunk/language/en_UK/common.lang.php
===================================================================
--- /trunk/language/en_UK/common.lang.php	(revision 2477)
+++ /trunk/language/en_UK/common.lang.php	(revision 2478)
@@ -311,5 +311,5 @@
 $lang['upload_advise_thumbnail'] = 'Optional, but recommended : choose a thumbnail to associate to ';
 $lang['upload_advise_width'] = 'the width of the picture must not exceed : ';
-$lang['upload_author'] = 'Author (eg "Pierrick LE GALL")';
+$lang['upload_author'] = 'Author';
 $lang['upload_cannot_upload'] = 'can\'t upload the picture on the server';
 $lang['upload_err_username'] = 'the username must be given';
Index: /trunk/language/nl_NL/common.lang.php
===================================================================
--- /trunk/language/nl_NL/common.lang.php	(revision 2477)
+++ /trunk/language/nl_NL/common.lang.php	(revision 2478)
@@ -311,5 +311,5 @@
 $lang['upload_advise_thumbnail'] = 'Optioneel, maar aanbevolen : kies een thumbnail voor associatie';
 $lang['upload_advise_width'] = 'de breedte van de afbeelding mag niet te groot zijn : ';
-$lang['upload_author'] = 'Auteur (eg "Pierrick LE GALL")';
+$lang['upload_author'] = 'Auteur';
 $lang['upload_cannot_upload'] = 'kan de afbeelding niet op de server plaatsen';
 $lang['upload_err_username'] = 'de gebruikersnaam moet ingevuld zijn';
Index: /trunk/tags.php
===================================================================
--- /trunk/tags.php	(revision 2477)
+++ /trunk/tags.php	(revision 2478)
@@ -68,11 +68,13 @@
 }
 
-$template->assign(
-  array(
-    'U_CLOUD' => get_root_url().'tags.php?display_mode=cloud',
-    'U_LETTERS' => get_root_url().'tags.php?display_mode=letters',
-    'display_mode' => $page['display_mode'],
-    )
-  );
+foreach (array('cloud', 'letters') as $mode)
+{
+  $template->assign(
+    'U_'.strtoupper($mode),
+    get_root_url().'tags.php'. ($conf['tags_default_display_mode']==$mode ? '' : '?display_mode='.$mode)
+    );
+}
+
+$template->assign( 'display_mode', $page['display_mode'] );
 
 // find all tags available for the current user
Index: /trunk/template/yoga/picture_nav_buttons.tpl
===================================================================
--- /trunk/template/yoga/picture_nav_buttons.tpl	(revision 2477)
+++ /trunk/template/yoga/picture_nav_buttons.tpl	(revision 2478)
@@ -3,59 +3,59 @@
   
 {if isset($last)}
-  <a class="navButton prev" href="{$last.U_IMG}" title="{'last_page'|@translate} : {$last.TITLE}" rel="last"><img src="{$ROOT_URL}{$themeconf.icon_dir}/last.png" class="button" alt="{'last_page'|@translate}"></a>
+  <a class="navButton" href="{$last.U_IMG}" title="{'last_page'|@translate} : {$last.TITLE}" rel="last"><img src="{$ROOT_URL}{$themeconf.icon_dir}/last.png" class="button" alt="{'last_page'|@translate}"></a>
 {else}
-  <a class="navButton prev"><img src="{$ROOT_URL}{$themeconf.icon_dir}/last_unactive.png" class="button" alt=""></a>
+  <a class="navButton"><img src="{$ROOT_URL}{$themeconf.icon_dir}/last_unactive.png" class="button" alt=""></a>
 {/if}
   
 {if isset($next)}
-  <a class="navButton next" href="{$next.U_IMG}" title="{'next_page'|@translate} : {$next.TITLE}" rel="next"><img src="{$ROOT_URL}{$themeconf.icon_dir}/right.png" class="button" alt="{'next_page'|@translate}"></a>
+  <a class="navButton" href="{$next.U_IMG}" title="{'next_page'|@translate} : {$next.TITLE}" rel="next"><img src="{$ROOT_URL}{$themeconf.icon_dir}/right.png" class="button" alt="{'next_page'|@translate}"></a>
 {else}
-  <a class="navButton next"><img src="{$ROOT_URL}{$themeconf.icon_dir}/right_unactive.png" class="button" alt=""></a>
+  <a class="navButton"><img src="{$ROOT_URL}{$themeconf.icon_dir}/right_unactive.png" class="button" alt=""></a>
 {/if}
 
 {if isset($slideshow.U_START_PLAY)}
-  <a class="navButton play" href="{$slideshow.U_START_PLAY}" title="{'start_play'|@translate}" rel="play"><img src="{$ROOT_URL}{$themeconf.icon_dir}/play.png" class="button" alt="{'start_play'|@translate}"></a>
+  <a class="navButton" href="{$slideshow.U_START_PLAY}" title="{'start_play'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/play.png" class="button" alt="{'start_play'|@translate}"></a>
 {/if}
 
 {if isset($slideshow.U_STOP_PLAY)}
-  <a class="navButton play" href="{$slideshow.U_STOP_PLAY}" title="{'stop_play'|@translate}" rel="play"><img src="{$ROOT_URL}{$themeconf.icon_dir}/pause.png" class="button" alt="{'stop_play'|@translate}"></a>
+  <a class="navButton" href="{$slideshow.U_STOP_PLAY}" title="{'stop_play'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/pause.png" class="button" alt="{'stop_play'|@translate}"></a>
 {/if}
 
 {if isset($U_UP) and !isset($slideshow)}
-  <a class="navButton up" href="{$U_UP}" title="{'thumbnails'|@translate}" rel="up"><img src="{$ROOT_URL}{$themeconf.icon_dir}/up.png" class="button" alt="{'thumbnails'|@translate}"></a>
+  <a class="navButton" href="{$U_UP}" title="{'thumbnails'|@translate}" rel="up"><img src="{$ROOT_URL}{$themeconf.icon_dir}/up.png" class="button" alt="{'thumbnails'|@translate}"></a>
 {/if}
   
 {if isset($previous)}
-  <a class="navButton prev" href="{$previous.U_IMG}" title="{'previous_page'|@translate} : {$previous.TITLE}" rel="prev"><img src="{$ROOT_URL}{$themeconf.icon_dir}/left.png" class="button" alt="{'previous_page'|@translate}"></a>
+  <a class="navButton" href="{$previous.U_IMG}" title="{'previous_page'|@translate} : {$previous.TITLE}" rel="prev"><img src="{$ROOT_URL}{$themeconf.icon_dir}/left.png" class="button" alt="{'previous_page'|@translate}"></a>
 {else}
-  <a class="navButton prev"><img src="{$ROOT_URL}{$themeconf.icon_dir}/left_unactive.png" class="button" alt=""></a>
+  <a class="navButton"><img src="{$ROOT_URL}{$themeconf.icon_dir}/left_unactive.png" class="button" alt=""></a>
 {/if}
   
 {if isset($first)}
-  <a class="navButton prev" href="{$first.U_IMG}" title="{'first_page'|@translate} : {$first.TITLE}" rel="first"><img src="{$ROOT_URL}{$themeconf.icon_dir}/first.png" class="button" alt="{'first_page'|@translate}"></a>
+  <a class="navButton" href="{$first.U_IMG}" title="{'first_page'|@translate} : {$first.TITLE}" rel="first"><img src="{$ROOT_URL}{$themeconf.icon_dir}/first.png" class="button" alt="{'first_page'|@translate}"></a>
 {else}
-  <a class="navButton prev"><img src="{$ROOT_URL}{$themeconf.icon_dir}/first_unactive.png" class="button" alt=""></a>
+  <a class="navButton"><img src="{$ROOT_URL}{$themeconf.icon_dir}/first_unactive.png" class="button" alt=""></a>
 {/if}
 
 
 {if isset($slideshow.U_START_REPEAT)}
-  <a class="navButton repeat" href="{$slideshow.U_START_REPEAT}" title="{'start_repeat'|@translate}" rel="repeat"><img src="{$ROOT_URL}{$themeconf.icon_dir}/start_repeat.png" class="button" alt="{'start_repeat'|@translate}"></a>
+  <a class="navButton" href="{$slideshow.U_START_REPEAT}" title="{'start_repeat'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/start_repeat.png" class="button" alt="{'start_repeat'|@translate}"></a>
 {/if}
 
 {if isset($slideshow.U_STOP_REPEAT)}
-  <a class="navButton repeat" href="{$slideshow.U_STOP_REPEAT}" title="{'stop_repeat'|@translate}" rel="repeat"><img src="{$ROOT_URL}{$themeconf.icon_dir}/stop_repeat.png" class="button" alt="{'stop_repeat'|@translate}"></a>
+  <a class="navButton" href="{$slideshow.U_STOP_REPEAT}" title="{'stop_repeat'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/stop_repeat.png" class="button" alt="{'stop_repeat'|@translate}"></a>
 {/if}
 
 {if isset($slideshow)}
   {if isset($slideshow.U_DEC_PERIOD)}
-    <a class="navButton dec_period" href="{$slideshow.U_DEC_PERIOD}" title="{'dec_period'|@translate}" rel="repeat"><img src="{$ROOT_URL}{$themeconf.icon_dir}/dec_period.png" class="button" alt="{'dec_period'|@translate}"></a>
+    <a class="navButton" href="{$slideshow.U_DEC_PERIOD}" title="{'dec_period'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/dec_period.png" class="button" alt="{'dec_period'|@translate}"></a>
   {else}
-    <a class="navButton dec_period"> <img src="{$ROOT_URL}{$themeconf.icon_dir}/dec_period_unactive.png" class="button" alt=""></a>
+    <a class="navButton"> <img src="{$ROOT_URL}{$themeconf.icon_dir}/dec_period_unactive.png" class="button" alt=""></a>
   {/if}
 
   {if isset($slideshow.U_INC_PERIOD)}
-    <a class="navButton inc_period" href="{$slideshow.U_INC_PERIOD}" title="{'inc_period'|@translate}" rel="repeat"><img src="{$ROOT_URL}{$themeconf.icon_dir}/inc_period.png" class="button" alt="{'inc_period'|@translate}"></a>
+    <a class="navButton" href="{$slideshow.U_INC_PERIOD}" title="{'inc_period'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/inc_period.png" class="button" alt="{'inc_period'|@translate}"></a>
   {else}
-    <a class="navButton inc_period"> <img src="{$ROOT_URL}{$themeconf.icon_dir}/inc_period_unactive.png" class="button" alt=""></a>
+    <a class="navButton"> <img src="{$ROOT_URL}{$themeconf.icon_dir}/inc_period_unactive.png" class="button" alt=""></a>
   {/if}
 {/if}
