Edit your license terms here. Author: Alex King Author URI: http://alexking.org Version: 1.1 */ function akcl_request_handler() { if (isset($_GET['activate']) && $_GET['activate'] == 'true') { if (get_option('akcl_text') == '') { add_option('akcl_text', 'By submitting a comment here you grant this site a perpetual license to reproduce your words and name/web site in attribution.'); } } if (!empty($_POST['ak_action'])) { switch($_POST['ak_action']) { case 'akcl_update_settings': if (isset($_POST['akcl_text'])) { update_option('akcl_text', stripslashes($_POST['akcl_text'])); header('Location: '.get_bloginfo('wpurl').'/wp-admin/options-general.php?page=comment-license.php&updated=true'); die(); } break; } } } add_action('init', 'akcl_request_handler'); function akcl_show_license() { $text = get_option('akcl_text'); if (!empty($text)) { print('

'.wp_specialchars($text).'

'); } } add_action('comment_form', 'akcl_show_license', 99); function akcl_options_form() { print('

'.__('Comment License Options', 'comment-license').'


'.__('README', 'comment-license').'

'.__('Find answers to common questions here.', 'comment-license').'

'); } function akcl_menu_items() { if (current_user_can('manage_options')) { add_options_page( __('Comment License', 'comment-license') , __('Comment License', 'comment-license') , 10 , basename(__FILE__) , 'akcl_options_form' ); } } add_action('admin_menu', 'akcl_menu_items'); function akcl_admin_head() { print(' '); } add_action('admin_head', 'akcl_admin_head'); ?>