コード例 #1
0
 function cntctfrm_admin_init()
 {
     global $bws_plugin_info, $cntctfrm_plugin_info;
     /* Add variable for bws_menu */
     $cntctfrm_plugin_info = get_plugin_data(__FILE__);
     if (!isset($bws_plugin_info) || empty($bws_plugin_info)) {
         $bws_plugin_info = array('id' => '77', 'version' => $cntctfrm_plugin_info["Version"]);
     }
     /* Call register settings function */
     cntctfrm_settings();
     /* Function check if plugin is compatible with current WP version  */
     cntctfrm_version_check();
 }
コード例 #2
0
ファイル: contact_form.php プロジェクト: alextkd/fdsmc
 function cntctfrm_init()
 {
     /* Internationalization, first(!) */
     if (!session_id()) {
         @session_start();
     }
     load_plugin_textdomain('contact_form', false, dirname(plugin_basename(__FILE__)) . '/languages/');
     /* Function check if plugin is compatible with current WP version  */
     cntctfrm_version_check();
     if (!is_admin()) {
         cntctfrm_check_and_send();
     }
 }