Ignore:
Timestamp:
Jun 11, 2011, 3:01:45 PM (13 years ago)
Author:
mistic100
Message:

activate captcha on comment form

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/CryptograPHP/maintain.inc.php

    r10841 r11316  
    66  if (!isset($conf['cryptographp_theme']))
    77  {
    8     pwg_query('INSERT INTO '.CONFIG_TABLE.' (param,value,comment) VALUES ("cryptographp_theme","cryptographp","CryptograPHP theme");');
     8    pwg_query('INSERT INTO '.CONFIG_TABLE.' (param,value,comment) VALUES ("cryptographp_theme","cryptographp,reject","CryptograPHP config");');
    99  }
    1010}
    1111
     12function plugin_activate()
     13{
     14  global $conf;
     15  $conf['cryptographp_theme'] = explode(',', $conf['cryptographp_theme']);
     16 
     17  if(count($conf['cryptographp_theme']) == 1)
     18  {
     19    pwg_query('UPDATE '.CONFIG_TABLE.' SET value = "'.$conf['cryptographp_theme'][0].',reject" WHERE param = "cryptographp_theme";');
     20  }
     21}
    1222function plugin_uninstall()
    1323{
Note: See TracChangeset for help on using the changeset viewer.