Changeset 11370
- Timestamp:
- Jun 14, 2011, 3:15:38 PM (13 years ago)
- Location:
- extensions/CryptograPHP
- Files:
-
- 5 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
extensions/CryptograPHP/include/category.inc.php
r11316 r11370 6 6 include($cryptinstall); 7 7 8 add_event_handler('loc_begin_index', 'add_c aptcha');9 add_event_handler('user_comment_check', 'check_c aptcha', EVENT_HANDLER_PRIORITY_NEUTRAL, 2);8 add_event_handler('loc_begin_index', 'add_crypto'); 9 add_event_handler('user_comment_check', 'check_crypto', EVENT_HANDLER_PRIORITY_NEUTRAL, 2); 10 10 11 function add_c aptcha()11 function add_crypto() 12 12 { 13 13 global $template, $conf; … … 15 15 if (!is_a_guest()) return; 16 16 17 $template->set_prefilter('comments_on_albums', ' captcha_prefilter');17 $template->set_prefilter('comments_on_albums', 'prefilter_crypto'); 18 18 $template->assign('CAPTCHA', dsp_crypt($conf['cryptographp_theme'][0].'.cfg.php',1)); 19 19 } 20 20 21 function captcha_prefilter($content, $smarty)21 function prefilter_crypto($content, $smarty) 22 22 { 23 23 load_language('plugin.lang', CRYPTO_PATH); … … 30 30 } 31 31 32 function check_c aptcha($action, $comment)32 function check_crypto($action, $comment) 33 33 { 34 34 global $conf, $user; -
extensions/CryptograPHP/include/contactform.inc.php
r11316 r11370 6 6 include($cryptinstall); 7 7 8 add_event_handler('display_contactform', 'add_c aptcha');9 add_event_handler('check_contactform_params', 'check_c aptcha');8 add_event_handler('display_contactform', 'add_crypto'); 9 add_event_handler('check_contactform_params', 'check_crypto'); 10 10 11 function add_c aptcha()11 function add_crypto() 12 12 { 13 13 global $template, $conf; … … 15 15 if (!is_a_guest()) return; 16 16 17 $template->set_prefilter('cf_form', ' captcha_prefilter');17 $template->set_prefilter('cf_form', 'prefilter_crypto'); 18 18 $template->assign('CAPTCHA', dsp_crypt($conf['cryptographp_theme'][0].'.cfg.php',1)); 19 19 } 20 20 21 function captcha_prefilter($content, $smarty)21 function prefilter_crypto($content, $smarty) 22 22 { 23 23 $search = ' … … 36 36 } 37 37 38 function check_c aptcha($infos)38 function check_crypto($infos) 39 39 { 40 40 if (!is_a_guest()) return $infos; -
extensions/CryptograPHP/include/picture.inc.php
r11316 r11370 6 6 include($cryptinstall); 7 7 8 add_event_handler('loc_begin_picture', 'add_c aptcha');9 add_event_handler('user_comment_check', 'check_c aptcha', EVENT_HANDLER_PRIORITY_NEUTRAL, 2);8 add_event_handler('loc_begin_picture', 'add_crypto'); 9 add_event_handler('user_comment_check', 'check_crypto', EVENT_HANDLER_PRIORITY_NEUTRAL, 2); 10 10 11 function add_c aptcha()11 function add_crypto() 12 12 { 13 13 global $template, $conf; … … 15 15 if (!is_a_guest()) return; 16 16 17 $template->set_prefilter('picture', ' captcha_prefilter');17 $template->set_prefilter('picture', 'prefilter_crypto'); 18 18 $template->assign('CAPTCHA', dsp_crypt($conf['cryptographp_theme'][0].'.cfg.php',1)); 19 19 } 20 20 21 function captcha_prefilter($content, $smarty)21 function prefilter_crypto($content, $smarty) 22 22 { 23 23 load_language('plugin.lang', CRYPTO_PATH); … … 30 30 } 31 31 32 function check_c aptcha($action, $comment)32 function check_crypto($action, $comment) 33 33 { 34 34 global $conf, $user; -
extensions/CryptograPHP/include/register.inc.php
r11316 r11370 6 6 include($cryptinstall); 7 7 8 add_event_handler('loc_end_page_header', 'add_c aptcha');9 add_event_handler('register_user_check', 'check_c aptcha');8 add_event_handler('loc_end_page_header', 'add_crypto'); 9 add_event_handler('register_user_check', 'check_crypto'); 10 10 11 function add_c aptcha()11 function add_crypto() 12 12 { 13 13 global $template, $conf; 14 14 15 $template->set_prefilter('register', ' captcha_prefilter');15 $template->set_prefilter('register', 'prefilter_crypto'); 16 16 $template->assign('CAPTCHA', dsp_crypt($conf['cryptographp_theme'][0].'.cfg.php',1)); 17 17 } 18 18 19 function captcha_prefilter($content, $smarty)19 function prefilter_crypto($content, $smarty) 20 20 { 21 21 load_language('plugin.lang', CRYPTO_PATH); … … 39 39 } 40 40 41 function check_c aptcha($errors)41 function check_crypto($errors) 42 42 { 43 43 if (!chk_crypt($_POST['code'])) -
extensions/CryptograPHP/main.inc.php
r11316 r11370 42 42 if (script_basename() == 'admin') 43 43 { 44 add_event_handler('get_admin_plugin_menu_links', 'crypto_plugin_admin_menu' ); 45 } 44 add_event_handler('get_admin_plugin_menu_links', 'crypto_plugin_admin_menu'); 46 45 47 function crypto_plugin_admin_menu($menu)48 {49 46 function crypto_plugin_admin_menu($menu) 47 { 48 global $page,$conf; 50 49 51 array_push( 52 $menu, 53 array( 54 'NAME' => 'CryptograPHP', 55 'URL' => get_root_url().'admin.php?page=plugin-'.basename(dirname(__FILE__)) 56 ) 57 ); 58 return $menu; 50 array_push( 51 $menu, 52 array( 53 'NAME' => 'CryptograPHP', 54 'URL' => get_root_url().'admin.php?page=plugin-'.basename(dirname(__FILE__)) 55 ) 56 ); 57 return $menu; 58 } 59 59 } 60 60
Note: See TracChangeset
for help on using the changeset viewer.