Index: /extensions/floPure/index.tpl
===================================================================
--- /extensions/floPure/index.tpl	(revision 3676)
+++ /extensions/floPure/index.tpl	(revision 3677)
@@ -12,69 +12,69 @@
       <td id="section_left">&nbsp;</td>
       <td id="section_in">
-  <div class="titrePage">
-    <ul class="categoryActions">
-      {if !empty($image_orders) }
-      <li>
-      {'Sort order'|@translate}:
-      <select onchange="document.location = this.options[this.selectedIndex].value;">
-        {foreach from=$image_orders item=image_order }
-        <option value="{$image_order.URL}"{if $image_order.SELECTED} selected="selected"{/if}>{$image_order.DISPLAY}</option>
-        {/foreach}
-      </select>
-      </li>
-      {/if}
-
-      {if isset($U_CADDIE) }
-      <li><a href="{$U_CADDIE}" title="{'add to caddie'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/caddie_add.png" class="button" alt="{'caddie'|@translate}"/></a></li>
-      {/if}
-
-      {if isset($U_EDIT) }
-      <li><a href="{$U_EDIT}" title="{'edit category informations'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/category_edit.png" class="button" alt="{'edit'|@translate}"/></a></li>
-      {/if}
-
-      {if isset($U_SEARCH_RULES) }
-      <li><a href="{$U_SEARCH_RULES}" onclick="popuphelp(this.href); return false;" title="{'Search rules'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/search_rules.png" class="button" alt="(?)" /></a></li>
-      {/if}
-
-      {if isset($U_SLIDESHOW) }
-      <li><a href="{$U_SLIDESHOW}" title="{'slideshow'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/start_slideshow.png" class="button" alt="{'slideshow'|@translate}"/></a></li>
-      {/if}
-
-      {if isset($U_MODE_FLAT) }
-      <li><a href="{$U_MODE_FLAT}" title="{'mode_flat_hint'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/flat.png" class="button" alt="{'mode_flat_hint'|@translate}" /></a></li>
-      {/if}
-
-      {if isset($U_MODE_NORMAL) }
-      <li><a href="{$U_MODE_NORMAL}" title="{'mode_normal_hint'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/normal_mode.png" class="button" alt="{'mode_normal_hint'|@translate}" /></a></li>
-      {/if}
-
-      {if isset($U_MODE_POSTED) }
-      <li><a href="{$U_MODE_POSTED}" title="{'mode_posted_hint'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/calendar.png" class="button" alt="{'mode_posted_hint'|@translate}" /></a></li>
-      {/if}
-      
-      {if isset($U_MODE_CREATED) }
-      <li><a href="{$U_MODE_CREATED}" title="{'mode_created_hint'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/calendar_created.png" class="button" alt="{'mode_created_hint'|@translate}" /></a></li>
-      {/if}
-      
-      {if !empty($PLUGIN_INDEX_ACTIONS)}{$PLUGIN_INDEX_ACTIONS}{/if}
-    </ul>
-
-  <h2>{$TITLE}</h2>
-
-  {if isset($chronology_views) }
-  <div class="calendarViews">{'calendar_view'|@translate}:
-    <select onchange="document.location = this.options[this.selectedIndex].value;">
-      {foreach from=$chronology_views item=view}
-      <option value="{$view.VALUE}"{if $view.SELECTED} selected="selected"{/if}>{$view.CONTENT}</option>
-      {/foreach}
-    </select>
-  </div>
-  {/if}
-
-  {if isset($chronology.TITLE) }
-  <h2>{$chronology.TITLE}</h2>
-  {/if}
-
-  </div> <!-- titrePage -->
+	  <div class="titrePage">
+		<ul class="categoryActions">
+		  {if !empty($image_orders) }
+		  <li>
+		  {'Sort order'|@translate}:
+		  <select onchange="document.location = this.options[this.selectedIndex].value;">
+			{foreach from=$image_orders item=image_order }
+			<option value="{$image_order.URL}"{if $image_order.SELECTED} selected="selected"{/if}>{$image_order.DISPLAY}</option>
+			{/foreach}
+		  </select>
+		  </li>
+		  {/if}
+	
+		  {if isset($U_CADDIE) }
+		  <li><a href="{$U_CADDIE}" title="{'add to caddie'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/caddie_add.png" class="button" alt="{'caddie'|@translate}"/></a></li>
+		  {/if}
+	
+		  {if isset($U_EDIT) }
+		  <li><a href="{$U_EDIT}" title="{'edit category informations'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/category_edit.png" class="button" alt="{'edit'|@translate}"/></a></li>
+		  {/if}
+	
+		  {if isset($U_SEARCH_RULES) }
+		  <li><a href="{$U_SEARCH_RULES}" onclick="popuphelp(this.href); return false;" title="{'Search rules'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/search_rules.png" class="button" alt="(?)" /></a></li>
+		  {/if}
+	
+		  {if isset($U_SLIDESHOW) }
+		  <li><a href="{$U_SLIDESHOW}" title="{'slideshow'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/start_slideshow.png" class="button" alt="{'slideshow'|@translate}"/></a></li>
+		  {/if}
+	
+		  {if isset($U_MODE_FLAT) }
+		  <li><a href="{$U_MODE_FLAT}" title="{'mode_flat_hint'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/flat.png" class="button" alt="{'mode_flat_hint'|@translate}" /></a></li>
+		  {/if}
+	
+		  {if isset($U_MODE_NORMAL) }
+		  <li><a href="{$U_MODE_NORMAL}" title="{'mode_normal_hint'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/normal_mode.png" class="button" alt="{'mode_normal_hint'|@translate}" /></a></li>
+		  {/if}
+	
+		  {if isset($U_MODE_POSTED) }
+		  <li><a href="{$U_MODE_POSTED}" title="{'mode_posted_hint'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/calendar.png" class="button" alt="{'mode_posted_hint'|@translate}" /></a></li>
+		  {/if}
+		  
+		  {if isset($U_MODE_CREATED) }
+		  <li><a href="{$U_MODE_CREATED}" title="{'mode_created_hint'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/calendar_created.png" class="button" alt="{'mode_created_hint'|@translate}" /></a></li>
+		  {/if}
+		  
+		  {if !empty($PLUGIN_INDEX_ACTIONS)}{$PLUGIN_INDEX_ACTIONS}{/if}
+		</ul>
+	
+	  <h2>{$TITLE}</h2>
+	
+	  {if isset($chronology_views) }
+	  <div class="calendarViews">{'calendar_view'|@translate}:
+		<select onchange="document.location = this.options[this.selectedIndex].value;">
+		  {foreach from=$chronology_views item=view}
+		  <option value="{$view.VALUE}"{if $view.SELECTED} selected="selected"{/if}>{$view.CONTENT}</option>
+		  {/foreach}
+		</select>
+	  </div>
+	  {/if}
+	
+	  {if isset($chronology.TITLE) }
+	  <h2>{$chronology.TITLE}</h2>
+	  {/if}
+	
+	  </div> <!-- titrePage -->
 
 {if !empty($PLUGIN_INDEX_CONTENT_BEGIN)}{$PLUGIN_INDEX_CONTENT_BEGIN}{/if}
