Ignore:
Timestamp:
Dec 14, 2012, 3:35:07 PM (11 years ago)
Author:
mistic100
Message:

change reload icon with color choice (dark or light), separate HTML and PHP

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/CryptograPHP/include/register.inc.php

    r17319 r19428  
    22if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
    33
    4 load_language('plugin.lang', CRYPTO_PATH);
     4include(CRYPTO_PATH.'include/common.inc.php');
    55add_event_handler('loc_end_page_header', 'add_crypto');
    66add_event_handler('register_user_check', 'check_crypto');
     
    99{
    1010  global $template;
    11 
    1211  $template->set_prefilter('register', 'prefilter_crypto');
    1312}
     
    1514function prefilter_crypto($content, $smarty)
    1615{
    17   global $conf, $user;
    18    
    1916  $search = '#\(\{\'useful when password forgotten\'\|@translate\}\)(\s*)((\{/if\})?)#i';
    20   $replace = '({\'useful when password forgotten\'|@translate})$1$2
    21       </li>
    22       <li>
    23         <span class="property">
    24           <label for="captcha_code">{\''.($conf['cryptographp']['captcha_type']=='string'?'Enter code':'Solve equation').'\'|@translate} <img id="captcha" src="'.CRYPTO_PATH.'securimage/securimage_show.php" alt="CAPTCHA Image"></label>
    25           <a href="#" onclick="document.getElementById(\'captcha\').src = \'{$ROOT_URL}'.CRYPTO_PATH.'securimage/securimage_show.php?\' + Math.random(); return false">
    26             <img src="{$ROOT_URL}'.CRYPTO_PATH.'template/refresh.png"></a>
    27         </span>
    28         <input type="text" id="captcha_code" name="captcha_code" size="'.($conf['cryptographp']['code_length']+1).'" maxlength="'.$conf['cryptographp']['code_length'].'" />';
    29 
     17  $replace = '({\'useful when password forgotten\'|@translate})$1$2'."\n".'{\$CRYPTOGRAPHP}';
    3018  return preg_replace($search, $replace, $content);
    3119}
Note: See TracChangeset for help on using the changeset viewer.