Changeset 868 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/user-content.php
- Timestamp:
- 09/23/2014 06:30:18 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/inc/user-content.php
r817 r868 1 1 <?php 2 2 /** 3 * Code Reference user submitted content (comments, examples, etc).3 * Code Reference user submitted content (comments, notes, etc). 4 4 * 5 5 * @package wporg-developer … … 19 19 20 20 /** 21 * Handles adding/removing hooks to enable comments as examples. 22 * 23 * Mostly gives users greater permissions in terms of comment content. 24 * 25 * In order to submit code examples, users must be able to post with less restrictions. 21 * Handles adding/removing hooks to enable comments as user contributed notes. 26 22 */ 27 23 public static function do_init() { … … 30 26 add_filter( 'comments_open', array( __CLASS__, 'prevent_invalid_comment_submissions' ), 10, 2 ); 31 27 32 // Sets whether submitting examples is open for the user33 add_filter( 'comments_open', '\DevHub\\can_user_post_ example', 10, 2 );28 // Sets whether submitting notes is open for the user 29 add_filter( 'comments_open', '\DevHub\\can_user_post_note', 10, 2 ); 34 30 35 31 // Enqueue scripts and styles … … 71 67 wp_enqueue_style( 'syntaxhighlighter-theme-default' ); 72 68 73 wp_enqueue_script( 'wporg-developer- code-examples', get_template_directory_uri() . '/js/code-example.js', array(), '20140423', true );69 wp_enqueue_script( 'wporg-developer-user-notes', get_template_directory_uri() . '/js/user-notes.js', array(), '20140912', true ); 74 70 if ( get_option( 'thread_comments' ) ) { 75 71 wp_enqueue_script( 'comment-reply' );
Note: See TracChangeset
for help on using the changeset viewer.