Index: /extensions/floPure/theme/neon/index.php
===================================================================
--- /extensions/floPure/theme/neon/index.php	(revision 3677)
+++ /extensions/floPure/theme/neon/index.php	(revision 3677)
@@ -0,0 +1,33 @@
+<?php
+// +-----------------------------------------------------------------------+
+// | PhpWebGallery - a PHP based picture gallery                           |
+// | Copyright (C) 2002-2003 Pierrick LE GALL - pierrick@phpwebgallery.net |
+// | Copyright (C) 2003-2007 PhpWebGallery Team - http://phpwebgallery.net |
+// +-----------------------------------------------------------------------+
+// | file          : $Id: index.php 1912 2007-03-16 06:30:07Z rub $
+// | last update   : $Date: 2007-03-16 07:30:07 +0100 (ven, 16 mar 2007) $
+// | last modifier : $Author: rub $
+// | revision      : $Revision: 1912 $
+// +-----------------------------------------------------------------------+
+// | This program is free software; you can redistribute it and/or modify  |
+// | it under the terms of the GNU General Public License as published by  |
+// | the Free Software Foundation                                          |
+// |                                                                       |
+// | This program is distributed in the hope that it will be useful, but   |
+// | WITHOUT ANY WARRANTY; without even the implied warranty of            |
+// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      |
+// | General Public License for more details.                              |
+// |                                                                       |
+// | You should have received a copy of the GNU General Public License     |
+// | along with this program; if not, write to the Free Software           |
+// | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, |
+// | USA.                                                                  |
+// +-----------------------------------------------------------------------+
+
+// Recursive call
+$url = '../';
+header( 'Request-URI: '.$url );
+header( 'Content-Location: '.$url );
+header( 'Location: '.$url );
+exit();
+?>
Index: /extensions/floPure/theme/neon/mail-css.tpl
===================================================================
--- /extensions/floPure/theme/neon/mail-css.tpl	(revision 3677)
+++ /extensions/floPure/theme/neon/mail-css.tpl	(revision 3677)
@@ -0,0 +1,13 @@
+{* $Id: mail-css.tpl 2285 2008-03-18 23:43:38Z rvelices $ *}
+/* Theme clear mail css */
+
+body {ldelim} background-color:#fff; color:#696969;}
+#the_page {ldelim} background: #fff url({$ROOT_URL}template/{$themeconf.template}/mail/text/html/images/mailbody-bg.png) repeat-y scroll left top;}
+#content {ldelim} background: transparent url({$ROOT_URL}template/{$themeconf.template}/mail/text/html/images/header-bg.png) no-repeat scroll left top;}
+#copyright {ldelim} background: transparent url({$ROOT_URL}template/{$themeconf.template}/mail/text/html/images/footer-bg.png) no-repeat scroll left bottom;
+color: #333;}
+h2 {ldelim} background-color: #ddd;}
+img {ldelim} margin: 16px; border: 16px solid #aaa; -moz-border-radius: 4px; border-radius: 4px 4px; }
+img:hover {ldelim} padding: 15px; border: 1px solid yellow;background-color:#faebd7; -moz-border-radius: 4px; border-radius: 4px 4px; }
+a {ldelim} color: #369; background: transparent; }
+a:hover {ldelim} color: #ddd; }
Index: /extensions/floPure/theme/neon/theme.css
===================================================================
--- /extensions/floPure/theme/neon/theme.css	(revision 3677)
+++ /extensions/floPure/theme/neon/theme.css	(revision 3677)
@@ -0,0 +1,234 @@
+/* flop25 $ */
+/* text color */
+BODY, H1, H3, DT,
+INPUT.rateButtonSelected /* <= why IE doesn't inherit this ? */ {
+  color:#e0e0e0;
+}
+
+H2, #menubar DT, .throw {
+	color: #FFFFFF;
+}
+
+#content .navigationBar {
+  color: #aaaaaa;
+}
+#content .pageNumberSelected, #comments DIV.comment BLOCKQUOTE {
+  color: #000000;
+}
+
+.tabsheet li,
+.tabsheet li a { color: #fff; }
+.tabsheet li a:hover { color: #fff48e; }
+
+/* positionnement */
+#menubar DL, #menubar DT, #the_page, BODY {
+	margin: 0px;
+	padding: 0px;
+}
+
+#content {
+margin-top:0;
+}
+/* backgrounds */
+BODY, H3, .throw, #content {
+  background-color: #000;
+}
+
+H2, #imageHeaderBar, #imageToolBar A:hover, .row1 {
+background-color: #676767
+}
+
+#imageToolBar, #admin_content {
+  background-color: #676767;
+}
+/*.header_notes, .content,  #autre_content {
+  background-color: #676767;
+}*/
+
+#theHeader {
+	background-color:#282828;
+	color:#9d9d9d;
+	margin-top: 0px;
+}
+.categoryActions {
+	background-image: url(images/bouton.jpg);
+	background-repeat:repeat-x;
+	background-position:center;
+}
+#imageToolBar, H2 {
+	background-image: url(images/boutonh.jpg);
+	background-repeat:repeat-x;
+	background-position:center;
+}
+/*--------menu--------------*/
+#table_content, .table_menu, #table_mbLinks, #table_mbCategories, #table_mbTags, #table_mbSpecials, #table_mbMenu, #table_mbIdentification {
+width:100%;
+border:0;
+padding:0;
+margin:0;
+}
+
+/* backgrounds menu */
+
+.blocmenu_up_right, #section_up_right{
+	background-image: url(images/c2_haut_droit.jpg);
+	background-position:bottom;
+	background-repeat:no-repeat;
+	width:15px;
+	 height:32px;
+}
+.blocmenu_up_left, #section_up_left{
+	background-image: url(images/c2_haut_gauche.jpg);
+	background-position:bottom;
+	background-repeat:no-repeat;
+	width:15px;
+	 height:32px;
+}
+.blocmenu_up, #section_up{
+ background-image: url(images/c2_haut_milieu.jpg);
+ background-position:bottom;
+ background-repeat:repeat-x;
+	 height:32px;
+}
+
+/*.blocmenu_in, #section_in{
+	background-color:#676767;
+}*/
+.blocmenu_left, #section_left {
+ background-image: url(images/neon_vert_anim2.png);
+ background-position:center;
+ background-repeat:repeat-y;
+	width:30px;
+}
+.blocmenu_right, #section_right {
+ background-image: url(images/neon_gimp_anim.png);
+ background-position:center;
+ background-repeat:repeat-y;
+	width:70px;
+}
+.blocmenu_bottom_right, #section_bottom_right {
+ background-image: url(images/c2_bas_droit.jpg);
+ background-position:top;
+ background-repeat:no-repeat;
+ width:15px;
+ height:15px;
+}
+.blocmenu_bottom_left, #section_bottom_left {
+ background-image: url(images/c2_bas_gauche.jpg);
+ background-position:top;
+ background-repeat:no-repeat;
+ width:15px;
+ height:15px;
+}
+.blocmenu_bottom, #section_bottom{
+ background-image: url(images/c2_bas_milieu.jpg);
+ background-position:top;
+ background-repeat:repeat-x;
+  height:15px;
+}
+/* borders */
+/*#menubar DL, #content,
+#imageToolBar, */
+#comments DIV.comment BLOCKQUOTE {
+  border: 1px solid #d3d3d3;
+}
+
+#theImage IMG {
+  border-color: #d3d3d3;
+}
+
+#content UL.thumbnail IMG {
+    border: 1px solid #a0a0a0;
+}
+
+FIELDSET, INPUT, SELECT, TEXTAREA,
+#content DIV.comment  A.illustration IMG, #infos,
+#content DIV.thumbnailCategory {
+  border: 1px solid gray;
+}
+
+#comments DIV.comment BLOCKQUOTE {
+  border-left: 2px solid #696969;
+  background-color: #eee;
+}
+
+#content UL.thumbnails SPAN.wrap2 {
+  border: 1px solid #aaaaaa;	/* thumbnails border color and style */
+  border-radius: 4px 4px;	/* round corners with CSS3 compliant browsers */
+}
+
+#content UL.thumbnails SPAN.wrap2:hover,
+#content UL.thumbnailCategories DIV.thumbnailCategory:hover,
+#content UL.thumbnailCategories DIV.thumbnailCategory:hover A {
+	background-color: #90949a;
+	border-color: #76717B;		/* thumbnails border color when mouse cursor is over it */
+	color: black;
+}
+
+ul.tabsheet { border-color: #fff48e; }
+.tabsheet li { border: 1px solid #fff; }
+.tabsheet li:hover { border-color: #fff48e !important; }
+
+
+/* links */
+A, INPUT.rateButton {
+  color: #FFFFFF;
+}
+
+A:hover {
+  color: #CCCCCC;
+}
+
+#imageToolBar A, #imageToolBar A:hover,
+A.navThumb, A.navThumb:hover {
+  border-bottom: none;
+}
+
+/* others */
+.pleaseNote {
+  background: #9c9c9c;
+  color: #CCCCCC;
+  padding: 1ex;
+  font-weight: bold;
+}
+#the_page {
+  border: 1px solid #e0e0e0;
+  padding-bottom:30px;
+  text-align:center;
+  display:block;
+}
+#content {
+  padding-right:5px;
+}
+/*calendar elements*/
+SPAN.calItemEmpty { color: silver; }
+
+SPAN.calItem, SPAN.calItemEmpty
+{
+  border: 1px solid silver;
+}
+
+/* nice looking month calendar*/
+TD.calDayCellEmpty, TD.calDayCellFull { border: 1px solid #7E7262;}
+
+TD.calDayCellEmpty { color: silver; }
+
+.calBackDate { color: #000; }
+.calForeDate { color: #fff; }
+.virtual_cat { background: #fff !important; }
+.qsearch { font-size: 80%; font-style: normal; }
+#mbMenu #quicksearch > p { text-align: left; }
+#qsearchInput {
+	color: #000;
+}
+#qsearchInput:focus {
+	color: #000;
+}
+.tabsheet li,
+.tabsheet li a { color: #FFFFFF;}
+.tabsheet li a:hover { color: #484848; }
+.tabsheet li { background-color: #807d76; }
+.selected_tab { background-color: #9e9c96!important; }
+ul.tabsheet { border-color: #807d76; }
+.tabsheet li { border: 1px solid #696969; }
+.tabsheet li:hover { border-color: #484848 !important; }
Index: /extensions/floPure/theme/neon/themeconf.inc.php
===================================================================
--- /extensions/floPure/theme/neon/themeconf.inc.php	(revision 3677)
+++ /extensions/floPure/theme/neon/themeconf.inc.php	(revision 3677)
@@ -0,0 +1,13 @@
+<?php
+$themeconf = array(
+  'template' => 'floPure',
+  'theme' => 'neon',
+  'template_dir' => 'template/floPure',
+  'icon_dir' => 'template/floPure/icon',
+  'admin_icon_dir' => 'template/floPure/icon/admin',
+  'mime_icon_dir' => 'template/floPure/icon/mimetypes/',
+  'local_head' => '<!-- no theme specific head content -->',
+  'eid' => '158',
+  'version' => '2.0.5',
+);
+?>
Index: /extensions/floPure/tools/floPure.class.php
===================================================================
--- /extensions/floPure/tools/floPure.class.php	(revision 3676)
+++ /extensions/floPure/tools/floPure.class.php	(revision 3677)
@@ -57,4 +57,135 @@
 	closedir ($dh); // on ferme le repertoire courant
 	}
+	function url_is_remote($url)
+	{
+	  if ( strncmp($url, 'http://', 7)==0
+		or strncmp($url, 'https://', 8)==0 )
+	  {
+		return true;
+	  }
+	  return false;
+	}
+	
+	function fetchRemote($src, &$dest, $user_agent='Piwigo', $step=0)
+	{
+	  // Try to retrieve data from local file?
+	  if (!$this->url_is_remote($src))
+	  {
+		$content = @file_get_contents($src);
+		if ($content !== false)
+		{
+		  is_resource($dest) ? @fwrite($dest, $content) : $dest = $content;
+		  return true;
+		}
+		else
+		{
+		  return false;
+		}
+	  }
+	
+	  // After 3 redirections, return false
+	  if ($step > 3) return false;
+	
+	  // Initialize $dest
+	  is_resource($dest) or $dest = '';
+	
+	  // Try curl to read remote file
+	  if (function_exists('curl_init'))
+	  {
+		$ch = @curl_init();
+		@curl_setopt($ch, CURLOPT_URL, $src);
+		@curl_setopt($ch, CURLOPT_HEADER, 1);
+		@curl_setopt($ch, CURLOPT_USERAGENT, $user_agent);
+		@curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
+		$content = @curl_exec($ch);
+		$header_length = @curl_getinfo($ch, CURLINFO_HEADER_SIZE);
+		$status = @curl_getinfo($ch, CURLINFO_HTTP_CODE);
+		@curl_close($ch);
+		if ($content !== false and $status >= 200 and $status < 400)
+		{
+		  if (preg_match('/Location:\s+?(.+)/', substr($content, 0, $header_length), $m))
+		  {
+			return $this->fetchRemote($m[1], $dest, $user_agent, $step+1);
+		  }
+		  $content = substr($content, $header_length);
+		  is_resource($dest) ? @fwrite($dest, $content) : $dest = $content;
+		  return true;
+		}
+	  }
+	
+	  // Try file_get_contents to read remote file
+	  if (ini_get('allow_url_fopen'))
+	  {
+		$content = @file_get_contents($src);
+		if ($content !== false)
+		{
+		  is_resource($dest) ? @fwrite($dest, $content) : $dest = $content;
+		  return true;
+		}
+	  }
+	
+	  // Try fsockopen to read remote file
+	  $src = parse_url($src);
+	  $host = $src['host'];
+	  $path = isset($src['path']) ? $src['path'] : '/';
+	  $path .= isset($src['query']) ? '?'.$src['query'] : '';
+	
+	  if (($s = @fsockopen($host,80,$errno,$errstr,5)) === false)
+	  {
+		return false;
+	  }
+	
+	  fwrite($s,
+		"GET ".$path." HTTP/1.0\r\n"
+		."Host: ".$host."\r\n"
+		."User-Agent: ".$user_agent."\r\n"
+		."Accept: */*\r\n"
+		."\r\n"
+	  );
+	
+	  $i = 0;
+	  $in_content = false;
+	  while (!feof($s))
+	  {
+		$line = fgets($s);
+	
+		if (rtrim($line,"\r\n") == '' && !$in_content)
+		{
+		  $in_content = true;
+		  $i++;
+		  continue;
+		}
+		if ($i == 0)
+		{
+		  if (!preg_match('/HTTP\/(\\d\\.\\d)\\s*(\\d+)\\s*(.*)/',rtrim($line,"\r\n"), $m))
+		  {
+			fclose($s);
+			return false;
+		  }
+		  $status = (integer) $m[2];
+		  if ($status < 200 || $status >= 400)
+		  {
+			fclose($s);
+			return false;
+		  }
+		}
+		if (!$in_content)
+		{
+		  if (preg_match('/Location:\s+?(.+)$/',rtrim($line,"\r\n"),$m))
+		  {
+			fclose($s);
+			return $this->fetchRemote(trim($m[1]),$dest,$user_agent,$step+1);
+		  }
+		  $i++;
+		  continue;
+		}
+		is_resource($dest) ? @fwrite($dest, $line) : $dest .= $line;
+		$i++;
+	  }
+	  fclose($s);
+	  return true;
+	}
+
+
 	function is_not_up_to_date($v_local, $eid)
 	{
