'; if ($canPost) echo 'Signatures'; else echo 'Signature'; echo ''; if ($canPost) { echo '

'; } echo ''; echo ''; } function update_signature_settings($user_ID) { if ( isset( $_POST['post_sig'] )) { $post_sig = apply_filters('set_post_signature', trim($_POST['post_sig'])); update_usermeta($user_ID, 'post_sig', $post_sig); } if ( isset( $_POST['comment_sig'] )) { $comment_sig = apply_filters('set_comment_signature', trim($_POST['comment_sig'])); update_usermeta($user_ID, 'comment_sig', $comment_sig); } } function post_content_intercept($content) { global $post; if ($post->post_type != 'post') { return $content; } $sig = get_usermeta($post->post_author, 'post_sig'); if ( !empty( $sig )) { $content .= $sig; } return $content; } function comment_intercept($content) { global $comment; $sig = get_usermeta($comment->user_id, 'comment_sig'); if ( !empty( $sig )) { $content .= "---------------------------------------- ".$sig; } return $content; } } } //instantiate the class if (class_exists('PerUserSig')) { $PerUserSig = new PerUserSig(); } ?>