Index: extensions/captcha/admin.php
===================================================================
--- extensions/captcha/admin.php	(revision 8032)
+++ extensions/captcha/admin.php	(revision 8034)
@@ -7,20 +7,15 @@
 if ( isset($_POST['submit']) and !is_adviser() )
 {
-  $conf['captcha_publickey'] = trim($_POST['captcha_publickey']);
-  $conf['captcha_privatekey'] = trim($_POST['captcha_privatekey']);
+  foreach (array('captcha_publickey', 'captcha_privatekey', 'captcha_theme') as $field)
+  {
+    $conf[$field] = trim($_POST[$field]);
 
-  $query = '
+    $query = '
 UPDATE '.CONFIG_TABLE.'
-  SET value="'.$conf['captcha_publickey'].'"
-  WHERE param="captcha_publickey"
+  SET value="'.$conf[$field].'"
+  WHERE param="'.$field.'"
   LIMIT 1';
-  pwg_query($query);
-
-  $query = '
-UPDATE '.CONFIG_TABLE.'
-  SET value="'.$conf['captcha_privatekey'].'"
-  WHERE param="captcha_privatekey"
-  LIMIT 1';
-  pwg_query($query);
+    pwg_query($query);
+  }
 
   array_push($page['infos'], l10n('Information data registered in database'));
@@ -32,5 +27,7 @@
   'CAPTCHA_PUBLICKEY' => $conf['captcha_publickey'],
   'CAPTCHA_PRIVATEKEY' => $conf['captcha_privatekey'],
-  'reCAPTCHA_URL' => recaptcha_get_signup_url (urlencode($_SERVER['SERVER_NAME']), 'Piwigo')
+  'reCAPTCHA_URL' => recaptcha_get_signup_url(urlencode($_SERVER['SERVER_NAME']), 'Piwigo'),
+  'captcha_theme_options' => array('red', 'white', 'blackglass'),
+  'captcha_theme_selected' => $conf['captcha_theme'],
   )
 );
Index: extensions/captcha/admin.tpl
===================================================================
--- extensions/captcha/admin.tpl	(revision 8032)
+++ extensions/captcha/admin.tpl	(revision 8034)
@@ -10,12 +10,18 @@
   <li>
   <label>
-    {'Public Key:'|@translate}
-    <input type="text" size="48" name="captcha_publickey" value="{$CAPTCHA_PUBLICKEY}" />
+    {'Public Key'|@translate}:
+    <input type="text" size="52" name="captcha_publickey" value="{$CAPTCHA_PUBLICKEY}" />
   </label>
   </li>
   <li>
   <label>
-    {'Private Key:'|@translate}
-    <input type="text" size="48" name="captcha_privatekey" value="{$CAPTCHA_PRIVATEKEY}" />
+    {'Private Key'|@translate}:
+    <input type="text" size="52" name="captcha_privatekey" value="{$CAPTCHA_PRIVATEKEY}" />
+  </label>
+  </li>
+  <li>
+  <label>
+    {'Interface theme'|@translate}:
+    {html_options name=captcha_theme values=$captcha_theme_options output=$captcha_theme_options selected=$captcha_theme_selected}
   </label>
   </li>
@@ -23,5 +29,5 @@
     <br/><a href="{$reCAPTCHA_URL}" target="_blank">{'Signup for personal usage keys'|@translate}</a>
   </li>
-  
+
   <p class="bottomButtons">
     <input class="submit" type="submit" value="{'Submit'|@translate}" name="submit" {$TAG_INPUT_ENABLED}/>
Index: extensions/captcha/captcha.tpl
===================================================================
--- extensions/captcha/captcha.tpl	(revision 8032)
+++ extensions/captcha/captcha.tpl	(revision 8034)
@@ -1,7 +1,10 @@
 {html_head}
 <script type= "text/javascript">
-var RecaptchaOptions = {ldelim} theme: "white", lang : "{$lang_info.code}" };
+var RecaptchaOptions = {ldelim} theme: "{$CAPTCHA_THEME}", lang : "{$lang_info.code}" };
 </script>
-<style type="text/css">#recaptcha_area {ldelim} margin: 25px auto; }</style>
+<style type="text/css">
+#recaptcha_area {ldelim} margin: 20px auto; }
+#recaptcha_area a {ldelim} border:0 none; }
+</style>
 {/html_head}
 
Index: extensions/captcha/language/de_DE/plugin.lang.php
===================================================================
--- extensions/captcha/language/de_DE/plugin.lang.php	(revision 8032)
+++ extensions/captcha/language/de_DE/plugin.lang.php	(revision 8034)
@@ -2,6 +2,6 @@
 
 $lang['Captcha Configuration'] = 'Captcha Konfiguration';
