Changeset 2068265
- Timestamp:
- 04/13/2019 03:07:44 PM (5 years ago)
- Location:
- unlist-my-post
- Files:
-
- 6 added
- 1 deleted
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
unlist-my-post/trunk/readme.txt
r2052012 r2068265 4 4 Requires at least: 4.6 5 5 Tested up to: 5.1 6 Stable tag: 3. 06 Stable tag: 3. 7 7 License: GNU GPL v3 8 8 License URI: https://www.gnu.org/licenses/gpl-3.0.html -
unlist-my-post/trunk/unlist-my-post.php
r2052012 r2068265 5 5 * Plugin URI: https://wordpress.org/plugins/unlist-my-post/ 6 6 * Description: Unlist your posts so you'll need a link to read them. 7 * Version: 3. 07 * Version: 3. 8 8 * Author: Daniel James 9 9 * Author URI: https://danieltj.uk/ … … 56 56 add_filter( 'widget_posts_args', array( __CLASS__, 'filter_post_widget' ), 10, 1 ); 57 57 add_filter( 'widget_pages_args', array( __CLASS__, 'filter_page_widget' ), 10, 1 ); 58 58 59 add_filter( 'rest_post_query', array( __CLASS__, 'filter_rest_api_posts' ), 10, 2 ); 59 60 add_filter( 'rest_page_query', array( __CLASS__, 'filter_rest_api_posts' ), 10, 2 ); … … 365 366 366 367 /** 367 * Filter the list of posts in the Recent Posts widget. 368 * 369 * See the function above, `filter_unlisted_posts` for more information. 368 * Filter the recent posts widget. 370 369 * 371 370 * @see filter_unlisted_posts() 372 371 * 373 * @param array $args A rguments for filtering posts in the widget.372 * @param array $args A. 374 373 * 375 374 * @return array $args … … 392 391 393 392 /** 394 * Filter the arguments for the Postwidget.393 * Filter the arguments for the widget. 395 394 * 396 395 * @since 1.1 … … 400 399 * @return array $args 401 400 */ 402 $args = apply_filters( 'unlisted_post_widget_args', $args ); 403 404 return $args; 405 406 } 407 408 /** 409 * Filter the list of pages in the Recent Pages widget. 410 * 411 * This works a little different to the Post widget filtering above 412 * because the page widget uses `wp_list_pages` to get the pages instead 413 * for some reason and expects a comma seperated string of page IDs. 401 return apply_filters( 'unlisted_post_widget_args', $args ); 402 403 } 404 405 /** 406 * Filter the pages widget. 414 407 * 415 408 * @see wp_list_pages() 416 409 * 417 * @param array $args A rguments for filtering pages in the widget.410 * @param array $args A. 418 411 * 419 412 * @return array $args … … 432 425 433 426 /** 434 * Filter the arguments for the Pagewidget.427 * Filter the arguments for the widget. 435 428 * 436 429 * @since 1.1 … … 441 434 */ 442 435 return apply_filters( 'unlisted_page_widget_args', $args ); 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 443 474 444 475 }
Note: See TracChangeset
for help on using the changeset viewer.