AnsPress_Admin::options_uac_reading()
Description #
Register UAC reading options.
Source #
File: admin/anspress-admin.php
public static function options_uac_reading() { $opt = ap_opt(); $form = array( 'fields' => array( 'read_question_per' => array( 'label' => __( 'Who can read question?', 'anspress-question-answer' ), 'desc' => __( 'Set who can view or read a question.', 'anspress-question-answer' ), 'type' => 'select', 'value' => $opt['read_question_per'], 'options' => array( 'anyone' => __( 'Anyone, including non-loggedin', 'anspress-question-answer' ), 'logged_in' => __( 'Only logged in', 'anspress-question-answer' ), 'have_cap' => __( 'Only user having ap_read_question capability', 'anspress-question-answer' ), ), ), 'read_answer_per' => array( 'label' => __( 'Who can read answers?', 'anspress-question-answer' ), 'desc' => __( 'Set who can view or read a answer.', 'anspress-question-answer' ), 'type' => 'select', 'value' => $opt['read_answer_per'], 'options' => array( 'anyone' => __( 'Anyone, including non-loggedin', 'anspress-question-answer' ), 'logged_in' => __( 'Only logged in', 'anspress-question-answer' ), 'have_cap' => __( 'Only user having ap_read_answer capability', 'anspress-question-answer' ), ), ), 'read_comment_per' => array( 'label' => __( 'Who can read comment?', 'anspress-question-answer' ), 'desc' => __( 'Set who can view or read a comment.', 'anspress-question-answer' ), 'type' => 'select', 'value' => $opt['read_comment_per'], 'options' => array( 'anyone' => __( 'Anyone, including non-loggedin', 'anspress-question-answer' ), 'logged_in' => __( 'Only logged in', 'anspress-question-answer' ), 'have_cap' => __( 'Only user having ap_read_comment capability', 'anspress-question-answer' ), ), ), ), ); return $form; }
Expand full source code Collapse full source code View on GitHub: admin/anspress-admin.php:1003
Add your comment