Index: /extensions/UserCollections/include/events.inc.php
===================================================================
--- /extensions/UserCollections/include/events.inc.php	(revision 16697)
+++ /extensions/UserCollections/include/events.inc.php	(revision 16698)
@@ -89,5 +89,6 @@
   
   // get existing collections
-  if (empty($UserCollection) and ($col_id = get_current_collection_id(false)) !== false)
+  $col_id = get_current_collection_id(false);
+  if (empty($UserCollection) and $col_id !== false)
   {
     $UserCollection = new UserCollection($col_id);
@@ -101,4 +102,10 @@
   {
     $collection = array();
+  }
+  
+  // if the collection is created we don't use AJAX to force menu refresh
+  if ($col_id === false)
+  {
+    $template->assign('NO_AJAX', true);
   }
   
@@ -196,19 +203,7 @@
   if (is_a_guest()) return;
   
-  global $user;
-  
   $menu = &$menu_ref_arr[0];
   if ($menu->get_id() != 'menubar') return;
-  
-  $query = '
-SELECT id
-  FROM '.COLLECTIONS_TABLE.'
-  WHERE user_id = '.$user['id'].'
-  LIMIT 1
-;';
-  $result = pwg_query($query);
-  
-  if (!pwg_db_num_rows($result)) return;
-  
+    
   $menu->register_block(new RegisteredBlock('mbUserCollection', l10n('Collections'), 'UserCollection'));
 }
Index: /extensions/UserCollections/language/en_UK/plugin.lang.php
===================================================================
--- /extensions/UserCollections/language/en_UK/plugin.lang.php	(revision 16697)
+++ /extensions/UserCollections/language/en_UK/plugin.lang.php	(revision 16698)
@@ -4,5 +4,5 @@
 $lang['Public collection'] = 'Public';
 $lang['Copy to clipboard'] = 'Copy to clipboard';
-$lang['Return to collections list'] = 'Return to collections list';
+$lang['Return to collections list'] = 'Return to list';
 $lang['This collection is empty'] = 'This collection is empty';
 $lang['Collection name:'] = 'Collection name:';
@@ -21,4 +21,6 @@
 $lang['Add to collection'] = 'Add to collection';
 $lang['Clear collection'] = 'Clear';
+$lang['You have %d collection'] = 'You have %d collection';
+$lang['You have no collection'] = 'You have no collection';
 $lang['You have %d collections'] = 'You have %d collections';
 $lang['active'] = 'active';
Index: /extensions/UserCollections/language/fr_FR/plugin.lang.php
===================================================================
--- /extensions/UserCollections/language/fr_FR/plugin.lang.php	(revision 16697)
+++ /extensions/UserCollections/language/fr_FR/plugin.lang.php	(revision 16698)
@@ -21,4 +21,6 @@
 $lang['Add to collection'] = 'Ajouter à la collection';
 $lang['Clear collection'] = 'Vider';
+$lang['You have %d collection'] = 'Vous avez %d collection';
+$lang['You have no collection'] = 'Vous n\'avez aucune collection';
 $lang['You have %d collections'] = 'Vous avez %d collections';
 $lang['active'] = 'active';
Index: /extensions/UserCollections/template/edit.tpl
===================================================================
--- /extensions/UserCollections/template/edit.tpl	(revision 16697)
+++ /extensions/UserCollections/template/edit.tpl	(revision 16698)
@@ -77,4 +77,10 @@
 
 
+<form id="actions" style="text-align:center;">
+<input type="submit" data-href="{$collection.U_CLEAR}" value="{'Clear collection'|@translate}">
+<input type="submit" data-href="{$collection.U_DELETE}" value="{'Delete'|@translate}">
+</form>
+
+
 {if $collection.NB_IMAGES > 0}
 <ul class="thumbnails" id="thumbnails">
@@ -86,10 +92,4 @@
 
 {if !empty($navbar)}{include file='navigation_bar.tpl'|@get_extent:'navbar'}{/if}
-
-
-<form id="actions" style="text-align:center;">
-<input type="submit" data-href="{$collection.U_CLEAR}" value="{'Clear collection'|@translate}">
-<input type="submit" data-href="{$collection.U_DELETE}" value="{'Delete'|@translate}">
-</form>
 {/if}
 
Index: /extensions/UserCollections/template/menublock_user_collec.tpl
===================================================================
--- /extensions/UserCollections/template/menublock_user_collec.tpl	(revision 16697)
+++ /extensions/UserCollections/template/menublock_user_collec.tpl	(revision 16698)
@@ -1,5 +1,10 @@
 <dt>{$block->get_title()}</dt>
 <dd>
-  <p><a href="{$block->data.U_LIST}">{'You have %d collections'|@translate|sprintf:$block->data.NB_COL}</a></p>
+  <p>
+    {if $block->data.NB_COL == 0}
+      {'You have no collection'|@translate|sprintf:$block->data.NB_COL}
+    {else}
+      <a href="{$block->data.U_LIST}">{$pwg->l10n_dec('You have %d collection', 'You have %d collections', $block->data.NB_COL)}</a>
+    {/if}</p>
   {if $block->data.collections}
   <ul>{strip}
Index: /extensions/UserCollections/template/thumbnails_css_js.tpl
===================================================================
--- /extensions/UserCollections/template/thumbnails_css_js.tpl	(revision 16697)
+++ /extensions/UserCollections/template/thumbnails_css_js.tpl	(revision 16698)
@@ -5,4 +5,5 @@
 {/html_style}
 
+{if not $NO_AJAX}
 {footer_script require='jquery'}
 jQuery(".addCollection").click(function() {ldelim}
@@ -21,4 +22,5 @@
     {if $COL_ID}
       $trigger.parent(".wrap1").hide("fast", function() {ldelim} $trigger.remove() });
+      if (typeof batchdown_count != 'undefined') batchdown_count-=1;
     {else}
       $trigger.html('{'Add to collection'|@translate}&nbsp;<img src="{$USER_COLLEC_PATH}template/image_add.png" title="{'Add to collection'|@translate}">');
@@ -33,2 +35,3 @@
 });
 {/footer_script}
+{/if}
