Ignore:
Timestamp:
Dec 14, 2012, 3:35:07 PM (12 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/category.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_begin_index', 'add_crypto');
    66add_event_handler('user_comment_check_albums', 'check_crypto', EVENT_HANDLER_PRIORITY_NEUTRAL, 2);
     
    99{
    1010  global $template;
    11  
    12   if (!is_a_guest()) return;
    13  
    1411  $template->set_prefilter('comments_on_albums', 'prefilter_crypto');
    1512}
     
    1714function prefilter_crypto($content, $smarty)
    1815{
    19   global $conf;
    20  
    2116  $search = '{$comment_add.CONTENT}</textarea></p>';
    22   $replace = $search.'
    23                                 <p><label>{\''.($conf['cryptographp']['captcha_type']=='string'?'Enter code':'Solve equation').'\'|@translate} :</label></p>
    24                                 <p>
    25                                   <img id="captcha" src="{$ROOT_URL}'.CRYPTO_PATH.'securimage/securimage_show.php" alt="CAPTCHA Image">
    26                                   <a href="#" onclick="document.getElementById(\'captcha\').src = \'{$ROOT_URL}'.CRYPTO_PATH.'securimage/securimage_show.php?\' + Math.random(); return false">
    27                                     <img src="{$ROOT_URL}'.CRYPTO_PATH.'template/refresh.png"></a>
    28           <input type="text" name="captcha_code" style="width:'.$conf['cryptographp']['code_length'].'em;" maxlength="'.$conf['cryptographp']['code_length'].'" />
    29                                 </p>';
    30 
    31   return str_replace($search, $replace, $content);
     17  return str_replace($search, $search."\n{\$CRYPTOGRAPHP}", $content);
    3218}
    3319
Note: See TracChangeset for help on using the changeset viewer.