-$lang['Public Key:'] = 'Öffentlicher Key:';
-$lang['Private Key:'] = 'Privater Key:';
+$lang['Public Key'] = 'Öffentlicher Key';
+$lang['Private Key'] = 'Privater Key';
 $lang['Signup for personal usage keys'] = 'Registrieren Sie sich um Ihre persönliche Keys zu erhalten';
 
Index: extensions/captcha/language/en_UK/plugin.lang.php
===================================================================
--- extensions/captcha/language/en_UK/plugin.lang.php	(revision 8032)
+++ extensions/captcha/language/en_UK/plugin.lang.php	(revision 8034)
@@ -2,6 +2,6 @@
 
 $lang['Captcha Configuration'] = 'Captcha Configuration';
-$lang['Public Key:'] = 'Public Key:';
-$lang['Private Key:'] = 'Private Key:';
+$lang['Public Key'] = 'Public Key';
+$lang['Private Key'] = 'Private Key';
 $lang['Signup for personal usage keys'] = 'Signup for personal usage keys';
 
Index: extensions/captcha/language/fr_FR/plugin.lang.php
===================================================================
--- extensions/captcha/language/fr_FR/plugin.lang.php	(revision 8032)
+++ extensions/captcha/language/fr_FR/plugin.lang.php	(revision 8034)
@@ -2,6 +2,6 @@
 
 $lang['Captcha Configuration'] = 'Configuration du Captcha';
-$lang['Public Key:'] = 'Clef publique:';
-$lang['Private Key:'] = 'Cléf privée:';
+$lang['Public Key'] = 'Clef publique';
+$lang['Private Key'] = 'Cléf privée';
 $lang['Signup for personal usage keys'] = 'Enregistrer ses clefs personelles';
 
Index: extensions/captcha/language/it_IT/plugin.lang.php
===================================================================
--- extensions/captcha/language/it_IT/plugin.lang.php	(revision 8032)
+++ extensions/captcha/language/it_IT/plugin.lang.php	(revision 8034)
@@ -2,6 +2,6 @@
 
 $lang['Captcha Configuration'] = 'Configurazione del captcha';
-$lang['Public Key:'] = 'Chiave pubblica:';
-$lang['Private Key:'] = 'Chiave privata:';
+$lang['Public Key'] = 'Chiave pubblica';
+$lang['Private Key'] = 'Chiave privata';
 $lang['Signup for personal usage keys'] = 'Iscriversi per le chiavi di uso personale';
 
Index: extensions/captcha/main.inc.php
===================================================================
--- extensions/captcha/main.inc.php	(revision 8032)
+++ extensions/captcha/main.inc.php	(revision 8034)
@@ -22,6 +22,5 @@
   add_event_handler('register_user_check', 'check_captcha');
 }
-
-if (script_basename() == 'admin')
+elseif (script_basename() == 'admin')
 {
   add_event_handler('get_admin_plugin_menu_links', 'captcha_plugin_admin_menu' );
@@ -34,5 +33,9 @@
   $template->set_prefilter('register', 'captcha_prefilter');
   $template->set_filename('captcha', realpath(CAPTCHA_PATH.'captcha.tpl'));
-  $template->assign('CAPTCHA_HTML', recaptcha_get_html($conf['captcha_publickey'], get_plugin_data('captcha')));
+  $template->assign(array(
+    'CAPTCHA_HTML'  => recaptcha_get_html($conf['captcha_publickey'], get_plugin_data('captcha')),
+    'CAPTCHA_THEME' => $conf['captcha_theme'],
+    )
+  );
   $template->assign_var_from_handle('CAPTCHA', 'captcha');
 }
@@ -41,7 +44,5 @@
 {
   $search = '<p class="bottomButtons">';
-  $captcha = '{$CAPTCHA}';
-
-  return str_replace($search, $captcha."\n".$search, $content);
+  return str_replace($search, '{$CAPTCHA}'."\n".$search, $content);
 }
 
Index: extensions/captcha/maintain.inc.php
===================================================================
--- extensions/captcha/maintain.inc.php	(revision 8032)
+++ extensions/captcha/maintain.inc.php	(revision 8034)
@@ -16,8 +16,23 @@
 }
 
+function plugin_activate()
+{
+  global $conf;
+
+  if (!isset($conf['captcha_theme']))
+  {
+    $q = '
+INSERT INTO '.CONFIG_TABLE.' (param,value,comment)
+  VALUES
+  ("captcha_theme","red","Captcha theme")
+;';
+    pwg_query($q);
+  }
+}
+
 
 function plugin_uninstall()
 {
-  foreach (array('captcha_publickey','captcha_privatekey') as $param)
+  foreach (array('captcha_publickey','captcha_privatekey', 'captcha_theme') as $param)
   {
     $q = '
