__('File type not allowed,\nAllowed file types: *.amf,*.txt') // ) ); } if (1 == get_option('acronym_content')) add_filter('the_content', array('Acronym_Manager', 'acronym_replace')); if (1 == get_option('acronym_comments')) add_filter('comment_text', array('Acronym_Manager', 'acronym_replace')); //Initiate the acronym widget that allows the adding of acronyms from the sidebar function am_init_widget() { require_once('php/acronym-manager-widget.php'); // Include widget file register_widget('Acronym_Manager_Widget'); // Register the widget } //add to a page in the site where you would like the complete collection of acronyms listed in table format add_shortcode( 'glossary', array('Acronym_Manager', 'print_glossary_list') ); /* void install () * Creates tables and populates default acronyms. */ function acronym_manager_install() { // Populate defaults $acronyms = array('CNS' => 'central nervous system'); add_option('acronym_acronyms', $acronyms); // Add default options -- Options not currently modifiable by user add_option('acronym_content', 1); add_option('acronym_comments', 1); Acronym_Manager::theme_html5_check(); } /* void uninstall () */ function acronym_manager_uninstall() { delete_option('acronym_acronyms'); delete_option('acronym_content'); delete_option('acronym_comments'); delete_option('acronym_html5'); } ?>