Ticket #41452: 41452-wp-includes.diff
File 41452-wp-includes.diff, 398.2 KB (added by , 4 years ago) |
---|
-
src/wp-includes/cache.php
291 291 * Holds the cached objects. 292 292 * 293 293 * @since 2.0.0 294 * @access private295 294 * @var array 296 295 */ 297 296 private $cache = array(); … … 300 299 * The amount of times the cache data was already stored in the cache. 301 300 * 302 301 * @since 2.5.0 303 * @access public304 302 * @var int 305 303 */ 306 304 public $cache_hits = 0; … … 309 307 * Amount of times the cache did not have the request in cache. 310 308 * 311 309 * @since 2.0.0 312 * @access public313 310 * @var int 314 311 */ 315 312 public $cache_misses = 0; … … 318 315 * List of global cache groups. 319 316 * 320 317 * @since 3.0.0 321 * @access protected322 318 * @var array 323 319 */ 324 320 protected $global_groups = array(); … … 327 323 * The blog prefix to prepend to keys in non-global groups. 328 324 * 329 325 * @since 3.5.0 330 * @access private331 326 * @var int 332 327 */ 333 328 private $blog_prefix; … … 336 331 * Holds the value of is_multisite(). 337 332 * 338 333 * @since 3.5.0 339 * @access private340 334 * @var bool 341 335 */ 342 336 private $multisite; … … 345 339 * Makes private properties readable for backward compatibility. 346 340 * 347 341 * @since 4.0.0 348 * @access public349 342 * 350 343 * @param string $name Property to get. 351 344 * @return mixed Property. … … 358 351 * Makes private properties settable for backward compatibility. 359 352 * 360 353 * @since 4.0.0 361 * @access public362 354 * 363 355 * @param string $name Property to set. 364 356 * @param mixed $value Property value. … … 372 364 * Makes private properties checkable for backward compatibility. 373 365 * 374 366 * @since 4.0.0 375 * @access public376 367 * 377 368 * @param string $name Property to check if set. 378 369 * @return bool Whether the property is set. … … 385 376 * Makes private properties un-settable for backward compatibility. 386 377 * 387 378 * @since 4.0.0 388 * @access public389 379 * 390 380 * @param string $name Property to unset. 391 381 */ … … 397 387 * Adds data to the cache if it doesn't already exist. 398 388 * 399 389 * @since 2.0.0 400 * @access public401 390 * 402 391 * @uses WP_Object_Cache::_exists() Checks to see if the cache already has data. 403 392 * @uses WP_Object_Cache::set() Sets the data after the checking the cache … … 430 419 * Sets the list of global cache groups. 431 420 * 432 421 * @since 3.0.0 433 * @access public434 422 * 435 423 * @param array $groups List of groups that are global. 436 424 */ … … 445 433 * Decrements numeric cache item's value. 446 434 * 447 435 * @since 3.3.0 448 * @access public449 436 * 450 437 * @param int|string $key The cache key to decrement. 451 438 * @param int $offset Optional. The amount by which to decrement the item's value. Default 1. … … 481 468 * If the cache key does not exist in the group, then nothing will happen. 482 469 * 483 470 * @since 2.0.0 484 * @access public485 471 * 486 472 * @param int|string $key What the contents in the cache are called. 487 473 * @param string $group Optional. Where the cache contents are grouped. Default 'default'. … … 506 492 * Clears the object cache of all data. 507 493 * 508 494 * @since 2.0.0 509 * @access public510 495 * 511 496 * @return true Always returns true. 512 497 */ … … 526 511 * On failure, the number of cache misses will be incremented. 527 512 * 528 513 * @since 2.0.0 529 * @access public530 514 * 531 515 * @param int|string $key What the contents in the cache are called. 532 516 * @param string $group Optional. Where the cache contents are grouped. Default 'default'. … … 561 545 * Increments numeric cache item's value. 562 546 * 563 547 * @since 3.3.0 564 * @access public565 548 * 566 549 * @param int|string $key The cache key to increment 567 550 * @param int $offset Optional. The amount by which to increment the item's value. Default 1. … … 595 578 * Replaces the contents in the cache, if contents already exist. 596 579 * 597 580 * @since 2.0.0 598 * @access public599 581 * 600 582 * @see WP_Object_Cache::set() 601 583 * … … 623 605 * Resets cache keys. 624 606 * 625 607 * @since 3.0.0 626 * @access public627 608 * 628 609 * @deprecated 3.5.0 Use switch_to_blog() 629 610 * @see switch_to_blog() … … 651 632 * more for cache plugins which use files. 652 633 * 653 634 * @since 2.0.0 654 * @access public655 635 * 656 636 * @param int|string $key What to call the contents in the cache. 657 637 * @param mixed $data The contents to store in the cache. … … 680 660 * key and the data. 681 661 * 682 662 * @since 2.0.0 683 * @access public684 663 */ 685 664 public function stats() { 686 665 echo "<p>"; … … 700 679 * This changes the blog ID used to create keys in blog specific groups. 701 680 * 702 681 * @since 3.5.0 703 * @access public704 682 * 705 683 * @param int $blog_id Blog ID. 706 684 */ … … 713 691 * Serves as a utility function to determine whether a key exists in the cache. 714 692 * 715 693 * @since 3.4.0 716 * @access protected717 694 * 718 695 * @param int|string $key Cache key to check for existence. 719 696 * @param string $group Cache group for the key existence check. -
src/wp-includes/class-http.php
98 98 * Please note: The only URI that are supported in the HTTP Transport implementation 99 99 * are the HTTP and HTTPS protocols. 100 100 * 101 * @access public102 101 * @since 2.7.0 103 102 * 104 103 * @param string $url The request URL. … … 428 427 * Normalizes cookies for using in Requests. 429 428 * 430 429 * @since 4.6.0 431 * @access public432 430 * @static 433 431 * 434 432 * @param array $cookies List of cookies to send with the request. … … 456 454 * specification for compatibility purposes. 457 455 * 458 456 * @since 4.6.0 459 * @access public460 457 * @static 461 458 * 462 459 * @param string $location URL to redirect to. … … 489 486 * Tests which transports are capable of supporting the request. 490 487 * 491 488 * @since 3.2.0 492 * @access public493 489 * 494 490 * @param array $args Request arguments 495 491 * @param string $url URL to Request … … 539 535 * @since 3.2.0 540 536 * 541 537 * @static 542 * @access private543 538 * 544 539 * @param string $url URL to Request 545 540 * @param array $args Request arguments … … 581 576 * 582 577 * Used for sending data that is expected to be in the body. 583 578 * 584 * @access public585 579 * @since 2.7.0 586 580 * 587 581 * @param string $url The request URL. … … 599 593 * 600 594 * Used for sending data that is expected to be in the body. 601 595 * 602 * @access public603 596 * @since 2.7.0 604 597 * 605 598 * @param string $url The request URL. … … 617 610 * 618 611 * Used for sending data that is expected to be in the body. 619 612 * 620 * @access public621 613 * @since 2.7.0 622 614 * 623 615 * @param string $url The request URL. … … 633 625 /** 634 626 * Parses the responses and splits the parts into headers and body. 635 627 * 636 * @access public637 628 * @static 638 629 * @since 2.7.0 639 630 * … … 652 643 * If an array is given then it is assumed to be raw header data with numeric keys with the 653 644 * headers as the values. No headers must be passed that were already processed. 654 645 * 655 * @access public656 646 * @static 657 647 * @since 2.7.0 658 648 * … … 730 720 * which are each parsed into strings and added to the Cookie: header (within the arguments array). 731 721 * Edits the array by reference. 732 722 * 733 * @access public734 723 * @since 2.8.0 735 724 * @static 736 725 * … … 761 750 * 762 751 * @link https://tools.ietf.org/html/rfc2616#section-19.4.6 Process for chunked decoding. 763 752 * 764 * @access public765 753 * @since 2.7.0 766 754 * @static 767 755 * … … 811 799 * are supported, eg *.wordpress.org will allow for all subdomains of wordpress.org to be contacted. 812 800 * 813 801 * @since 2.8.0 814 * @access public815 802 * @link https://core.trac.wordpress.org/ticket/8927 Allow preventing external requests. 816 803 * @link https://core.trac.wordpress.org/ticket/14636 Allow wildcard domains in WP_ACCESSIBLE_HOSTS 817 804 * … … 871 858 /** 872 859 * Used as a wrapper for PHP's parse_url() function that handles edgecases in < PHP 5.4.7. 873 860 * 874 * @access protected875 861 * @deprecated 4.4.0 Use wp_parse_url() 876 862 * @see wp_parse_url() 877 863 * … … 892 878 * @since 3.4.0 893 879 * 894 880 * @static 895 * @access public896 881 * 897 882 * @param string $maybe_relative_path The URL which might be relative 898 883 * @param string $url The URL which $maybe_relative_path is relative to … … 963 948 * Handles HTTP Redirects and follows them if appropriate. 964 949 * 965 950 * @since 3.7.0 966 * @access public967 951 * @static 968 952 * 969 953 * @param string $url The URL which was requested. … … 1020 1004 * @link http://home.deds.nl/~aeron/regex/ for IPv6 regex 1021 1005 * 1022 1006 * @since 3.7.0 1023 * @access public1024 1007 * @static 1025 1008 * 1026 1009 * @param string $maybe_ip A suspected IP address -
src/wp-includes/class-oembed.php
22 22 * A list of oEmbed providers. 23 23 * 24 24 * @since 2.9.0 25 * @access public26 25 * @var array 27 26 */ 28 27 public $providers = array(); … … 31 30 * A list of an early oEmbed providers. 32 31 * 33 32 * @since 4.0.0 34 * @access public35 33 * @static 36 34 * @var array 37 35 */ … … 41 39 * A list of private/protected methods, used for backward compatibility. 42 40 * 43 41 * @since 4.2.0 44 * @access private45 42 * @var array 46 43 */ 47 44 private $compat_methods = array( '_fetch_with_format', '_parse_json', '_parse_xml', '_parse_xml_body' ); … … 50 47 * Constructor. 51 48 * 52 49 * @since 2.9.0 53 * @access public54 50 */ 55 51 public function __construct() { 56 52 $host = urlencode( home_url() ); … … 211 207 * Exposes private/protected methods for backward compatibility. 212 208 * 213 209 * @since 4.0.0 214 * @access public215 210 * 216 211 * @param callable $name Method to call. 217 212 * @param array $arguments Arguments to pass when calling. … … 228 223 * Takes a URL and returns the corresponding oEmbed provider's URL, if there is one. 229 224 * 230 225 * @since 4.0.0 231 * @access public232 226 * 233 227 * @see WP_oEmbed::discover() 234 228 * … … 275 269 * 276 270 * @static 277 271 * @since 4.0.0 278 * @access public279 272 * 280 273 * @see wp_oembed_add_provider() 281 274 * … … 302 295 * The just-in-time removal is for the benefit of the {@see 'oembed_providers'} filter. 303 296 * 304 297 * @since 4.0.0 305 * @access public306 298 * @static 307 299 * 308 300 * @see wp_oembed_remove_provider() … … 324 316 * @see WP_oEmbed::fetch() 325 317 * 326 318 * @since 4.8.0 327 * @access public328 319 * 329 320 * @param string $url The URL to the content that should be attempted to be embedded. 330 321 * @param array|string $args Optional. Arguments, usually passed from a shortcode. Default empty. … … 355 346 * @see WP_oEmbed::data2html() 356 347 * 357 348 * @since 2.9.0 358 * @access public359 349 * 360 350 * @param string $url The URL to the content that should be attempted to be embedded. 361 351 * @param array|string $args Optional. Arguments, usually passed from a shortcode. Default empty. … … 405 395 * Attempts to discover link tags at the given URL for an oEmbed provider. 406 396 * 407 397 * @since 2.9.0 408 * @access public409 398 * 410 399 * @param string $url The URL that should be inspected for discovery `<link>` tags. 411 400 * @return false|string False on failure, otherwise the oEmbed provider URL. … … 489 478 * Connects to a oEmbed provider and returns the result. 490 479 * 491 480 * @since 2.9.0 492 * @access public493 481 * 494 482 * @param string $provider The URL to the oEmbed provider. 495 483 * @param string $url The URL to the content that is desired to be embedded. … … 527 515 * Fetches result from an oEmbed provider for a specific format and complete provider URL 528 516 * 529 517 * @since 3.0.0 530 * @access private531 518 * 532 519 * @param string $provider_url_with_args URL to the provider with full arguments list (url, maxheight, etc.) 533 520 * @param string $format Format to use … … 552 539 * Parses a json response body. 553 540 * 554 541 * @since 3.0.0 555 * @access private556 542 * 557 543 * @param string $response_body 558 544 * @return object|false … … 566 552 * Parses an XML response body. 567 553 * 568 554 * @since 3.0.0 569 * @access private570 555 * 571 556 * @param string $response_body 572 557 * @return object|false … … 590 575 * Serves as a helper function for parsing an XML response body. 591 576 * 592 577 * @since 3.6.0 593 * @access private594 578 * 595 579 * @param string $response_body 596 580 * @return stdClass|false … … 628 612 * Converts a data object from WP_oEmbed::fetch() and returns the HTML. 629 613 * 630 614 * @since 2.9.0 631 * @access public632 615 * 633 616 * @param object $data A data object result from an oEmbed provider. 634 617 * @param string $url The URL to the content that is desired to be embedded. … … 685 668 * 686 669 * @since 2.9.0 as strip_scribd_newlines() 687 670 * @since 3.0.0 688 * @access public689 671 * 690 672 * @param string $html Existing HTML. 691 673 * @param object $data Data object from WP_oEmbed::data2html() -
src/wp-includes/class-walker-category-dropdown.php
20 20 * What the class handles. 21 21 * 22 22 * @since 2.1.0 23 * @access private24 23 * @var string 25 24 * 26 25 * @see Walker::$tree_type … … 31 30 * Database fields to use. 32 31 * 33 32 * @since 2.1.0 34 * @access public35 33 * @todo Decouple this 36 34 * @var array 37 35 * … … 43 41 * Starts the element output. 44 42 * 45 43 * @since 2.1.0 46 * @access public47 44 * 48 45 * @see Walker::start_el() 49 46 * -
src/wp-includes/class-walker-category.php
20 20 * What the class handles. 21 21 * 22 22 * @since 2.1.0 23 * @access public24 23 * @var string 25 24 * 26 25 * @see Walker::$tree_type … … 31 30 * Database fields to use. 32 31 * 33 32 * @since 2.1.0 34 * @access public35 33 * @var array 36 34 * 37 35 * @see Walker::$db_fields … … 43 41 * Starts the list before the elements are added. 44 42 * 45 43 * @since 2.1.0 46 * @access public47 44 * 48 45 * @see Walker::start_lvl() 49 46 * … … 64 61 * Ends the list of after the elements are added. 65 62 * 66 63 * @since 2.1.0 67 * @access public68 64 * 69 65 * @see Walker::end_lvl() 70 66 * … … 85 81 * Starts the element output. 86 82 * 87 83 * @since 2.1.0 88 * @access public89 84 * 90 85 * @see Walker::start_el() 91 86 * … … 215 210 * Ends the element output, if needed. 216 211 * 217 212 * @since 2.1.0 218 * @access public219 213 * 220 214 * @see Walker::end_el() 221 215 * -
src/wp-includes/class-walker-comment.php
20 20 * What the class handles. 21 21 * 22 22 * @since 2.7.0 23 * @access public24 23 * @var string 25 24 * 26 25 * @see Walker::$tree_type … … 31 30 * Database fields to use. 32 31 * 33 32 * @since 2.7.0 34 * @access public35 33 * @var array 36 34 * 37 35 * @see Walker::$db_fields … … 43 41 * Starts the list before the elements are added. 44 42 * 45 43 * @since 2.7.0 46 * @access public47 44 * 48 45 * @see Walker::start_lvl() 49 46 * @global int $comment_depth … … 72 69 * Ends the list of items after the elements are added. 73 70 * 74 71 * @since 2.7.0 75 * @access public76 72 * 77 73 * @see Walker::end_lvl() 78 74 * @global int $comment_depth … … 118 114 * 2.2 119 115 * 120 116 * @since 2.7.0 121 * @access public122 117 * 123 118 * @see Walker::display_element() 124 119 * @see wp_list_comments() … … 157 152 * Starts the element output. 158 153 * 159 154 * @since 2.7.0 160 * @access public161 155 * 162 156 * @see Walker::start_el() 163 157 * @see wp_list_comments() … … 201 195 * Ends the element output, if needed. 202 196 * 203 197 * @since 2.7.0 204 * @access public205 198 * 206 199 * @see Walker::end_el() 207 200 * @see wp_list_comments() … … 228 221 * Outputs a pingback comment. 229 222 * 230 223 * @since 3.6.0 231 * @access protected232 224 * 233 225 * @see wp_list_comments() 234 226 * … … 250 242 * Outputs a single comment. 251 243 * 252 244 * @since 3.6.0 253 * @access protected254 245 * 255 246 * @see wp_list_comments() 256 247 * … … 314 305 * Outputs a comment in the HTML5 format. 315 306 * 316 307 * @since 3.6.0 317 * @access protected318 308 * 319 309 * @see wp_list_comments() 320 310 * -
src/wp-includes/class-walker-nav-menu.php
19 19 * What the class handles. 20 20 * 21 21 * @since 3.0.0 22 * @access public23 22 * @var string 24 23 * 25 24 * @see Walker::$tree_type … … 30 29 * Database fields to use. 31 30 * 32 31 * @since 3.0.0 33 * @access public34 32 * @todo Decouple this. 35 33 * @var array 36 34 * -
src/wp-includes/class-walker-page-dropdown.php
20 20 * What the class handles. 21 21 * 22 22 * @since 2.1.0 23 * @access public24 23 * @var string 25 24 * 26 25 * @see Walker::$tree_type … … 31 30 * Database fields to use. 32 31 * 33 32 * @since 2.1.0 34 * @access public35 33 * @var array 36 34 * 37 35 * @see Walker::$db_fields … … 43 41 * Starts the element output. 44 42 * 45 43 * @since 2.1.0 46 * @access public47 44 * 48 45 * @see Walker::start_el() 49 46 * -
src/wp-includes/class-walker-page.php
20 20 * What the class handles. 21 21 * 22 22 * @since 2.1.0 23 * @access public24 23 * @var string 25 24 * 26 25 * @see Walker::$tree_type … … 31 30 * Database fields to use. 32 31 * 33 32 * @since 2.1.0 34 * @access private35 33 * @var array 36 34 * 37 35 * @see Walker::$db_fields … … 43 41 * Outputs the beginning of the current level in the tree before elements are output. 44 42 * 45 43 * @since 2.1.0 46 * @access public47 44 * 48 45 * @see Walker::start_lvl() 49 46 * … … 68 65 * Outputs the end of the current level in the tree after elements are output. 69 66 * 70 67 * @since 2.1.0 71 * @access public72 68 * 73 69 * @see Walker::end_lvl() 74 70 * … … 94 90 * 95 91 * @see Walker::start_el() 96 92 * @since 2.1.0 97 * @access public98 93 * 99 94 * @param string $output Used to append additional content. Passed by reference. 100 95 * @param WP_Post $page Page data object. … … 214 209 * Outputs the end of the current element in the tree. 215 210 * 216 211 * @since 2.1.0 217 * @access public218 212 * 219 213 * @see Walker::end_el() 220 214 * -
src/wp-includes/class-wp-admin-bar.php
33 33 } 34 34 35 35 /** 36 * @access public37 36 */ 38 37 public function initialize() { 39 38 $this->user = new stdClass; … … 100 99 * 101 100 * @since 3.1.0 102 101 * @since 4.5.0 Added the ability to pass 'lang' and 'dir' meta data. 103 * @access public104 102 * 105 103 * @param array $args { 106 104 * Arguments for adding a node. … … 258 256 } 259 257 260 258 /** 261 * @access public262 259 */ 263 260 public function render() { 264 261 $root = $this->_bind(); … … 572 569 } 573 570 574 571 /** 575 * @access public576 572 */ 577 573 public function add_menus() { 578 574 // User related, aligned right. -
src/wp-includes/class-wp-ajax-response.php
39 39 * </response> 40 40 * 41 41 * @since 2.1.0 42 * @access public43 42 * 44 43 * @param string|array $args { 45 44 * Optional. An array or string of XML response arguments. -
src/wp-includes/class-wp-comment-query.php
20 20 * SQL for database query. 21 21 * 22 22 * @since 4.0.1 23 * @access public24 23 * @var string 25 24 */ 26 25 public $request; … … 29 28 * Metadata query container 30 29 * 31 30 * @since 3.5.0 32 * @access public33 31 * @var object WP_Meta_Query 34 32 */ 35 33 public $meta_query = false; … … 38 36 * Metadata query clauses. 39 37 * 40 38 * @since 4.4.0 41 * @access protected42 39 * @var array 43 40 */ 44 41 protected $meta_query_clauses; … … 47 44 * SQL query clauses. 48 45 * 49 46 * @since 4.4.0 50 * @access protected51 47 * @var array 52 48 */ 53 49 protected $sql_clauses = array( … … 65 61 * Stored after the {@see 'comments_clauses'} filter is run on the compiled WHERE sub-clauses. 66 62 * 67 63 * @since 4.4.2 68 * @access protected69 64 * @var string 70 65 */ 71 66 protected $filtered_where_clause; … … 74 69 * Date query container 75 70 * 76 71 * @since 3.7.0 77 * @access public78 72 * @var object WP_Date_Query 79 73 */ 80 74 public $date_query = false; … … 83 77 * Query vars set by the user. 84 78 * 85 79 * @since 3.1.0 86 * @access public87 80 * @var array 88 81 */ 89 82 public $query_vars; … … 92 85 * Default values for query vars. 93 86 * 94 87 * @since 4.2.0 95 * @access public96 88 * @var array 97 89 */ 98 90 public $query_var_defaults; … … 101 93 * List of comments located by the query. 102 94 * 103 95 * @since 4.0.0 104 * @access public105 96 * @var array 106 97 */ 107 98 public $comments; … … 110 101 * The amount of found comments for the current query. 111 102 * 112 103 * @since 4.4.0 113 * @access public114 104 * @var int 115 105 */ 116 106 public $found_comments = 0; … … 119 109 * The number of pages. 120 110 * 121 111 * @since 4.4.0 122 * @access public123 112 * @var int 124 113 */ 125 114 public $max_num_pages = 0; … … 128 117 * Make private/protected methods readable for backward compatibility. 129 118 * 130 119 * @since 4.0.0 131 * @access public132 120 * 133 121 * @param callable $name Method to call. 134 122 * @param array $arguments Arguments to pass when calling. … … 152 140 * `$hierarchical`, and `$update_comment_post_cache` were added. 153 141 * @since 4.5.0 Introduced the `$author_url` argument. 154 142 * @since 4.6.0 Introduced the `$cache_domain` argument. 155 * @access public156 143 * 157 144 * @param string|array $query { 158 145 * Optional. Array or query string of comment query parameters. Default empty. … … 317 304 * 318 305 * @since 4.2.0 Extracted from WP_Comment_Query::query(). 319 306 * 320 * @access public321 307 * 322 308 * @param string|array $query WP_Comment_Query arguments. See WP_Comment_Query::__construct() 323 309 */ … … 347 333 * 'post__not_in', 'include_unapproved', 'type__in', and 'type__not_in' 348 334 * arguments to $query_vars. 349 335 * @since 4.2.0 Moved parsing to WP_Comment_Query::parse_query(). 350 * @access public351 336 * 352 337 * @param string|array $query Array or URL query string of parameters. 353 338 * @return array|int List of comments, or number of comments when 'count' is passed as a query var. … … 361 346 * Get a list of comments matching the query vars. 362 347 * 363 348 * @since 4.2.0 364 * @access public365 349 * 366 350 * @global wpdb $wpdb WordPress database abstraction object. 367 351 * … … 476 460 * Used internally to get a list of comment IDs matching the query vars. 477 461 * 478 462 * @since 4.4.0 479 * @access protected480 463 * 481 464 * @global wpdb $wpdb WordPress database abstraction object. 482 465 */ … … 906 889 * query if the limit clause was used. 907 890 * 908 891 * @since 4.6.0 909 * @access private910 892 * 911 893 * @global wpdb $wpdb WordPress database abstraction object. 912 894 */ … … 935 917 * the descendant trees for all matched top-level comments. 936 918 * 937 919 * @since 4.4.0 938 * @access protected 939 * 920 * 940 921 * @global wpdb $wpdb WordPress database abstraction object. 941 922 * 942 923 * @param array $comments Array of top-level comments whose descendants should be filled in. … … 1050 1031 * Used internally to generate an SQL string for searching across multiple columns 1051 1032 * 1052 1033 * @since 3.1.0 1053 * @access protected1054 1034 * 1055 1035 * @global wpdb $wpdb WordPress database abstraction object. 1056 1036 * … … 1075 1055 * Parse and sanitize 'orderby' keys passed to the comment query. 1076 1056 * 1077 1057 * @since 4.2.0 1078 * @access protected1079 1058 * 1080 1059 * @global wpdb $wpdb WordPress database abstraction object. 1081 1060 * … … 1139 1118 * Parse an 'order' query variable and cast it to ASC or DESC as necessary. 1140 1119 * 1141 1120 * @since 4.2.0 1142 * @access protected1143 1121 * 1144 1122 * @param string $order The 'order' query variable. 1145 1123 * @return string The sanitized 'order' query variable. -
src/wp-includes/class-wp-comment.php
18 18 * Comment ID. 19 19 * 20 20 * @since 4.4.0 21 * @access public22 21 * @var int 23 22 */ 24 23 public $comment_ID; … … 27 26 * ID of the post the comment is associated with. 28 27 * 29 28 * @since 4.4.0 30 * @access public31 29 * @var int 32 30 */ 33 31 public $comment_post_ID = 0; … … 36 34 * Comment author name. 37 35 * 38 36 * @since 4.4.0 39 * @access public40 37 * @var string 41 38 */ 42 39 public $comment_author = ''; … … 45 42 * Comment author email address. 46 43 * 47 44 * @since 4.4.0 48 * @access public49 45 * @var string 50 46 */ 51 47 public $comment_author_email = ''; … … 54 50 * Comment author URL. 55 51 * 56 52 * @since 4.4.0 57 * @access public58 53 * @var string 59 54 */ 60 55 public $comment_author_url = ''; … … 63 58 * Comment author IP address (IPv4 format). 64 59 * 65 60 * @since 4.4.0 66 * @access public67 61 * @var string 68 62 */ 69 63 public $comment_author_IP = ''; … … 72 66 * Comment date in YYYY-MM-DD HH:MM:SS format. 73 67 * 74 68 * @since 4.4.0 75 * @access public76 69 * @var string 77 70 */ 78 71 public $comment_date = '0000-00-00 00:00:00'; … … 81 74 * Comment GMT date in YYYY-MM-DD HH::MM:SS format. 82 75 * 83 76 * @since 4.4.0 84 * @access public85 77 * @var string 86 78 */ 87 79 public $comment_date_gmt = '0000-00-00 00:00:00'; … … 90 82 * Comment content. 91 83 * 92 84 * @since 4.4.0 93 * @access public94 85 * @var string 95 86 */ 96 87 public $comment_content; … … 99 90 * Comment karma count. 100 91 * 101 92 * @since 4.4.0 102 * @access public103 93 * @var int 104 94 */ 105 95 public $comment_karma = 0; … … 108 98 * Comment approval status. 109 99 * 110 100 * @since 4.4.0 111 * @access public112 101 * @var string 113 102 */ 114 103 public $comment_approved = '1'; … … 117 106 * Comment author HTTP user agent. 118 107 * 119 108 * @since 4.4.0 120 * @access public121 109 * @var string 122 110 */ 123 111 public $comment_agent = ''; … … 126 114 * Comment type. 127 115 * 128 116 * @since 4.4.0 129 * @access public130 117 * @var string 131 118 */ 132 119 public $comment_type = ''; … … 135 122 * Parent comment ID. 136 123 * 137 124 * @since 4.4.0 138 * @access public139 125 * @var int 140 126 */ 141 127 public $comment_parent = 0; … … 144 130 * Comment author ID. 145 131 * 146 132 * @since 4.4.0 147 * @access public148 133 * @var int 149 134 */ 150 135 public $user_id = 0; … … 153 138 * Comment children. 154 139 * 155 140 * @since 4.4.0 156 * @access protected157 141 * @var array 158 142 */ 159 143 protected $children; … … 162 146 * Whether children have been populated for this comment object. 163 147 * 164 148 * @since 4.4.0 165 * @access protected166 149 * @var bool 167 150 */ 168 151 protected $populated_children = false; … … 171 154 * Post fields. 172 155 * 173 156 * @since 4.4.0 174 * @access protected175 157 * @var array 176 158 */ 177 159 protected $post_fields = array( 'post_author', 'post_date', 'post_date_gmt', 'post_content', 'post_title', 'post_excerpt', 'post_status', 'comment_status', 'ping_status', 'post_name', 'to_ping', 'pinged', 'post_modified', 'post_modified_gmt', 'post_content_filtered', 'post_parent', 'guid', 'menu_order', 'post_type', 'post_mime_type', 'comment_count' ); … … 180 162 * Retrieves a WP_Comment instance. 181 163 * 182 164 * @since 4.4.0 183 * @access public184 165 * @static 185 166 * 186 167 * @global wpdb $wpdb WordPress database abstraction object. … … 217 198 * Populates properties with object vars. 218 199 * 219 200 * @since 4.4.0 220 * @access public221 201 * 222 202 * @param WP_Comment $comment Comment object. 223 203 */ … … 231 211 * Convert object to array. 232 212 * 233 213 * @since 4.4.0 234 * @access public235 214 * 236 215 * @return array Object as array. 237 216 */ … … 243 222 * Get the children of a comment. 244 223 * 245 224 * @since 4.4.0 246 * @access public247 225 * 248 226 * @param array $args { 249 227 * Array of arguments used to pass to get_comments() and determine format. … … 318 296 * Used by `WP_Comment_Query` when bulk-filling descendants. 319 297 * 320 298 * @since 4.4.0 321 * @access public322 299 * 323 300 * @param WP_Comment $child Child comment. 324 301 */ … … 330 307 * Get a child comment by ID. 331 308 * 332 309 * @since 4.4.0 333 * @access public334 310 * 335 311 * @param int $child_id ID of the child. 336 312 * @return WP_Comment|bool Returns the comment object if found, otherwise false. … … 363 339 * If `$name` matches a post field, the comment post will be loaded and the post's value checked. 364 340 * 365 341 * @since 4.4.0 366 * @access public367 342 * 368 343 * @param string $name Property name. 369 344 * @return bool … … 381 356 * If `$name` matches a post field, the comment post will be loaded and the post's value returned. 382 357 * 383 358 * @since 4.4.0 384 * @access public385 359 * 386 360 * @param string $name 387 361 * @return mixed -
src/wp-includes/class-wp-customize-control.php
22 22 * @since 4.1.0 23 23 * 24 24 * @static 25 * @access protected26 25 * @var int 27 26 */ 28 27 protected static $instance_count = 0; … … 31 30 * Order in which this instance was created in relation to other instances. 32 31 * 33 32 * @since 4.1.0 34 * @access public35 33 * @var int 36 34 */ 37 35 public $instance_number; … … 40 38 * Customizer manager. 41 39 * 42 40 * @since 3.4.0 43 * @access public44 41 * @var WP_Customize_Manager 45 42 */ 46 43 public $manager; … … 49 46 * Control ID. 50 47 * 51 48 * @since 3.4.0 52 * @access public53 49 * @var string 54 50 */ 55 51 public $id; … … 58 54 * All settings tied to the control. 59 55 * 60 56 * @since 3.4.0 61 * @access public62 57 * @var array 63 58 */ 64 59 public $settings; … … 67 62 * The primary setting for the control (if there is one). 68 63 * 69 64 * @since 3.4.0 70 * @access public71 65 * @var string 72 66 */ 73 67 public $setting = 'default'; … … 79 73 * of the associated `$settings`. 80 74 * 81 75 * @since 4.5.0 82 * @access public83 76 * @var string 84 77 */ 85 78 public $capability; … … 88 81 * Order priority to load the control in Customizer. 89 82 * 90 83 * @since 3.4.0 91 * @access public92 84 * @var int 93 85 */ 94 86 public $priority = 10; … … 97 89 * Section the control belongs to. 98 90 * 99 91 * @since 3.4.0 100 * @access public101 92 * @var string 102 93 */ 103 94 public $section = ''; … … 106 97 * Label for the control. 107 98 * 108 99 * @since 3.4.0 109 * @access public110 100 * @var string 111 101 */ 112 102 public $label = ''; … … 115 105 * Description for the control. 116 106 * 117 107 * @since 4.0.0 118 * @access public119 108 * @var string 120 109 */ 121 110 public $description = ''; … … 124 113 * List of choices for 'radio' or 'select' type controls, where values are the keys, and labels are the values. 125 114 * 126 115 * @since 3.4.0 127 * @access public128 116 * @var array 129 117 */ 130 118 public $choices = array(); … … 135 123 * Not used for 'checkbox', 'radio', 'select', 'textarea', or 'dropdown-pages' control types. 136 124 * 137 125 * @since 4.0.0 138 * @access public139 126 * @var array 140 127 */ 141 128 public $input_attrs = array(); … … 144 131 * Show UI for adding new content, currently only used for the dropdown-pages control. 145 132 * 146 133 * @since 4.7.0 147 * @access public148 134 * @var bool 149 135 */ 150 136 public $allow_addition = false; … … 152 138 /** 153 139 * @deprecated It is better to just call the json() method 154 140 * @since 3.4.0 155 * @access public156 141 * @var array 157 142 */ 158 143 public $json = array(); … … 161 146 * Control's Type. 162 147 * 163 148 * @since 3.4.0 164 * @access public165 149 * @var string 166 150 */ 167 151 public $type = 'text'; … … 170 154 * Callback. 171 155 * 172 156 * @since 4.0.0 173 * @access public174 157 * 175 158 * @see WP_Customize_Control::active() 176 159 * -
src/wp-includes/class-wp-customize-manager.php
25 25 * An instance of the theme being previewed. 26 26 * 27 27 * @since 3.4.0 28 * @access protected29 28 * @var WP_Theme 30 29 */ 31 30 protected $theme; … … 34 33 * The directory name of the previously active theme (within the theme_root). 35 34 * 36 35 * @since 3.4.0 37 * @access protected38 36 * @var string 39 37 */ 40 38 protected $original_stylesheet; … … 43 41 * Whether this is a Customizer pageload. 44 42 * 45 43 * @since 3.4.0 46 * @access protected47 44 * @var bool 48 45 */ 49 46 protected $previewing = false; … … 52 49 * Methods and properties dealing with managing widgets in the Customizer. 53 50 * 54 51 * @since 3.9.0 55 * @access public56 52 * @var WP_Customize_Widgets 57 53 */ 58 54 public $widgets; … … 61 57 * Methods and properties dealing with managing nav menus in the Customizer. 62 58 * 63 59 * @since 4.3.0 64 * @access public65 60 * @var WP_Customize_Nav_Menus 66 61 */ 67 62 public $nav_menus; … … 70 65 * Methods and properties dealing with selective refresh in the Customizer preview. 71 66 * 72 67 * @since 4.5.0 73 * @access public74 68 * @var WP_Customize_Selective_Refresh 75 69 */ 76 70 public $selective_refresh; … … 79 73 * Registered instances of WP_Customize_Setting. 80 74 * 81 75 * @since 3.4.0 82 * @access protected83 76 * @var array 84 77 */ 85 78 protected $settings = array(); … … 88 81 * Sorted top-level instances of WP_Customize_Panel and WP_Customize_Section. 89 82 * 90 83 * @since 4.0.0 91 * @access protected92 84 * @var array 93 85 */ 94 86 protected $containers = array(); … … 97 89 * Registered instances of WP_Customize_Panel. 98 90 * 99 91 * @since 4.0.0 100 * @access protected101 92 * @var array 102 93 */ 103 94 protected $panels = array(); … … 106 97 * List of core components. 107 98 * 108 99 * @since 4.5.0 109 * @access protected110 100 * @var array 111 101 */ 112 102 protected $components = array( 'widgets', 'nav_menus' ); … … 115 105 * Registered instances of WP_Customize_Section. 116 106 * 117 107 * @since 3.4.0 118 * @access protected119 108 * @var array 120 109 */ 121 110 protected $sections = array(); … … 124 113 * Registered instances of WP_Customize_Control. 125 114 * 126 115 * @since 3.4.0 127 * @access protected128 116 * @var array 129 117 */ 130 118 protected $controls = array(); … … 133 121 * Panel types that may be rendered from JS templates. 134 122 * 135 123 * @since 4.3.0 136 * @access protected137 124 * @var array 138 125 */ 139 126 protected $registered_panel_types = array(); … … 142 129 * Section types that may be rendered from JS templates. 143 130 * 144 131 * @since 4.3.0 145 * @access protected146 132 * @var array 147 133 */ 148 134 protected $registered_section_types = array(); … … 151 137 * Control types that may be rendered from JS templates. 152 138 * 153 139 * @since 4.1.0 154 * @access protected155 140 * @var array 156 141 */ 157 142 protected $registered_control_types = array(); … … 160 145 * Initial URL being previewed. 161 146 * 162 147 * @since 4.4.0 163 * @access protected164 148 * @var string 165 149 */ 166 150 protected $preview_url; … … 169 153 * URL to link the user to when closing the Customizer. 170 154 * 171 155 * @since 4.4.0 172 * @access protected173 156 * @var string 174 157 */ 175 158 protected $return_url; … … 178 161 * Mapping of 'panel', 'section', 'control' to the ID which should be autofocused. 179 162 * 180 163 * @since 4.4.0 181 * @access protected182 164 * @var array 183 165 */ 184 166 protected $autofocus = array(); … … 187 169 * Messenger channel. 188 170 * 189 171 * @since 4.7.0 190 * @access protected191 172 * @var string 192 173 */ 193 174 protected $messenger_channel; … … 203 184 * Changeset UUID. 204 185 * 205 186 * @since 4.7.0 206 * @access private207 187 * @var string 208 188 */ 209 189 private $_changeset_uuid; … … 212 192 * Changeset post ID. 213 193 * 214 194 * @since 4.7.0 215 * @access private216 195 * @var int|false 217 196 */ 218 197 private $_changeset_post_id; … … 221 200 * Changeset data loaded from a customize_changeset post. 222 201 * 223 202 * @since 4.7.0 224 * @access private225 203 * @var array 226 204 */ 227 205 private $_changeset_data; … … 373 351 * 374 352 * @since 3.4.0 375 353 * @since 4.2.0 Added `$action` param. 376 * @access public377 354 * 378 355 * @param string|null $action Whether the supplied Ajax action is being run. 379 356 * @return bool True if it's an Ajax request, false otherwise. … … 648 625 * Get the changeset UUID. 649 626 * 650 627 * @since 4.7.0 651 * @access public652 628 * 653 629 * @return string UUID. 654 630 */ … … 718 694 * Get the registered panels. 719 695 * 720 696 * @since 4.0.0 721 * @access public722 697 * 723 698 * @return array Panels. 724 699 */ … … 798 773 * Find the changeset post ID for a given changeset UUID. 799 774 * 800 775 * @since 4.7.0 801 * @access public802 776 * 803 777 * @param string $uuid Changeset UUID. 804 778 * @return int|null Returns post ID on success and null on failure. … … 835 809 * Get the changeset post id for the loaded changeset. 836 810 * 837 811 * @since 4.7.0 838 * @access public839 812 * 840 813 * @return int|null Post ID on success or null if there is no post yet saved. 841 814 */ … … 857 830 * Get the data stored in a changeset post. 858 831 * 859 832 * @since 4.7.0 860 * @access protected861 833 * 862 834 * @param int $post_id Changeset post ID. 863 835 * @return array|WP_Error Changeset data or WP_Error on error. … … 887 859 * Get changeset data. 888 860 * 889 861 * @since 4.7.0 890 * @access public891 862 * 892 863 * @return array Changeset data. 893 864 */ … … 913 884 * Starter content setting IDs. 914 885 * 915 886 * @since 4.7.0 916 * @access private917 887 * @var array 918 888 */ 919 889 protected $pending_starter_content_settings_ids = array(); … … 922 892 * Import theme starter content into the customized state. 923 893 * 924 894 * @since 4.7.0 925 * @access public926 895 * 927 896 * @param array $starter_content Starter content. Defaults to `get_theme_starter_content()`. 928 897 */ … … 1315 1284 * Ensure that the attachments are valid and that they have slugs and file name/path. 1316 1285 * 1317 1286 * @since 4.7.0 1318 * @access private1319 1287 * 1320 1288 * @param array $attachments Attachments. 1321 1289 * @return array Prepared attachments. … … 1376 1344 * Save starter content changeset. 1377 1345 * 1378 1346 * @since 4.7.0 1379 * @access private1380 1347 */ 1381 1348 public function _save_starter_content_changeset() { 1382 1349 … … 1485 1452 * @since 3.4.0 1486 1453 * @since 4.1.1 Introduced the `$default` parameter. 1487 1454 * @since 4.6.0 `$default` is now returned early when the setting post value is invalid. 1488 * @access public1489 1455 * 1490 1456 * @see WP_REST_Server::dispatch() 1491 1457 * @see WP_Rest_Request::sanitize_params() … … 1520 1486 * exclusively sourced from `$_POST['customized']`. 1521 1487 * 1522 1488 * @since 4.2.0 1523 * @access public1524 1489 * 1525 1490 * @param string $setting_id ID for the WP_Customize_Setting instance. 1526 1491 * @param mixed $value Post value. … … 1618 1583 * Filter the X-Frame-Options and Content-Security-Policy headers to ensure frontend can load in customizer. 1619 1584 * 1620 1585 * @since 4.7.0 1621 * @access public1622 1586 * 1623 1587 * @param array $headers Headers. 1624 1588 * @return array Headers. … … 1634 1598 * Add customize state query params to a given URL if preview is allowed. 1635 1599 * 1636 1600 * @since 4.7.0 1637 * @access public1638 1601 * @see wp_redirect() 1639 1602 * @see WP_Customize_Manager::get_allowed_url() 1640 1603 * … … 1680 1643 * 1681 1644 * @since 4.0.0 1682 1645 * @deprecated 4.7.0 1683 * @access public1684 1646 */ 1685 1647 public function customize_preview_override_404_status() { 1686 1648 _deprecated_function( __METHOD__, '4.7.0' ); … … 1710 1672 * Print CSS for loading indicators for the Customizer preview. 1711 1673 * 1712 1674 * @since 4.2.0 1713 * @access public1714 1675 */ 1715 1676 public function customize_preview_loading_style() { 1716 1677 ?><style> … … 1741 1702 * work as expected since the parent frame is not being sent the URL to navigate to. 1742 1703 * 1743 1704 * @since 4.7.0 1744 * @access public1745 1705 */ 1746 1706 public function remove_frameless_preview_messenger_channel() { 1747 1707 if ( ! $this->messenger_channel ) { … … 1991 1951 * after sanitizing are marked invalid. 1992 1952 * 1993 1953 * @since 4.6.0 1994 * @access public1995 1954 * 1996 1955 * @see WP_REST_Request::has_valid_params() 1997 1956 * @see WP_Customize_Setting::validate() … … 2058 2017 * `wp.customize.Notification` JS model. 2059 2018 * 2060 2019 * @since 4.6.0 2061 * @access public2062 2020 * 2063 2021 * @param true|WP_Error $validity Setting validity. 2064 2022 * @return true|array If `$validity` was a WP_Error, the error codes will be array-mapped … … 2225 2183 * Save the post for the loaded changeset. 2226 2184 * 2227 2185 * @since 4.7.0 2228 * @access public2229 2186 * 2230 2187 * @param array $args { 2231 2188 * Args for changeset post. … … 2569 2526 * Whether a changeset revision should be made. 2570 2527 * 2571 2528 * @since 4.7.0 2572 * @access private2573 2529 * @var bool 2574 2530 */ 2575 2531 protected $store_changeset_revision; … … 2580 2536 * Note that this will not be called while a changeset post remains in auto-draft status. 2581 2537 * 2582 2538 * @since 4.7.0 2583 * @access private2584 2539 * 2585 2540 * @param bool $post_has_changed Whether the post has changed. 2586 2541 * @param WP_Post $last_revision The last revision post object. … … 2610 2565 * invoking this method. 2611 2566 * 2612 2567 * @since 4.7.0 2613 * @access private2614 2568 * @see _wp_customize_publish_changeset() 2615 2569 * 2616 2570 * @param int $changeset_post_id ID for customize_changeset post. Defaults to the changeset for the current manager instance. … … 2761 2715 * Update stashed theme mod settings. 2762 2716 * 2763 2717 * @since 4.7.0 2764 * @access private2765 2718 * 2766 2719 * @param array $inactive_theme_mod_settings Mapping of stylesheet to arrays of theme mod settings. 2767 2720 * @return array|false Returns array of updated stashed theme mods or false if the update failed or there were no changes. … … 2865 2818 * even though they are not directly created statically with code. 2866 2819 * 2867 2820 * @since 4.2.0 2868 * @access public2869 2821 * 2870 2822 * @param array $setting_ids The setting IDs to add. 2871 2823 * @return array The WP_Customize_Setting objects added. … … 2977 2929 * Retrieve a customize panel. 2978 2930 * 2979 2931 * @since 4.0.0 2980 * @access public2981 2932 * 2982 2933 * @param string $id Panel ID to get. 2983 2934 * @return WP_Customize_Panel|void Requested panel instance, if set. … … 2992 2943 * Remove a customize panel. 2993 2944 * 2994 2945 * @since 4.0.0 2995 * @access public2996 2946 * 2997 2947 * @param string $id Panel ID to remove. 2998 2948 */ … … 3016 2966 * Registered types are eligible to be rendered via JS and created dynamically. 3017 2967 * 3018 2968 * @since 4.3.0 3019 * @access public3020 2969 * 3021 2970 * @see WP_Customize_Panel 3022 2971 * … … 3030 2979 * Render JS templates for all registered panel types. 3031 2980 * 3032 2981 * @since 4.3.0 3033 * @access public3034 2982 */ 3035 2983 public function render_panel_templates() { 3036 2984 foreach ( $this->registered_panel_types as $panel_type ) { … … 3044 2992 * 3045 2993 * @since 3.4.0 3046 2994 * @since 4.5.0 Return added WP_Customize_Section instance. 3047 * @access public3048 2995 * 3049 2996 * @param WP_Customize_Section|string $id Customize Section object, or Section ID. 3050 2997 * @param array $args { … … 3103 3050 * Registered types are eligible to be rendered via JS and created dynamically. 3104 3051 * 3105 3052 * @since 4.3.0 3106 * @access public3107 3053 * 3108 3054 * @see WP_Customize_Section 3109 3055 * … … 3117 3063 * Render JS templates for all registered section types. 3118 3064 * 3119 3065 * @since 4.3.0 3120 * @access public3121 3066 */ 3122 3067 public function render_section_templates() { 3123 3068 foreach ( $this->registered_section_types as $section_type ) { … … 3131 3076 * 3132 3077 * @since 3.4.0 3133 3078 * @since 4.5.0 Return added WP_Customize_Control instance. 3134 * @access public3135 3079 * 3136 3080 * @param WP_Customize_Control|string $id Customize Control object, or ID. 3137 3081 * @param array $args { … … 3197 3141 * Registered types are eligible to be rendered via JS and created dynamically. 3198 3142 * 3199 3143 * @since 4.1.0 3200 * @access public3201 3144 * 3202 3145 * @param string $control Name of a custom control which is a subclass of 3203 3146 * WP_Customize_Control. … … 3210 3153 * Render JS templates for all registered control types. 3211 3154 * 3212 3155 * @since 4.1.0 3213 * @access public3214 3156 */ 3215 3157 public function render_control_templates() { 3216 3158 foreach ( $this->registered_control_types as $control_type ) { … … 3350 3292 * Determine whether the user agent is iOS. 3351 3293 * 3352 3294 * @since 4.4.0 3353 * @access public3354 3295 * 3355 3296 * @return bool Whether the user agent is iOS. 3356 3297 */ … … 3362 3303 * Get the template string for the Customizer pane document title. 3363 3304 * 3364 3305 * @since 4.4.0 3365 * @access public3366 3306 * 3367 3307 * @return string The template string for the document title. 3368 3308 */ … … 3384 3324 * URL is validated. 3385 3325 * 3386 3326 * @since 4.4.0 3387 * @access public3388 3327 * 3389 3328 * @param string $preview_url URL to be previewed. 3390 3329 */ … … 3397 3336 * Get the initial URL to be previewed. 3398 3337 * 3399 3338 * @since 4.4.0 3400 * @access public3401 3339 * 3402 3340 * @return string URL being previewed. 3403 3341 */ … … 3414 3352 * Determines whether the admin and the frontend are on different domains. 3415 3353 * 3416 3354 * @since 4.7.0 3417 * @access public3418 3355 * 3419 3356 * @return bool Whether cross-domain. 3420 3357 */ … … 3436 3373 * using the customize_allowed_urls filter. 3437 3374 * 3438 3375 * @since 4.7.0 3439 * @access public3440 3376 * 3441 3377 * @returns array Allowed URLs. 3442 3378 */ … … 3463 3399 * Get messenger channel. 3464 3400 * 3465 3401 * @since 4.7.0 3466 * @access public3467 3402 * 3468 3403 * @return string Messenger channel. 3469 3404 */ … … 3477 3412 * URL is validated. 3478 3413 * 3479 3414 * @since 4.4.0 3480 * @access public3481 3415 * 3482 3416 * @param string $return_url URL for return link. 3483 3417 */ … … 3492 3426 * Get URL to link the user to when closing the Customizer. 3493 3427 * 3494 3428 * @since 4.4.0 3495 * @access public3496 3429 * 3497 3430 * @return string URL for link to close Customizer. 3498 3431 */ … … 3516 3449 * Set the autofocused constructs. 3517 3450 * 3518 3451 * @since 4.4.0 3519 * @access public3520 3452 * 3521 3453 * @param array $autofocus { 3522 3454 * Mapping of 'panel', 'section', 'control' to the ID which should be autofocused. … … 3534 3466 * Get the autofocused constructs. 3535 3467 * 3536 3468 * @since 4.4.0 3537 * @access public3538 3469 * 3539 3470 * @return array { 3540 3471 * Mapping of 'panel', 'section', 'control' to the ID which should be autofocused. … … 4265 4196 * Add settings from the POST data that were not added with code, e.g. dynamically-created settings for Widgets 4266 4197 * 4267 4198 * @since 4.2.0 4268 * @access public4269 4199 * 4270 4200 * @see add_dynamic_settings() 4271 4201 */ -
src/wp-includes/class-wp-customize-nav-menus.php
22 22 * WP_Customize_Manager instance. 23 23 * 24 24 * @since 4.3.0 25 * @access public26 25 * @var WP_Customize_Manager 27 26 */ 28 27 public $manager; … … 31 30 * Previewed Menus. 32 31 * 33 32 * @since 4.3.0 34 * @access public35 33 * @var array 36 34 */ 37 35 public $previewed_menus; … … 40 38 * Constructor. 41 39 * 42 40 * @since 4.3.0 43 * @access public44 41 * 45 42 * @param object $manager An instance of the WP_Customize_Manager class. 46 43 */ … … 77 74 * Adds a nonce for customizing menus. 78 75 * 79 76 * @since 4.5.0 80 * @access public81 77 * 82 78 * @param array $nonces Array of nonces. 83 79 * @return array $nonces Modified array of nonces. … … 91 87 * Ajax handler for loading available menu items. 92 88 * 93 89 * @since 4.3.0 94 * @access public95 90 */ 96 91 public function ajax_load_available_items() { 97 92 check_ajax_referer( 'customize-menus', 'customize-menus-nonce' ); … … 135 130 * Performs the post_type and taxonomy queries for loading available menu items. 136 131 * 137 132 * @since 4.3.0 138 * @access public139 133 * 140 134 * @param string $type Optional. Accepts any custom object type and has built-in support for 141 135 * 'post_type' and 'taxonomy'. Default is 'post_type'. … … 258 252 * Ajax handler for searching available menu items. 259 253 * 260 254 * @since 4.3.0 261 * @access public262 255 */ 263 256 public function ajax_search_available_items() { 264 257 check_ajax_referer( 'customize-menus', 'customize-menus-nonce' ); … … 292 285 * Based on WP_Editor::wp_link_query(). 293 286 * 294 287 * @since 4.3.0 295 * @access public296 288 * 297 289 * @param array $args Optional. Accepts 'pagenum' and 's' (search) arguments. 298 290 * @return array Menu items. … … 395 387 * Enqueue scripts and styles for Customizer pane. 396 388 * 397 389 * @since 4.3.0 398 * @access public399 390 */ 400 391 public function enqueue_scripts() { 401 392 wp_enqueue_style( 'customize-nav-menus' ); … … 480 471 * the WP_Customize_Setting constructor. 481 472 * 482 473 * @since 4.3.0 483 * @access public484 474 * 485 475 * @param false|array $setting_args The arguments to the WP_Customize_Setting constructor. 486 476 * @param string $setting_id ID for dynamic setting, usually coming from `$_POST['customized']`. … … 505 495 * Allow non-statically created settings to be constructed with custom WP_Customize_Setting subclass. 506 496 * 507 497 * @since 4.3.0 508 * @access public509 498 * 510 499 * @param string $setting_class WP_Customize_Setting or a subclass. 511 500 * @param string $setting_id ID for dynamic setting, usually coming from `$_POST['customized']`. … … 527 516 * Add the customizer settings and controls. 528 517 * 529 518 * @since 4.3.0 530 * @access public531 519 */ 532 520 public function customize_register() { 533 521 … … 708 696 * intval because the second argument is not what intval() expects. 709 697 * 710 698 * @since 4.3.0 711 * @access public712 699 * 713 700 * @param mixed $value Number to convert. 714 701 * @return int Integer. … … 722 709 * 723 710 * @since 4.3.0 724 711 * @since 4.7.0 Each array item now includes a `$type_label` in in addition to `$title`, `$type`, and `$object`. 725 * @access public726 712 * 727 713 * @return array The available menu item types. 728 714 */ … … 772 758 /** 773 759 * Add a new `auto-draft` post. 774 760 * 775 * @access public776 761 * @since 4.7.0 777 762 * 778 763 * @param array $postarr { … … 822 807 /** 823 808 * Ajax handler for adding a new auto-draft post. 824 809 * 825 * @access public826 810 * @since 4.7.0 827 811 */ 828 812 public function ajax_insert_auto_draft_post() { … … 899 883 * Templates are imported into the JS use wp.template. 900 884 * 901 885 * @since 4.3.0 902 * @access public903 886 */ 904 887 public function print_templates() { 905 888 ?> … … 942 925 * Print the html template used to render the add-menu-item frame. 943 926 * 944 927 * @since 4.3.0 945 * @access public946 928 */ 947 929 public function available_items_template() { 948 930 ?> … … 1003 985 * To be used in the template #available-menu-items. 1004 986 * 1005 987 * @since 4.7.0 1006 * @access private1007 988 * 1008 989 * @param array $available_item_type Menu item data to output, including title, type, and label. 1009 990 * @return void … … 1043 1024 * Print the markup for available menu item custom links. 1044 1025 * 1045 1026 * @since 4.7.0 1046 * @access private1047 1027 * 1048 1028 * @return void 1049 1029 */ … … 1086 1066 * Nav menu args used for each instance, keyed by the args HMAC. 1087 1067 * 1088 1068 * @since 4.3.0 1089 * @access public1090 1069 * @var array 1091 1070 */ 1092 1071 public $preview_nav_menu_instance_args = array(); … … 1095 1074 * Filters arguments for dynamic nav_menu selective refresh partials. 1096 1075 * 1097 1076 * @since 4.5.0 1098 * @access public1099 1077 * 1100 1078 * @param array|false $partial_args Partial args. 1101 1079 * @param string $partial_id Partial ID. … … 1126 1104 * Add hooks for the Customizer preview. 1127 1105 * 1128 1106 * @since 4.3.0 1129 * @access public1130 1107 */ 1131 1108 public function customize_preview_init() { 1132 1109 add_action( 'wp_enqueue_scripts', array( $this, 'customize_preview_enqueue_deps' ) ); … … 1140 1117 * Make the auto-draft status protected so that it can be queried. 1141 1118 * 1142 1119 * @since 4.7.0 1143 * @access public1144 1120 * 1145 1121 * @global array $wp_post_statuses List of post statuses. 1146 1122 */ … … 1153 1129 * Sanitize post IDs for auto-draft posts created for nav menu items to be published. 1154 1130 * 1155 1131 * @since 4.7.0 1156 * @access public1157 1132 * 1158 1133 * @param array $value Post IDs. 1159 1134 * @returns array Post IDs. … … 1189 1164 * post is not an auto-draft. 1190 1165 * 1191 1166 * @since 4.7.0 1192 * @access public1193 1167 * 1194 1168 * @param WP_Customize_Setting $setting Customizer setting object. 1195 1169 */ … … 1219 1193 * Keep track of the arguments that are being passed to wp_nav_menu(). 1220 1194 * 1221 1195 * @since 4.3.0 1222 * @access public1223 1196 * @see wp_nav_menu() 1224 1197 * @see WP_Customize_Widgets_Partial_Refresh::filter_dynamic_sidebar_params() 1225 1198 * … … 1287 1260 * Injects attributes into container element. 1288 1261 * 1289 1262 * @since 4.3.0 1290 * @access public1291 1263 * 1292 1264 * @see wp_nav_menu() 1293 1265 * … … 1312 1284 * Note that the array is expected to be pre-sorted. 1313 1285 * 1314 1286 * @since 4.3.0 1315 * @access public1316 1287 * 1317 1288 * @param array $args The arguments to hash. 1318 1289 * @return string Hashed nav menu arguments. … … 1325 1296 * Enqueue scripts for the Customizer preview. 1326 1297 * 1327 1298 * @since 4.3.0 1328 * @access public1329 1299 */ 1330 1300 public function customize_preview_enqueue_deps() { 1331 1301 wp_enqueue_script( 'customize-preview-nav-menus' ); // Note that we have overridden this. … … 1335 1305 * Exports data from PHP to JS. 1336 1306 * 1337 1307 * @since 4.3.0 1338 * @access public1339 1308 */ 1340 1309 public function export_preview_data() { 1341 1310 … … 1350 1319 * Export any wp_nav_menu() calls during the rendering of any partials. 1351 1320 * 1352 1321 * @since 4.5.0 1353 * @access public1354 1322 * 1355 1323 * @param array $response Response. 1356 1324 * @return array Response. … … 1364 1332 * Render a specific menu via wp_nav_menu() using the supplied arguments. 1365 1333 * 1366 1334 * @since 4.3.0 1367 * @access public1368 1335 * 1369 1336 * @see wp_nav_menu() 1370 1337 * -
src/wp-includes/class-wp-customize-panel.php
26 26 * @since 4.1.0 27 27 * 28 28 * @static 29 * @access protected30 29 * @var int 31 30 */ 32 31 protected static $instance_count = 0; … … 35 34 * Order in which this instance was created in relation to other instances. 36 35 * 37 36 * @since 4.1.0 38 * @access public39 37 * @var int 40 38 */ 41 39 public $instance_number; … … 44 42 * WP_Customize_Manager instance. 45 43 * 46 44 * @since 4.0.0 47 * @access public48 45 * @var WP_Customize_Manager 49 46 */ 50 47 public $manager; … … 53 50 * Unique identifier. 54 51 * 55 52 * @since 4.0.0 56 * @access public57 53 * @var string 58 54 */ 59 55 public $id; … … 62 58 * Priority of the panel, defining the display order of panels and sections. 63 59 * 64 60 * @since 4.0.0 65 * @access public66 61 * @var integer 67 62 */ 68 63 public $priority = 160; … … 71 66 * Capability required for the panel. 72 67 * 73 68 * @since 4.0.0 74 * @access public75 69 * @var string 76 70 */ 77 71 public $capability = 'edit_theme_options'; … … 80 74 * Theme feature support for the panel. 81 75 * 82 76 * @since 4.0.0 83 * @access public84 77 * @var string|array 85 78 */ 86 79 public $theme_supports = ''; … … 89 82 * Title of the panel to show in UI. 90 83 * 91 84 * @since 4.0.0 92 * @access public93 85 * @var string 94 86 */ 95 87 public $title = ''; … … 98 90 * Description to show in the UI. 99 91 * 100 92 * @since 4.0.0 101 * @access public102 93 * @var string 103 94 */ 104 95 public $description = ''; … … 107 98 * Auto-expand a section in a panel when the panel is expanded when the panel only has the one section. 108 99 * 109 100 * @since 4.7.4 110 * @access public111 101 * @var bool 112 102 */ 113 103 public $auto_expand_sole_section = false; … … 116 106 * Customizer sections for this panel. 117 107 * 118 108 * @since 4.0.0 119 * @access public120 109 * @var array 121 110 */ 122 111 public $sections; … … 125 114 * Type of this panel. 126 115 * 127 116 * @since 4.1.0 128 * @access public129 117 * @var string 130 118 */ 131 119 public $type = 'default'; … … 134 122 * Active callback. 135 123 * 136 124 * @since 4.1.0 137 * @access public138 125 * 139 126 * @see WP_Customize_Section::active() 140 127 * … … 179 166 * Check whether panel is active to current Customizer preview. 180 167 * 181 168 * @since 4.1.0 182 * @access public183 169 * 184 170 * @return bool Whether the panel is active to the current preview. 185 171 */ … … 207 193 * provide an 'active_callback' argument to the constructor. 208 194 * 209 195 * @since 4.1.0 210 * @access public211 196 * 212 197 * @return bool Always true. 213 198 */ … … 303 288 * Panel containers are now rendered in JS by default, see WP_Customize_Panel::print_template(). 304 289 * 305 290 * @since 4.0.0 306 * @access protected307 291 */ 308 292 protected function render() {} 309 293 … … 313 297 * Panel contents are now rendered in JS by default, see WP_Customize_Panel::print_template(). 314 298 * 315 299 * @since 4.1.0 316 * @access protected317 300 */ 318 301 protected function render_content() {} 319 302 … … 347 330 * @see WP_Customize_Panel::print_template() 348 331 * 349 332 * @since 4.3.0 350 * @access protected351 333 */ 352 334 protected function render_template() { 353 335 ?> … … 370 352 * @see WP_Customize_Panel::print_template() 371 353 * 372 354 * @since 4.3.0 373 * @access protected374 355 */ 375 356 protected function content_template() { 376 357 ?> -
src/wp-includes/class-wp-customize-section.php
26 26 * @since 4.1.0 27 27 * 28 28 * @static 29 * @access protected30 29 * @var int 31 30 */ 32 31 protected static $instance_count = 0; … … 35 34 * Order in which this instance was created in relation to other instances. 36 35 * 37 36 * @since 4.1.0 38 * @access public39 37 * @var int 40 38 */ 41 39 public $instance_number; … … 44 42 * WP_Customize_Manager instance. 45 43 * 46 44 * @since 3.4.0 47 * @access public48 45 * @var WP_Customize_Manager 49 46 */ 50 47 public $manager; … … 53 50 * Unique identifier. 54 51 * 55 52 * @since 3.4.0 56 * @access public57 53 * @var string 58 54 */ 59 55 public $id; … … 62 58 * Priority of the section which informs load order of sections. 63 59 * 64 60 * @since 3.4.0 65 * @access public66 61 * @var integer 67 62 */ 68 63 public $priority = 160; … … 71 66 * Panel in which to show the section, making it a sub-section. 72 67 * 73 68 * @since 4.0.0 74 * @access public75 69 * @var string 76 70 */ 77 71 public $panel = ''; … … 80 74 * Capability required for the section. 81 75 * 82 76 * @since 3.4.0 83 * @access public84 77 * @var string 85 78 */ 86 79 public $capability = 'edit_theme_options'; … … 89 82 * Theme feature support for the section. 90 83 * 91 84 * @since 3.4.0 92 * @access public93 85 * @var string|array 94 86 */ 95 87 public $theme_supports = ''; … … 98 90 * Title of the section to show in UI. 99 91 * 100 92 * @since 3.4.0 101 * @access public102 93 * @var string 103 94 */ 104 95 public $title = ''; … … 107 98 * Description to show in the UI. 108 99 * 109 100 * @since 3.4.0 110 * @access public111 101 * @var string 112 102 */ 113 103 public $description = ''; … … 116 106 * Customizer controls for this section. 117 107 * 118 108 * @since 3.4.0 119 * @access public120 109 * @var array 121 110 */ 122 111 public $controls; … … 125 114 * Type of this section. 126 115 * 127 116 * @since 4.1.0 128 * @access public129 117 * @var string 130 118 */ 131 119 public $type = 'default'; … … 134 122 * Active callback. 135 123 * 136 124 * @since 4.1.0 137 * @access public138 125 * 139 126 * @see WP_Customize_Section::active() 140 127 * … … 149 136 * Show the description or hide it behind the help icon. 150 137 * 151 138 * @since 4.7.0 152 * @access public153 139 * 154 140 * @var bool Indicates whether the Section's description should be 155 141 * hidden behind a help icon ("?") in the Section header, … … 191 177 * Check whether section is active to current Customizer preview. 192 178 * 193 179 * @since 4.1.0 194 * @access public195 180 * 196 181 * @return bool Whether the section is active to the current preview. 197 182 */ … … 219 204 * an 'active_callback' argument to the constructor. 220 205 * 221 206 * @since 4.1.0 222 * @access public223 207 * 224 208 * @return true Always true. 225 209 */ … … 331 315 * WP_Customize_Manager::register_section_type(). 332 316 * 333 317 * @since 4.3.0 334 * @access public335 318 * 336 319 * @see WP_Customize_Manager::render_template() 337 320 */ … … 350 333 * export custom variables by overriding WP_Customize_Section::json(). 351 334 * 352 335 * @since 4.3.0 353 * @access protected354 336 * 355 337 * @see WP_Customize_Section::print_template() 356 338 */ -
src/wp-includes/class-wp-customize-setting.php
21 21 * Customizer bootstrap instance. 22 22 * 23 23 * @since 3.4.0 24 * @access public25 24 * @var WP_Customize_Manager 26 25 */ 27 26 public $manager; … … 30 29 * Unique string identifier for the setting. 31 30 * 32 31 * @since 3.4.0 33 * @access public34 32 * @var string 35 33 */ 36 34 public $id; … … 39 37 * Type of customize settings. 40 38 * 41 39 * @since 3.4.0 42 * @access public43 40 * @var string 44 41 */ 45 42 public $type = 'theme_mod'; … … 48 45 * Capability required to edit this setting. 49 46 * 50 47 * @since 3.4.0 51 * @access public52 48 * @var string|array 53 49 */ 54 50 public $capability = 'edit_theme_options'; … … 57 53 * Feature a theme is required to support to enable this setting. 58 54 * 59 55 * @since 3.4.0 60 * @access public61 56 * @var string 62 57 */ 63 58 public $theme_supports = ''; … … 66 61 * The default value for the setting. 67 62 * 68 63 * @since 3.4.0 69 * @access public70 64 * @var string 71 65 */ 72 66 public $default = ''; … … 80 74 * @link https://developer.wordpress.org/themes/customize-api 81 75 * 82 76 * @since 3.4.0 83 * @access public84 77 * @var string 85 78 */ 86 79 public $transport = 'refresh'; … … 89 82 * Server-side validation callback for the setting's value. 90 83 * 91 84 * @since 4.6.0 92 * @access public93 85 * @var callable 94 86 */ 95 87 public $validate_callback = ''; … … 98 90 * Callback to filter a Customize setting value in un-slashed form. 99 91 * 100 92 * @since 3.4.0 101 * @access public102 93 * @var callable 103 94 */ 104 95 public $sanitize_callback = ''; … … 107 98 * Callback to convert a Customize PHP setting value to a value that is JSON serializable. 108 99 * 109 100 * @since 3.4.0 110 * @access public111 101 * @var string 112 102 */ 113 103 public $sanitize_js_callback = ''; … … 121 111 * from the start. 122 112 * 123 113 * @since 4.2.0 124 * @access public125 114 * @var bool 126 115 */ 127 116 public $dirty = false; … … 130 119 * ID Data. 131 120 * 132 121 * @since 3.4.0 133 * @access protected134 122 * @var array 135 123 */ 136 124 protected $id_data = array(); … … 139 127 * Whether or not preview() was called. 140 128 * 141 129 * @since 4.4.0 142 * @access protected143 130 * @var bool 144 131 */ 145 132 protected $is_previewed = false; … … 149 136 * 150 137 * @since 4.4.0 151 138 * @static 152 * @access protected153 139 * @var array 154 140 */ 155 141 protected static $aggregated_multidimensionals = array(); … … 158 144 * Whether the multidimensional setting is aggregated. 159 145 * 160 146 * @since 4.4.0 161 * @access protected162 147 * @var bool 163 148 */ 164 149 protected $is_multidimensional_aggregated = false; … … 277 262 * The ID for the current site when the preview() method was called. 278 263 * 279 264 * @since 4.2.0 280 * @access protected281 265 * @var int 282 266 */ 283 267 protected $_previewed_blog_id; … … 301 285 * 302 286 * @see WP_Customize_Setting::preview() 303 287 * @since 4.1.1 304 * @access protected305 288 * @var mixed 306 289 */ 307 290 protected $_original_value; -
src/wp-includes/class-wp-customize-widgets.php
22 22 * WP_Customize_Manager instance. 23 23 * 24 24 * @since 3.9.0 25 * @access public26 25 * @var WP_Customize_Manager 27 26 */ 28 27 public $manager; … … 31 30 * All id_bases for widgets defined in core. 32 31 * 33 32 * @since 3.9.0 34 * @access protected35 33 * @var array 36 34 */ 37 35 protected $core_widget_id_bases = array( … … 56 54 57 55 /** 58 56 * @since 3.9.0 59 * @access protected60 57 * @var array 61 58 */ 62 59 protected $rendered_sidebars = array(); … … 63 60 64 61 /** 65 62 * @since 3.9.0 66 * @access protected67 63 * @var array 68 64 */ 69 65 protected $rendered_widgets = array(); … … 70 66 71 67 /** 72 68 * @since 3.9.0 73 * @access protected74 69 * @var array 75 70 */ 76 71 protected $old_sidebars_widgets = array(); … … 79 74 * Mapping of widget ID base to whether it supports selective refresh. 80 75 * 81 76 * @since 4.5.0 82 * @access protected83 77 * @var array 84 78 */ 85 79 protected $selective_refreshable_widgets; … … 88 82 * Mapping of setting type to setting ID pattern. 89 83 * 90 84 * @since 4.2.0 91 * @access protected92 85 * @var array 93 86 */ 94 87 protected $setting_id_patterns = array( … … 100 93 * Initial loader. 101 94 * 102 95 * @since 3.9.0 103 * @access public104 96 * 105 97 * @param WP_Customize_Manager $manager Customize manager bootstrap instance. 106 98 */ … … 143 135 * then this will always return an empty array. 144 136 * 145 137 * @since 4.5.0 146 * @access public147 138 * 148 139 * @global WP_Widget_Factory $wp_widget_factory 149 140 * … … 168 159 * Determines if a widget supports selective refresh. 169 160 * 170 161 * @since 4.5.0 171 * @access public172 162 * 173 163 * @param string $id_base Widget ID Base. 174 164 * @return bool Whether the widget can be selective refreshed. … … 182 172 * Retrieves the widget setting type given a setting ID. 183 173 * 184 174 * @since 4.2.0 185 * @access protected186 175 * 187 176 * @staticvar array $cache 188 177 * … … 207 196 * them up-front so widgets will be initialized properly. 208 197 * 209 198 * @since 4.2.0 210 * @access public211 199 */ 212 200 public function register_settings() { 213 201 $widget_setting_ids = array(); … … 239 227 * Determines the arguments for a dynamically-created setting. 240 228 * 241 229 * @since 4.2.0 242 * @access public243 230 * 244 231 * @param false|array $args The arguments to the WP_Customize_Setting constructor. 245 232 * @param string $setting_id ID for dynamic setting, usually coming from `$_POST['customized']`. … … 256 243 * Retrieves an unslashed post value or return a default. 257 244 * 258 245 * @since 3.9.0 259 * @access protected260 246 * 261 247 * @param string $name Post value. 262 248 * @param mixed $default Default post value. … … 280 266 * theme gets switched. 281 267 * 282 268 * @since 3.9.0 283 * @access public284 269 * 285 270 * @global array $sidebars_widgets 286 271 * @global array $_wp_sidebars_widgets … … 313 298 * theme_mod. 314 299 * 315 300 * @since 3.9.0 316 * @access public317 301 * 318 302 * @see WP_Customize_Widgets::handle_theme_switch() 319 303 * … … 332 316 * option. 333 317 * 334 318 * @since 3.9.0 335 * @access public336 319 * 337 320 * @see WP_Customize_Widgets::handle_theme_switch() 338 321 * @global array $sidebars_widgets … … 352 335 * Note: these actions are also fired in wp_ajax_update_widget(). 353 336 * 354 337 * @since 3.9.0 355 * @access public356 338 */ 357 339 public function customize_controls_init() { 358 340 /** This action is documented in wp-admin/includes/ajax-actions.php */ … … 372 354 * so that all filters have been initialized (e.g. Widget Visibility). 373 355 * 374 356 * @since 3.9.0 375 * @access public376 357 */ 377 358 public function schedule_customize_register() { 378 359 if ( is_admin() ) { … … 386 367 * Registers Customizer settings and controls for all sidebars and widgets. 387 368 * 388 369 * @since 3.9.0 389 * @access public390 370 * 391 371 * @global array $wp_registered_widgets 392 372 * @global array $wp_registered_widget_controls … … 537 517 * Determines whether the widgets panel is active, based on whether there are sidebars registered. 538 518 * 539 519 * @since 4.4.0 540 * @access public541 520 * 542 521 * @see WP_Customize_Panel::$active_callback 543 522 * … … 553 532 * Converts a widget_id into its corresponding Customizer setting ID (option name). 554 533 * 555 534 * @since 3.9.0 556 * @access public557 535 * 558 536 * @param string $widget_id Widget ID. 559 537 * @return string Maybe-parsed widget ID. … … 579 557 * overridden with the {@see 'is_wide_widget_in_customizer'} filter. 580 558 * 581 559 * @since 3.9.0 582 * @access public583 560 * 584 561 * @global $wp_registered_widget_controls 585 562 * … … 609 586 * Converts a widget ID into its id_base and number components. 610 587 * 611 588 * @since 3.9.0 612 * @access public613 589 * 614 590 * @param string $widget_id Widget ID. 615 591 * @return array Array containing a widget's id_base and number components. … … 634 610 * Converts a widget setting ID (option path) to its id_base and number components. 635 611 * 636 612 * @since 3.9.0 637 * @access public638 613 * 639 614 * @param string $setting_id Widget setting ID. 640 615 * @return WP_Error|array Array containing a widget's id_base and number components, … … 656 631 * allow custom styles from plugins. 657 632 * 658 633 * @since 3.9.0 659 * @access public660 634 */ 661 635 public function print_styles() { 662 636 /** This action is documented in wp-admin/admin-header.php */ … … 671 645 * allow custom scripts from plugins. 672 646 * 673 647 * @since 3.9.0 674 * @access public675 648 */ 676 649 public function print_scripts() { 677 650 /** This action is documented in wp-admin/admin-header.php */ … … 685 658 * Enqueues scripts and styles for Customizer panel and export data to JavaScript. 686 659 * 687 660 * @since 3.9.0 688 * @access public689 661 * 690 662 * @global WP_Scripts $wp_scripts 691 663 * @global array $wp_registered_sidebars … … 822 794 * Renders the widget form control templates into the DOM. 823 795 * 824 796 * @since 3.9.0 825 * @access public826 797 */ 827 798 public function output_widget_control_templates() { 828 799 ?> … … 865 836 * allow custom scripts from plugins. 866 837 * 867 838 * @since 3.9.0 868 * @access public869 839 */ 870 840 public function print_footer_scripts() { 871 841 /** This action is documented in wp-admin/admin-footer.php */ … … 882 852 * Retrieves common arguments to supply when constructing a Customizer setting. 883 853 * 884 854 * @since 3.9.0 885 * @access public886 855 * 887 856 * @param string $id Widget setting ID. 888 857 * @param array $overrides Array of setting overrides. … … 926 895 * Used as the 'sanitize_callback' for each $sidebars_widgets setting. 927 896 * 928 897 * @since 3.9.0 929 * @access public930 898 * 931 899 * @param array $widget_ids Array of widget IDs. 932 900 * @return array Array of sanitized widget IDs. … … 944 912 * Builds up an index of all available widgets for use in Backbone models. 945 913 * 946 914 * @since 3.9.0 947 * @access public948 915 * 949 916 * @global array $wp_registered_widgets 950 917 * @global array $wp_registered_widget_controls … … 1031 998 * Naturally orders available widgets by name. 1032 999 * 1033 1000 * @since 3.9.0 1034 * @access protected1035 1001 * 1036 1002 * @param array $widget_a The first widget to compare. 1037 1003 * @param array $widget_b The second widget to compare. … … 1045 1011 * Retrieves the widget control markup. 1046 1012 * 1047 1013 * @since 3.9.0 1048 * @access public1049 1014 * 1050 1015 * @param array $args Widget control arguments. 1051 1016 * @return string Widget control form HTML markup. … … 1065 1030 * Retrieves the widget control markup parts. 1066 1031 * 1067 1032 * @since 4.4.0 1068 * @access public1069 1033 * 1070 1034 * @param array $args Widget control arguments. 1071 1035 * @return array { … … 1096 1060 * Adds hooks for the Customizer preview. 1097 1061 * 1098 1062 * @since 3.9.0 1099 * @access public1100 1063 */ 1101 1064 public function customize_preview_init() { 1102 1065 add_action( 'wp_enqueue_scripts', array( $this, 'customize_preview_enqueue' ) ); … … 1108 1071 * Refreshes the nonce for widget updates. 1109 1072 * 1110 1073 * @since 4.2.0 1111 * @access public1112 1074 * 1113 1075 * @param array $nonces Array of nonces. 1114 1076 * @return array $nonces Array of nonces. … … 1127 1089 * filter is added, it has to be reset after the filter has been added. 1128 1090 * 1129 1091 * @since 3.9.0 1130 * @access public1131 1092 * 1132 1093 * @param array $sidebars_widgets List of widgets for the current sidebar. 1133 1094 * @return array … … 1143 1104 * Enqueues scripts for the Customizer preview. 1144 1105 * 1145 1106 * @since 3.9.0 1146 * @access public1147 1107 */ 1148 1108 public function customize_preview_enqueue() { 1149 1109 wp_enqueue_script( 'customize-preview-widgets' ); … … 1154 1114 * stylesheet can override. 1155 1115 * 1156 1116 * @since 3.9.0 1157 * @access public1158 1117 */ 1159 1118 public function print_preview_css() { 1160 1119 ?> … … 1215 1174 * Tracks the widgets that were rendered. 1216 1175 * 1217 1176 * @since 3.9.0 1218 * @access public1219 1177 * 1220 1178 * @param array $widget Rendered widget to tally. 1221 1179 */ … … 1227 1185 * Determine if a widget is rendered on the page. 1228 1186 * 1229 1187 * @since 4.0.0 1230 * @access public1231 1188 * 1232 1189 * @param string $widget_id Widget ID to check. 1233 1190 * @return bool Whether the widget is rendered. … … 1240 1197 * Determines if a sidebar is rendered on the page. 1241 1198 * 1242 1199 * @since 4.0.0 1243 * @access public1244 1200 * 1245 1201 * @param string $sidebar_id Sidebar ID to check. 1246 1202 * @return bool Whether the sidebar is rendered. … … 1257 1213 * if there were widgets populating it. 1258 1214 * 1259 1215 * @since 3.9.0 1260 * @access public1261 1216 * 1262 1217 * @param bool $is_active Whether the sidebar is active. 1263 1218 * @param string $sidebar_id Sidebar ID. … … 1283 1238 * there were widgets populating it. 1284 1239 * 1285 1240 * @since 3.9.0 1286 * @access public1287 1241 * 1288 1242 * @param bool $has_widgets Whether the current sidebar has widgets. 1289 1243 * @param string $sidebar_id Sidebar ID. … … 1309 1263 * data has occurred. 1310 1264 * 1311 1265 * @since 3.9.0 1312 * @access protected1313 1266 * 1314 1267 * @param string $serialized_instance Widget instance. 1315 1268 * @return string MAC for serialized widget instance. … … 1325 1278 * only get applied to an instance *once*. 1326 1279 * 1327 1280 * @since 3.9.0 1328 * @access public1329 1281 * 1330 1282 * @param array $value Widget instance to sanitize. 1331 1283 * @return array|void Sanitized widget instance. … … 1363 1315 * Converts a widget instance into JSON-representable format. 1364 1316 * 1365 1317 * @since 3.9.0 1366 * @access public1367 1318 * 1368 1319 * @param array $value Widget instance to convert to JSON. 1369 1320 * @return array JSON-converted widget instance. … … 1389 1340 * in a sidebar upon deactivation. 1390 1341 * 1391 1342 * @since 3.9.0 1392 * @access public1393 1343 * 1394 1344 * @global array $wp_registered_widgets 1395 1345 * … … 1408 1358 * Requires that `$_POST` be populated with the instance data. 1409 1359 * 1410 1360 * @since 3.9.0 1411 * @access public1412 1361 * 1413 1362 * @global array $wp_registered_widget_updates 1414 1363 * @global array $wp_registered_widget_controls … … 1538 1487 * Most code here copied from wp_ajax_save_widget(). 1539 1488 * 1540 1489 * @since 3.9.0 1541 * @access public1542 1490 * 1543 1491 * @see wp_ajax_save_widget() 1544 1492 */ … … 1601 1549 * Filters arguments for dynamic widget partials. 1602 1550 * 1603 1551 * @since 4.5.0 1604 * @access public1605 1552 * 1606 1553 * @param array|false $partial_args Partial arguments. 1607 1554 * @param string $partial_id Partial ID. … … 1635 1582 * Adds hooks for selective refresh. 1636 1583 * 1637 1584 * @since 4.5.0 1638 * @access public1639 1585 */ 1640 1586 public function selective_refresh_init() { 1641 1587 if ( ! current_theme_supports( 'customize-selective-refresh-widgets' ) ) { … … 1711 1657 * data-* attributes can be whitelisted. 1712 1658 * 1713 1659 * @since 4.5.0 1714 * @access protected1715 1660 * @var array 1716 1661 */ 1717 1662 protected $before_widget_tags_seen = array(); … … 1722 1667 * This is needed in case the `$before_widget` is run through wp_kses() when printed. 1723 1668 * 1724 1669 * @since 4.5.0 1725 * @access public1726 1670 * 1727 1671 * @param array $allowed_html Allowed HTML. 1728 1672 * @return array (Maybe) modified allowed HTML. … … 1752 1696 * This helps facilitate the uncommon scenario where a single sidebar is rendered multiple times on a template. 1753 1697 * 1754 1698 * @since 4.5.0 1755 * @access protected1756 1699 * @var array 1757 1700 */ 1758 1701 protected $sidebar_instance_count = array(); … … 1761 1704 * The current request's sidebar_instance_number context. 1762 1705 * 1763 1706 * @since 4.5.0 1764 * @access protected1765 1707 * @var int 1766 1708 */ 1767 1709 protected $context_sidebar_instance_number; … … 1770 1712 * Current sidebar ID being rendered. 1771 1713 * 1772 1714 * @since 4.5.0 1773 * @access protected1774 1715 * @var array 1775 1716 */ 1776 1717 protected $current_dynamic_sidebar_id_stack = array(); … … 1781 1722 * Insert marker before widgets are rendered in a dynamic sidebar. 1782 1723 * 1783 1724 * @since 4.5.0 1784 * @access public1785 1725 * 1786 1726 * @param int|string $index Index, name, or ID of the dynamic sidebar. 1787 1727 */ … … 1802 1742 * Inserts a marker after widgets are rendered in a dynamic sidebar. 1803 1743 * 1804 1744 * @since 4.5.0 1805 * @access public1806 1745 * 1807 1746 * @param int|string $index Index, name, or ID of the dynamic sidebar. 1808 1747 */ … … 1817 1756 * Current sidebar being rendered. 1818 1757 * 1819 1758 * @since 4.5.0 1820 * @access protected1821 1759 * @var string 1822 1760 */ 1823 1761 protected $rendering_widget_id; … … 1826 1764 * Current widget being rendered. 1827 1765 * 1828 1766 * @since 4.5.0 1829 * @access protected1830 1767 * @var string 1831 1768 */ 1832 1769 protected $rendering_sidebar_id; … … 1835 1772 * Filters sidebars_widgets to ensure the currently-rendered widget is the only widget in the current sidebar. 1836 1773 * 1837 1774 * @since 4.5.0 1838 * @access protected1839 1775 * 1840 1776 * @param array $sidebars_widgets Sidebars widgets. 1841 1777 * @return array Filtered sidebars widgets. … … 1849 1785 * Renders a specific widget using the supplied sidebar arguments. 1850 1786 * 1851 1787 * @since 4.5.0 1852 * @access public1853 1788 * 1854 1789 * @see dynamic_sidebar() 1855 1790 * … … 1908 1843 * List of captured widget option updates. 1909 1844 * 1910 1845 * @since 3.9.0 1911 * @access protected1912 1846 * @var array $_captured_options Values updated while option capture is happening. 1913 1847 */ 1914 1848 protected $_captured_options = array(); … … 1917 1851 * Whether option capture is currently happening. 1918 1852 * 1919 1853 * @since 3.9.0 1920 * @access protected1921 1854 * @var bool $_is_current Whether option capture is currently happening or not. 1922 1855 */ 1923 1856 protected $_is_capturing_option_updates = false; … … 1926 1859 * Determines whether the captured option update should be ignored. 1927 1860 * 1928 1861 * @since 3.9.0 1929 * @access protected1930 1862 * 1931 1863 * @param string $option_name Option name. 1932 1864 * @return bool Whether the option capture is ignored. … … 1939 1871 * Retrieves captured widget option updates. 1940 1872 * 1941 1873 * @since 3.9.0 1942 * @access protected1943 1874 * 1944 1875 * @return array Array of captured options. 1945 1876 */ … … 1951 1882 * Retrieves the option that was captured from being saved. 1952 1883 * 1953 1884 * @since 4.2.0 1954 * @access protected1955 1885 * 1956 1886 * @param string $option_name Option name. 1957 1887 * @param mixed $default Optional. Default value to return if the option does not exist. Default false. … … 1970 1900 * Retrieves the number of captured widget option updates. 1971 1901 * 1972 1902 * @since 3.9.0 1973 * @access protected1974 1903 * 1975 1904 * @return int Number of updated options. 1976 1905 */ … … 1982 1911 * Begins keeping track of changes to widget options, caching new values. 1983 1912 * 1984 1913 * @since 3.9.0 1985 * @access protected1986 1914 */ 1987 1915 protected function start_capturing_option_updates() { 1988 1916 if ( $this->_is_capturing_option_updates ) { … … 1998 1926 * Pre-filters captured option values before updating. 1999 1927 * 2000 1928 * @since 3.9.0 2001 * @access public2002 1929 * 2003 1930 * @param mixed $new_value The new option value. 2004 1931 * @param string $option_name Name of the option. … … 2023 1950 * Pre-filters captured option values before retrieving. 2024 1951 * 2025 1952 * @since 3.9.0 2026 * @access public2027 1953 * 2028 1954 * @param mixed $value Value to return instead of the option value. 2029 1955 * @return mixed Filtered option value. … … 2045 1971 * Undoes any changes to the options since options capture began. 2046 1972 * 2047 1973 * @since 3.9.0 2048 * @access protected2049 1974 */ 2050 1975 protected function stop_capturing_option_updates() { 2051 1976 if ( ! $this->_is_capturing_option_updates ) { -
src/wp-includes/class-wp-dependency.php
20 20 /** 21 21 * The handle name. 22 22 * 23 * @access public24 23 * @since 2.6.0 25 24 * @var null 26 25 */ … … 29 28 /** 30 29 * The handle source. 31 30 * 32 * @access public33 31 * @since 2.6.0 34 32 * @var null 35 33 */ … … 38 36 /** 39 37 * An array of handle dependencies. 40 38 * 41 * @access public42 39 * @since 2.6.0 43 40 * @var array 44 41 */ … … 49 46 * 50 47 * Used for cache-busting. 51 48 * 52 * @access public53 49 * @since 2.6.0 54 50 * @var bool|string 55 51 */ … … 58 54 /** 59 55 * Additional arguments for the handle. 60 56 * 61 * @access public62 57 * @since 2.6.0 63 58 * @var null 64 59 */ … … 67 62 /** 68 63 * Extra data to supply to the handle. 69 64 * 70 * @access public71 65 * @since 2.6.0 72 66 * @var array 73 67 */ … … 87 81 /** 88 82 * Add handle data. 89 83 * 90 * @access public91 84 * @since 2.6.0 92 85 * 93 86 * @param string $name The data key to add. -
src/wp-includes/class-wp-embed.php
20 20 * 21 21 * Bypasses the {@see 'embed_maybe_make_link'} filter. 22 22 * 23 * @access public24 23 * @var bool 25 24 */ 26 25 public $return_false_on_fail = false; -
src/wp-includes/class-wp-error.php
65 65 * Retrieve all error codes. 66 66 * 67 67 * @since 2.1.0 68 * @access public69 68 * 70 69 * @return array List of error codes, if available. 71 70 */ … … 80 79 * Retrieve first error code available. 81 80 * 82 81 * @since 2.1.0 83 * @access public84 82 * 85 83 * @return string|int Empty string, if no error codes. 86 84 */ … … 157 155 * Add an error or append additional message to an existing error. 158 156 * 159 157 * @since 2.1.0 160 * @access public161 158 * 162 159 * @param string|int $code Error code. 163 160 * @param string $message Error message. -
src/wp-includes/class-wp-feed-cache-transient.php
18 18 * Holds the transient name. 19 19 * 20 20 * @since 2.8.0 21 * @access public22 21 * @var string 23 22 */ 24 23 public $name; … … 27 26 * Holds the transient mod name. 28 27 * 29 28 * @since 2.8.0 30 * @access public31 29 * @var string 32 30 */ 33 31 public $mod_name; … … 38 36 * Defaults to 43200 seconds (12 hours). 39 37 * 40 38 * @since 2.8.0 41 * @access public42 39 * @var int 43 40 */ 44 41 public $lifetime = 43200; … … 48 45 * 49 46 * @since 2.8.0 50 47 * @since 3.2.0 Updated to use a PHP5 constructor. 51 * @access public52 48 * 53 49 * @param string $location URL location (scheme is used to determine handler). 54 50 * @param string $filename Unique identifier for cache object. … … 74 70 * Sets the transient. 75 71 * 76 72 * @since 2.8.0 77 * @access public78 73 * 79 74 * @param SimplePie $data Data to save. 80 75 * @return true Always true. … … 93 88 * Gets the transient. 94 89 * 95 90 * @since 2.8.0 96 * @access public97 91 * 98 92 * @return mixed Transient value. 99 93 */ … … 105 99 * Gets mod transient. 106 100 * 107 101 * @since 2.8.0 108 * @access public109 102 * 110 103 * @return mixed Transient value. 111 104 */ … … 117 110 * Sets mod transient. 118 111 * 119 112 * @since 2.8.0 120 * @access public121 113 * 122 114 * @return bool False if value was not set and true if value was set. 123 115 */ … … 129 121 * Deletes transients. 130 122 * 131 123 * @since 2.8.0 132 * @access public133 124 * 134 125 * @return true Always true. 135 126 */ -
src/wp-includes/class-wp-feed-cache.php
20 20 * Creates a new SimplePie_Cache object. 21 21 * 22 22 * @since 2.8.0 23 * @access public24 23 * 25 24 * @param string $location URL location (scheme is used to determine handler). 26 25 * @param string $filename Unique identifier for cache object. -
src/wp-includes/class-wp-hook.php
21 21 * Hook callbacks. 22 22 * 23 23 * @since 4.7.0 24 * @access public25 24 * @var array 26 25 */ 27 26 public $callbacks = array(); … … 30 29 * The priority keys of actively running iterations of a hook. 31 30 * 32 31 * @since 4.7.0 33 * @access private34 32 * @var array 35 33 */ 36 34 private $iterations = array(); … … 39 37 * The current priority of actively running iterations of a hook. 40 38 * 41 39 * @since 4.7.0 42 * @access private43 40 * @var array 44 41 */ 45 42 private $current_priority = array(); … … 48 45 * Number of levels this hook can be recursively called. 49 46 * 50 47 * @since 4.7.0 51 * @access private52 48 * @var int 53 49 */ 54 50 private $nesting_level = 0; … … 57 53 * Flag for if we're current doing an action, rather than a filter. 58 54 * 59 55 * @since 4.7.0 60 * @access private61 56 * @var bool 62 57 */ 63 58 private $doing_action = false; … … 66 61 * Hooks a function or method to a specific filter action. 67 62 * 68 63 * @since 4.7.0 69 * @access public70 64 * 71 65 * @param string $tag The name of the filter to hook the $function_to_add callback to. 72 66 * @param callable $function_to_add The callback to be run when the filter is applied. … … 99 93 * Handles reseting callback priority keys mid-iteration. 100 94 * 101 95 * @since 4.7.0 102 * @access private103 96 * 104 97 * @param bool|int $new_priority Optional. The priority of the new filter being added. Default false, 105 98 * for no priority being added. … … 168 161 * Unhooks a function or method from a specific filter action. 169 162 * 170 163 * @since 4.7.0 171 * @access public172 164 * 173 165 * @param string $tag The filter hook to which the function to be removed is hooked. Used 174 166 * for building the callback ID when SPL is not available. … … 196 188 * Checks if a specific action has been registered for this hook. 197 189 * 198 190 * @since 4.7.0 199 * @access public200 191 * 201 192 * @param callable|bool $function_to_check Optional. The callback to check for. Default false. 202 193 * @param string $tag Optional. The name of the filter hook. Used for building … … 226 217 * Checks if any callbacks have been registered for this hook. 227 218 * 228 219 * @since 4.7.0 229 * @access public230 220 * 231 221 * @return bool True if callbacks have been registered for the current hook, otherwise false. 232 222 */ … … 243 233 * Removes all callbacks from the current filter. 244 234 * 245 235 * @since 4.7.0 246 * @access public247 236 * 248 237 * @param int|bool $priority Optional. The priority number to remove. Default false. 249 238 */ … … 267 256 * Calls the callback functions added to a filter hook. 268 257 * 269 258 * @since 4.7.0 270 * @access public271 259 * 272 260 * @param mixed $value The value to filter. 273 261 * @param array $args Arguments to pass to callbacks. … … 314 302 * Executes the callback functions hooked on a specific action hook. 315 303 * 316 304 * @since 4.7.0 317 * @access public318 305 * 319 306 * @param mixed $args Arguments to pass to the hook callbacks. 320 307 */ … … 332 319 * Processes the functions hooked into the 'all' hook. 333 320 * 334 321 * @since 4.7.0 335 * @access public336 322 * 337 323 * @param array $args Arguments to pass to the hook callbacks. Passed by reference. 338 324 */ … … 355 341 * Return the current priority level of the currently running iteration of the hook. 356 342 * 357 343 * @since 4.7.0 358 * @access public359 344 * 360 345 * @return int|false If the hook is running, return the current priority level. If it isn't running, return false. 361 346 */ … … 371 356 * Normalizes filters set up before WordPress has initialized to WP_Hook objects. 372 357 * 373 358 * @since 4.7.0 374 * @access public375 359 * @static 376 360 * 377 361 * @param array $filters Filters to normalize. … … 405 389 * Determines whether an offset value exists. 406 390 * 407 391 * @since 4.7.0 408 * @access public409 392 * 410 393 * @link https://secure.php.net/manual/en/arrayaccess.offsetexists.php 411 394 * … … 420 403 * Retrieves a value at a specified offset. 421 404 * 422 405 * @since 4.7.0 423 * @access public424 406 * 425 407 * @link https://secure.php.net/manual/en/arrayaccess.offsetget.php 426 408 * … … 435 417 * Sets a value at a specified offset. 436 418 * 437 419 * @since 4.7.0 438 * @access public439 420 * 440 421 * @link https://secure.php.net/manual/en/arrayaccess.offsetset.php 441 422 * … … 454 435 * Unsets a specified offset. 455 436 * 456 437 * @since 4.7.0 457 * @access public458 438 * 459 439 * @link https://secure.php.net/manual/en/arrayaccess.offsetunset.php 460 440 * … … 468 448 * Returns the current element. 469 449 * 470 450 * @since 4.7.0 471 * @access public472 451 * 473 452 * @link https://secure.php.net/manual/en/iterator.current.php 474 453 * … … 482 461 * Moves forward to the next element. 483 462 * 484 463 * @since 4.7.0 485 * @access public486 464 * 487 465 * @link https://secure.php.net/manual/en/iterator.next.php 488 466 * … … 496 474 * Returns the key of the current element. 497 475 * 498 476 * @since 4.7.0 499 * @access public500 477 * 501 478 * @link https://secure.php.net/manual/en/iterator.key.php 502 479 * … … 510 487 * Checks if current position is valid. 511 488 * 512 489 * @since 4.7.0 513 * @access public514 490 * 515 491 * @link https://secure.php.net/manual/en/iterator.valid.php 516 492 * … … 524 500 * Rewinds the Iterator to the first element. 525 501 * 526 502 * @since 4.7.0 527 * @access public528 503 * 529 504 * @link https://secure.php.net/manual/en/iterator.rewind.php 530 505 */ -
src/wp-includes/class-wp-http-cookie.php
67 67 * or a header string detailing it. 68 68 * 69 69 * @since 2.8.0 70 * @access public71 70 * 72 71 * @param string|array $data { 73 72 * Raw cookie data as header string or data array. … … 140 139 * 141 140 * Decision is based on RFC 2109/2965, so look there for details on validity. 142 141 * 143 * @access public144 142 * @since 2.8.0 145 143 * 146 144 * @param string $url URL you intend to send this cookie to … … 185 183 /** 186 184 * Convert cookie name and value back to header string. 187 185 * 188 * @access public189 186 * @since 2.8.0 190 187 * 191 188 * @return string Header encoded cookie name and value. … … 208 205 /** 209 206 * Retrieve cookie header for usage in the rest of the WordPress HTTP API. 210 207 * 211 * @access public212 208 * @since 2.8.0 213 209 * 214 210 * @return string … … 221 217 * Retrieves cookie attributes. 222 218 * 223 219 * @since 4.6.0 224 * @access public225 220 * 226 221 * @return array { 227 222 * List of attributes. -
src/wp-includes/class-wp-http-curl.php
22 22 * Temporary header storage for during requests. 23 23 * 24 24 * @since 3.2.0 25 * @access private26 25 * @var string 27 26 */ 28 27 private $headers = ''; … … 31 30 * Temporary body storage for during requests. 32 31 * 33 32 * @since 3.6.0 34 * @access private35 33 * @var string 36 34 */ 37 35 private $body = ''; … … 40 38 * The maximum amount of data to receive from the remote server. 41 39 * 42 40 * @since 3.6.0 43 * @access private44 41 * @var int 45 42 */ 46 43 private $max_body_length = false; … … 49 46 * The file resource used for streaming to file. 50 47 * 51 48 * @since 3.6.0 52 * @access private53 49 * @var resource 54 50 */ 55 51 private $stream_handle = false; … … 58 54 * The total bytes written in the current request. 59 55 * 60 56 * @since 4.1.0 61 * @access private62 57 * @var int 63 58 */ 64 59 private $bytes_written_total = 0; … … 66 61 /** 67 62 * Send a HTTP request to a URI using cURL extension. 68 63 * 69 * @access public70 64 * @since 2.7.0 71 65 * 72 66 * @param string $url The request URL. … … 304 298 * for temporary storage 305 299 * 306 300 * @since 3.2.0 307 * @access private308 301 * 309 302 * @param resource $handle cURL handle. 310 303 * @param string $headers cURL request headers. … … 323 316 * `$data` passed in will cause cURL to abort the request with `CURLE_WRITE_ERROR`. 324 317 * 325 318 * @since 3.6.0 326 * @access private327 319 * 328 320 * @param resource $handle cURL handle. 329 321 * @param string $data cURL request body. -
src/wp-includes/class-wp-http-requests-response.php
19 19 * Requests Response object. 20 20 * 21 21 * @since 4.6.0 22 * @access protected23 22 * @var Requests_Response 24 23 */ 25 24 protected $response; … … 28 27 * Filename the response was saved to. 29 28 * 30 29 * @since 4.6.0 31 * @access protected32 30 * @var string|null 33 31 */ 34 32 protected $filename; … … 37 35 * Constructor. 38 36 * 39 37 * @since 4.6.0 40 * @access public41 38 * 42 39 * @param Requests_Response $response HTTP response. 43 40 * @param string $filename Optional. File name. Default empty. … … 51 48 * Retrieves the response object for the request. 52 49 * 53 50 * @since 4.6.0 54 * @access public55 51 * 56 52 * @return Requests_Response HTTP response. 57 53 */ … … 63 59 * Retrieves headers associated with the response. 64 60 * 65 61 * @since 4.6.0 66 * @access public67 62 * 68 63 * @see \Requests_Utility_CaseInsensitiveDictionary 69 64 * … … 88 83 * Sets all header values. 89 84 * 90 85 * @since 4.6.0 91 * @access public92 86 * 93 87 * @param array $headers Map of header name to header value. 94 88 */ … … 100 94 * Sets a single HTTP header. 101 95 * 102 96 * @since 4.6.0 103 * @access public104 97 * 105 98 * @param string $key Header name. 106 99 * @param string $value Header value. … … 119 112 * Retrieves the HTTP return code for the response. 120 113 * 121 114 * @since 4.6.0 122 * @access public123 115 * 124 116 * @return int The 3-digit HTTP status code. 125 117 */ … … 131 123 * Sets the 3-digit HTTP status code. 132 124 * 133 125 * @since 4.6.0 134 * @access public135 126 * 136 127 * @param int $code HTTP status. 137 128 */ … … 143 134 * Retrieves the response data. 144 135 * 145 136 * @since 4.6.0 146 * @access public147 137 * 148 138 * @return mixed Response data. 149 139 */ … … 155 145 * Sets the response data. 156 146 * 157 147 * @since 4.6.0 158 * @access public159 148 * 160 149 * @param mixed $data Response data. 161 150 */ … … 167 156 * Retrieves cookies from the response. 168 157 * 169 158 * @since 4.6.0 170 * @access public171 159 * 172 160 * @return WP_HTTP_Cookie[] List of cookie objects. 173 161 */ … … 190 178 * Converts the object to a WP_Http response array. 191 179 * 192 180 * @since 4.6.0 193 * @access public194 181 * 195 182 * @return array WP_Http response array, per WP_Http::request(). 196 183 */ -
src/wp-includes/class-wp-http-response.php
18 18 * Response data. 19 19 * 20 20 * @since 4.4.0 21 * @access public22 21 * @var mixed 23 22 */ 24 23 public $data; … … 27 26 * Response headers. 28 27 * 29 28 * @since 4.4.0 30 * @access public31 29 * @var array 32 30 */ 33 31 public $headers; … … 36 34 * Response status. 37 35 * 38 36 * @since 4.4.0 39 * @access public40 37 * @var int 41 38 */ 42 39 public $status; … … 45 42 * Constructor. 46 43 * 47 44 * @since 4.4.0 48 * @access public49 45 * 50 46 * @param mixed $data Response data. Default null. 51 47 * @param int $status Optional. HTTP status code. Default 200. … … 61 57 * Retrieves headers associated with the response. 62 58 * 63 59 * @since 4.4.0 64 * @access public65 60 * 66 61 * @return array Map of header name to header value. 67 62 */ … … 73 68 * Sets all header values. 74 69 * 75 70 * @since 4.4.0 76 * @access public77 71 * 78 72 * @param array $headers Map of header name to header value. 79 73 */ … … 85 79 * Sets a single HTTP header. 86 80 * 87 81 * @since 4.4.0 88 * @access public89 82 * 90 83 * @param string $key Header name. 91 84 * @param string $value Header value. … … 104 97 * Retrieves the HTTP return code for the response. 105 98 * 106 99 * @since 4.4.0 107 * @access public108 100 * 109 101 * @return int The 3-digit HTTP status code. 110 102 */ … … 116 108 * Sets the 3-digit HTTP status code. 117 109 * 118 110 * @since 4.4.0 119 * @access public120 111 * 121 112 * @param int $code HTTP status. 122 113 */ … … 128 119 * Retrieves the response data. 129 120 * 130 121 * @since 4.4.0 131 * @access public132 122 * 133 123 * @return mixed Response data. 134 124 */ … … 140 130 * Sets the response data. 141 131 * 142 132 * @since 4.4.0 143 * @access public144 133 * 145 134 * @param mixed $data Response data. 146 135 */ … … 155 144 * however this may be different if you want to do custom JSON data handling. 156 145 * 157 146 * @since 4.4.0 158 * @access public159 147 * 160 148 * @return mixed Any JSON-serializable value. 161 149 */ -
src/wp-includes/class-wp-http-streams.php
22 22 * @since 2.7.0 23 23 * @since 3.7.0 Combined with the fsockopen transport and switched to stream_socket_client(). 24 24 * 25 * @access public26 25 * @param string $url The request URL. 27 26 * @param string|array $args Optional. Override the defaults. 28 27 * @return array|WP_Error Array containing 'headers', 'body', 'response', 'cookies', 'filename'. A WP_Error instance upon error … … 380 379 * Determines whether this class can be used for retrieving a URL. 381 380 * 382 381 * @static 383 * @access public384 382 * @since 2.7.0 385 383 * @since 3.7.0 Combined with the fsockopen transport and switched to stream_socket_client(). 386 384 * -
src/wp-includes/class-wp-image-editor-gd.php
17 17 /** 18 18 * GD Resource. 19 19 * 20 * @access protected21 20 * @var resource 22 21 */ 23 22 protected $image; … … 35 34 * @since 3.5.0 36 35 * 37 36 * @static 38 * @access public39 37 * 40 38 * @param array $args 41 39 * @return bool … … 61 59 * @since 3.5.0 62 60 * 63 61 * @static 64 * @access public65 62 * 66 63 * @param string $mime_type 67 64 * @return bool … … 84 81 * Loads image from $this->file into new GD Resource. 85 82 * 86 83 * @since 3.5.0 87 * @access public88 84 * 89 85 * @return bool|WP_Error True if loaded successfully; WP_Error on failure. 90 86 */ … … 122 118 * Sets or updates current image size. 123 119 * 124 120 * @since 3.5.0 125 * @access protected126 121 * 127 122 * @param int $width 128 123 * @param int $height … … 147 142 * maintain aspect ratio according to the provided dimension. 148 143 * 149 144 * @since 3.5.0 150 * @access public151 145 * 152 146 * @param int|null $max_w Image width. 153 147 * @param int|null $max_h Image height. … … 200 194 * Resize multiple images from a single source. 201 195 * 202 196 * @since 3.5.0 203 * @access public204 197 * 205 198 * @param array $sizes { 206 199 * An array of image size arrays. Default sizes are 'small', 'medium', 'medium_large', 'large'. … … 263 256 * Crops Image. 264 257 * 265 258 * @since 3.5.0 266 * @access public267 259 * 268 260 * @param int $src_x The start x position to crop from. 269 261 * @param int $src_y The start y position to crop from. … … 309 301 * Ported from image-edit.php 310 302 * 311 303 * @since 3.5.0 312 * @access public313 304 * 314 305 * @param float $angle 315 306 * @return true|WP_Error … … 335 326 * Flips current image. 336 327 * 337 328 * @since 3.5.0 338 * @access public339 329 * 340 330 * @param bool $horz Flip along Horizontal Axis 341 331 * @param bool $vert Flip along Vertical Axis … … 365 355 * Saves current in-memory image to file. 366 356 * 367 357 * @since 3.5.0 368 * @access public369 358 * 370 359 * @param string|null $filename 371 360 * @param string|null $mime_type … … 439 428 * Returns stream of current image. 440 429 * 441 430 * @since 3.5.0 442 * @access public443 431 * 444 432 * @param string $mime_type 445 433 * @return bool … … 464 452 * Either calls editor's save function or handles file as a stream. 465 453 * 466 454 * @since 3.5.0 467 * @access protected468 455 * 469 456 * @param string|stream $filename 470 457 * @param callable $function -
src/wp-includes/class-wp-image-editor-imagick.php
17 17 /** 18 18 * Imagick object. 19 19 * 20 * @access protected21 20 * @var Imagick 22 21 */ 23 22 protected $image; … … 39 38 * @since 3.5.0 40 39 * 41 40 * @static 42 * @access public43 41 * 44 42 * @param array $args 45 43 * @return bool … … 98 96 * @since 3.5.0 99 97 * 100 98 * @static 101 * @access public102 99 * 103 100 * @param string $mime_type 104 101 * @return bool … … 126 123 * Loads image from $this->file into new Imagick Object. 127 124 * 128 125 * @since 3.5.0 129 * @access public130 126 * 131 127 * @return true|WP_Error True if loaded; WP_Error on failure. 132 128 */ … … 181 177 * Sets Image Compression quality on a 1-100% scale. 182 178 * 183 179 * @since 3.5.0 184 * @access public185 180 * 186 181 * @param int $quality Compression Quality. Range: [1,100] 187 182 * @return true|WP_Error True if set successfully; WP_Error on failure. … … 214 209 * Sets or updates current image size. 215 210 * 216 211 * @since 3.5.0 217 * @access protected218 212 * 219 213 * @param int $width 220 214 * @param int $height … … 249 243 * maintain aspect ratio according to the provided dimension. 250 244 * 251 245 * @since 3.5.0 252 * @access public253 246 * 254 247 * @param int|null $max_w Image width. 255 248 * @param int|null $max_h Image height. … … 285 278 * which resizes an image to given dimensions and removes any associated profiles. 286 279 * 287 280 * @since 4.5.0 288 * @access protected289 281 * 290 282 * @param int $dst_w The destination width. 291 283 * @param int $dst_h The destination height. … … 417 409 * Resize multiple images from a single source. 418 410 * 419 411 * @since 3.5.0 420 * @access public421 412 * 422 413 * @param array $sizes { 423 414 * An array of image size arrays. Default sizes are 'small', 'medium', 'medium_large', 'large'. … … 488 479 * Crops Image. 489 480 * 490 481 * @since 3.5.0 491 * @access public492 482 * 493 483 * @param int $src_x The start x position to crop from. 494 484 * @param int $src_y The start y position to crop from. … … 535 525 * Rotates current image counter-clockwise by $angle. 536 526 * 537 527 * @since 3.5.0 538 * @access public539 528 * 540 529 * @param float $angle 541 530 * @return true|WP_Error … … 570 559 * Flips current image. 571 560 * 572 561 * @since 3.5.0 573 * @access public574 562 * 575 563 * @param bool $horz Flip along Horizontal Axis 576 564 * @param bool $vert Flip along Vertical Axis … … 594 582 * Saves current image to file. 595 583 * 596 584 * @since 3.5.0 597 * @access public598 585 * 599 586 * @param string $destfilename 600 587 * @param string $mime_type … … 664 651 * Streams current image to browser. 665 652 * 666 653 * @since 3.5.0 667 * @access public668 654 * 669 655 * @param string $mime_type 670 656 * @return true|WP_Error … … 694 680 * Strips all image meta except color profiles from an image. 695 681 * 696 682 * @since 4.5.0 697 * @access protected698 683 * 699 684 * @return true|WP_Error True if stripping metadata was successful. WP_Error object on error. 700 685 */ … … 747 732 * Increases rendering DPI and only loads first page. 748 733 * 749 734 * @since 4.7.0 750 * @access protected751 735 * 752 736 * @return string|WP_Error File to load or WP_Error on failure. 753 737 */ -
src/wp-includes/class-wp-image-editor.php
35 35 * @since 3.5.0 36 36 * 37 37 * @static 38 * @access public39 38 * @abstract 40 39 * 41 40 * @param array $args … … 52 51 * @since 3.5.0 53 52 * 54 53 * @static 55 * @access public56 54 * @abstract 57 55 * 58 56 * @param string $mime_type … … 66 64 * Loads image from $this->file into editor. 67 65 * 68 66 * @since 3.5.0 69 * @access public70 67 * @abstract 71 68 * 72 69 * @return bool|WP_Error True if loaded; WP_Error on failure. … … 77 74 * Saves current image to file. 78 75 * 79 76 * @since 3.5.0 80 * @access public81 77 * @abstract 82 78 * 83 79 * @param string $destfilename … … 94 90 * maintain aspect ratio according to the provided dimension. 95 91 * 96 92 * @since 3.5.0 97 * @access public98 93 * @abstract 99 94 * 100 95 * @param int|null $max_w Image width. … … 108 103 * Resize multiple images from a single source. 109 104 * 110 105 * @since 3.5.0 111 * @access public112 106 * @abstract 113 107 * 114 108 * @param array $sizes { … … 128 122 * Crops Image. 129 123 * 130 124 * @since 3.5.0 131 * @access public132 125 * @abstract 133 126 * 134 127 * @param int $src_x The start x position to crop from. … … 146 139 * Rotates current image counter-clockwise by $angle. 147 140 * 148 141 * @since 3.5.0 149 * @access public150 142 * @abstract 151 143 * 152 144 * @param float $angle … … 158 150 * Flips current image. 159 151 * 160 152 * @since 3.5.0 161 * @access public162 153 * @abstract 163 154 * 164 155 * @param bool $horz Flip along Horizontal Axis … … 171 162 * Streams current image to browser. 172 163 * 173 164 * @since 3.5.0 174 * @access public175 165 * @abstract 176 166 * 177 167 * @param string $mime_type … … 183 173 * Gets dimensions of image. 184 174 * 185 175 * @since 3.5.0 186 * @access public187 176 * 188 177 * @return array {'width'=>int, 'height'=>int} 189 178 */ … … 195 184 * Sets current image size. 196 185 * 197 186 * @since 3.5.0 198 * @access protected199 187 * 200 188 * @param int $width 201 189 * @param int $height … … 213 201 * Gets the Image Compression quality on a 1-100% scale. 214 202 * 215 203 * @since 4.0.0 216 * @access public217 204 * 218 205 * @return int $quality Compression Quality. Range: [1,100] 219 206 */ … … 229 216 * Sets Image Compression quality on a 1-100% scale. 230 217 * 231 218 * @since 3.5.0 232 * @access public233 219 * 234 220 * @param int $quality Compression Quality. Range: [1,100] 235 221 * @return true|WP_Error True if set successfully; WP_Error on failure. … … 298 284 * Provides corrected filename only if filename is provided. 299 285 * 300 286 * @since 3.5.0 301 * @access protected302 287 * 303 288 * @param string $filename 304 289 * @param string $mime_type … … 359 344 * Builds an output filename based on current file, and adding proper suffix 360 345 * 361 346 * @since 3.5.0 362 * @access public363 347 * 364 348 * @param string $suffix 365 349 * @param string $dest_path … … 387 371 * Builds and returns proper suffix for file based on height and width. 388 372 * 389 373 * @since 3.5.0 390 * @access public391 374 * 392 375 * @return false|string suffix 393 376 */ … … 402 385 * Either calls editor's save function or handles file as a stream. 403 386 * 404 387 * @since 3.5.0 405 * @access protected406 388 * 407 389 * @param string|stream $filename 408 390 * @param callable $function … … 445 427 * @since 3.5.0 446 428 * 447 429 * @static 448 * @access protected449 430 * 450 431 * @param string $extension 451 432 * @return string|false … … 473 454 * @since 3.5.0 474 455 * 475 456 * @static 476 * @access protected477 457 * 478 458 * @param string $mime_type 479 459 * @return string|false -
src/wp-includes/class-wp-list-util.php
18 18 * The input array. 19 19 * 20 20 * @since 4.7.0 21 * @access private22 21 * @var array 23 22 */ 24 23 private $input = array(); … … 27 26 * The output array. 28 27 * 29 28 * @since 4.7.0 30 * @access private31 29 * @var array 32 30 */ 33 31 private $output = array(); … … 36 34 * Temporary arguments for sorting. 37 35 * 38 36 * @since 4.7.0 39 * @access private40 37 * @var array 41 38 */ 42 39 private $orderby = array(); … … 58 55 * Returns the original input array. 59 56 * 60 57 * @since 4.7.0 61 * @access public62 58 * 63 59 * @return array The input array. 64 60 */ … … 70 66 * Returns the output array. 71 67 * 72 68 * @since 4.7.0 73 * @access public74 69 * 75 70 * @return array The output array. 76 71 */ … … 228 223 * Callback to sort the list by specific fields. 229 224 * 230 225 * @since 4.7.0 231 * @access private232 226 * 233 227 * @see WP_List_Util::sort() 234 228 * -
src/wp-includes/class-wp-locale-switcher.php
17 17 * Locale stack. 18 18 * 19 19 * @since 4.7.0 20 * @access private21 20 * @var string[] 22 21 */ 23 22 private $locales = array(); … … 26 25 * Original locale. 27 26 * 28 27 * @since 4.7.0 29 * @access private30 28 * @var string 31 29 */ 32 30 private $original_locale; … … 35 33 * Holds all available languages. 36 34 * 37 35 * @since 4.7.0 38 * @access private39 36 * @var array An array of language codes (file names without the .mo extension). 40 37 */ 41 38 private $available_languages = array(); … … 184 181 * When switching to a locale, translations for this locale must be loaded from scratch. 185 182 * 186 183 * @since 4.7.0 187 * @access private188 184 * 189 185 * @global Mo[] $l10n An array of all currently loaded text domains. 190 186 * … … 214 210 * all post type labels. 215 211 * 216 212 * @since 4.7.0 217 * @access private218 213 * 219 214 * @global WP_Locale $wp_locale The WordPress date and time locale object. 220 215 * -
src/wp-includes/class-wp-locale.php
99 99 * The thousands separator and decimal point values used for localizing numbers. 100 100 * 101 101 * @since 2.3.0 102 * @access public103 102 * @var array 104 103 */ 105 104 public $number_format; … … 122 121 * specific calendar names and text direction. 123 122 * 124 123 * @since 2.1.0 125 * @access public126 124 * 127 125 * @global string $text_direction 128 126 */ … … 240 238 * Outputs an admin notice if the /build directory must be used for RTL. 241 239 * 242 240 * @since 3.8.0 243 * @access public244 241 */ 245 242 public function rtl_src_admin_notice() { 246 243 /* translators: %s: Name of the directory (build) */ … … 255 252 * and ends on Saturday with is fetched by using 6 (six). 256 253 * 257 254 * @since 2.1.0 258 * @access public259 255 * 260 256 * @param int $weekday_number 0 for Sunday through 6 Saturday 261 257 * @return string Full translated weekday … … 273 269 * not conflict. 274 270 * 275 271 * @since 2.1.0 276 * @access public277 272 * 278 273 * @param string $weekday_name 279 274 * @return string … … 289 284 * full weekday word. 290 285 * 291 286 * @since 2.1.0 292 * @access public293 287 * 294 288 * @param string $weekday_name Full translated weekday word 295 289 * @return string Translated weekday abbreviation … … 310 304 * '0' before the numbers less than 10 for you. 311 305 * 312 306 * @since 2.1.0 313 * @access public314 307 * 315 308 * @param string|int $month_number '01' through '12' 316 309 * @return string Translated full month name … … 326 319 * translatable version of the month. 327 320 * 328 321 * @since 2.1.0 329 * @access public330 322 * 331 323 * @param string $month_name Translated month to get abbreviated version 332 324 * @return string Translated abbreviated month … … 341 333 * The $meridiem parameter is expected to not be translated. 342 334 * 343 335 * @since 2.1.0 344 * @access public345 336 * 346 337 * @param string $meridiem Either 'am', 'pm', 'AM', or 'PM'. Not translated version. 347 338 * @return string Translated version … … 356 347 * For backward compatibility only. 357 348 * 358 349 * @deprecated For backward compatibility only. 359 * @access public360 350 * 361 351 * @global array $weekday 362 352 * @global array $weekday_initial -
src/wp-includes/class-wp-matchesmapregex.php
15 15 /** 16 16 * store for matches 17 17 * 18 * @access private19 18 * @var array 20 19 */ 21 20 private $_matches; … … 23 22 /** 24 23 * store for mapping result 25 24 * 26 * @access public27 25 * @var string 28 26 */ 29 27 public $output; … … 31 29 /** 32 30 * subject to perform mapping on (query string containing $matches[] references 33 31 * 34 * @access private35 32 * @var string 36 33 */ 37 34 private $_subject; … … 61 58 * static helper function to ease use 62 59 * 63 60 * @static 64 * @access public65 61 * 66 62 * @param string $subject subject 67 63 * @param array $matches data used for substitution … … 75 71 /** 76 72 * do the actual mapping 77 73 * 78 * @access private79 74 * @return string 80 75 */ 81 76 private function _map() { … … 86 81 /** 87 82 * preg_replace_callback hook 88 83 * 89 * @access public90 84 * @param array $matches preg_replace regexp matches 91 85 * @return string 92 86 */ -
src/wp-includes/class-wp-meta-query.php
26 26 * See WP_Meta_Query::__construct() for information on meta query arguments. 27 27 * 28 28 * @since 3.2.0 29 * @access public30 29 * @var array 31 30 */ 32 31 public $queries = array(); … … 35 34 * The relation between the queries. Can be one of 'AND' or 'OR'. 36 35 * 37 36 * @since 3.2.0 38 * @access public39 37 * @var string 40 38 */ 41 39 public $relation; … … 44 42 * Database table to query for the metadata. 45 43 * 46 44 * @since 4.1.0 47 * @access public48 45 * @var string 49 46 */ 50 47 public $meta_table; … … 53 50 * Column in meta_table that represents the ID of the object the metadata belongs to. 54 51 * 55 52 * @since 4.1.0 56 * @access public57 53 * @var string 58 54 */ 59 55 public $meta_id_column; … … 62 58 * Database table that where the metadata's objects are stored (eg $wpdb->users). 63 59 * 64 60 * @since 4.1.0 65 * @access public66 61 * @var string 67 62 */ 68 63 public $primary_table; … … 71 66 * Column in primary_table that represents the ID of the object. 72 67 * 73 68 * @since 4.1.0 74 * @access public75 69 * @var string 76 70 */ 77 71 public $primary_id_column; … … 80 74 * A flat list of table aliases used in JOIN clauses. 81 75 * 82 76 * @since 4.1.0 83 * @access protected84 77 * @var array 85 78 */ 86 79 protected $table_aliases = array(); … … 89 82 * A flat list of clauses, keyed by clause 'name'. 90 83 * 91 84 * @since 4.2.0 92 * @access protected93 85 * @var array 94 86 */ 95 87 protected $clauses = array(); … … 98 90 * Whether the query contains any OR relations. 99 91 * 100 92 * @since 4.3.0 101 * @access protected102 93 * @var bool 103 94 */ 104 95 protected $has_or_relation = false; … … 109 100 * @since 3.2.0 110 101 * @since 4.2.0 Introduced support for naming query clauses by associative array keys. 111 102 * 112 * @access public113 103 * 114 104 * @param array $meta_query { 115 105 * Array of meta query clauses. When first-order clauses or sub-clauses use strings as … … 153 143 * Eliminates empty items and ensures that a 'relation' is set. 154 144 * 155 145 * @since 4.1.0 156 * @access public157 146 * 158 147 * @param array $queries Array of query clauses. 159 148 * @return array Sanitized array of query clauses. … … 222 211 * a 'value' array key. 223 212 * 224 213 * @since 4.1.0 225 * @access protected226 214 * 227 215 * @param array $query Meta query arguments. 228 216 * @return bool Whether the query clause is a first-order clause. … … 235 223 * Constructs a meta query based on 'meta_*' query vars 236 224 * 237 225 * @since 3.2.0 238 * @access public239 226 * 240 227 * @param array $qv The query variables 241 228 */ … … 283 270 * Return the appropriate alias for the given meta type if applicable. 284 271 * 285 272 * @since 3.7.0 286 * @access public287 273 * 288 274 * @param string $type MySQL type to cast meta_value. 289 275 * @return string MySQL type. … … 307 293 * Generates SQL clauses to be appended to a main query. 308 294 * 309 295 * @since 3.2.0 310 * @access public311 296 * 312 297 * @param string $type Type of meta, eg 'user', 'post'. 313 298 * @param string $primary_table Database table where the object being filtered is stored (eg wp_users). … … 365 350 * out to maintain parity with the other Query classes. 366 351 * 367 352 * @since 4.1.0 368 * @access protected369 353 * 370 354 * @return array { 371 355 * Array containing JOIN and WHERE SQL clauses to append to the main query. … … 396 380 * produce the properly nested SQL. 397 381 * 398 382 * @since 4.1.0 399 * @access protected400 383 * 401 384 * @param array $query Query to parse, passed by reference. 402 385 * @param int $depth Optional. Number of tree levels deep we currently are. … … 480 463 * "First-order" means that it's an array with a 'key' or 'value'. 481 464 * 482 465 * @since 4.1.0 483 * @access public484 466 * 485 467 * @global wpdb $wpdb WordPress database abstraction object. 486 468 * … … 658 640 * a value of 'orderby' corresponding to a meta clause. 659 641 * 660 642 * @since 4.2.0 661 * @access public662 643 * 663 644 * @return array Meta clauses. 664 645 */ … … 681 662 * connected by the relation 'OR'. 682 663 * 683 664 * @since 4.1.0 684 * @access protected685 665 * 686 666 * @param array $clause Query clause. 687 667 * @param array $parent_query Parent query of $clause. -
src/wp-includes/class-wp-metadata-lazyloader.php
33 33 * Pending objects queue. 34 34 * 35 35 * @since 4.5.0 36 * @access protected37 36 * @var array 38 37 */ 39 38 protected $pending_objects; … … 42 41 * Settings for supported object types. 43 42 * 44 43 * @since 4.5.0 45 * @access protected46 44 * @var array 47 45 */ 48 46 protected $settings = array(); … … 51 49 * Constructor. 52 50 * 53 51 * @since 4.5.0 54 * @access public55 52 */ 56 53 public function __construct() { 57 54 $this->settings = array( … … 70 67 * Adds objects to the metadata lazy-load queue. 71 68 * 72 69 * @since 4.5.0 73 * @access public74 70 * 75 71 * @param string $object_type Type of object whose meta is to be lazy-loaded. Accepts 'term' or 'comment'. 76 72 * @param array $object_ids Array of object IDs. … … 112 108 * Resets lazy-load queue for a given object type. 113 109 * 114 110 * @since 4.5.0 115 * @access public116 111 * 117 112 * @param string $object_type Object type. Accepts 'comment' or 'term'. 118 113 * @return bool|WP_Error True on success, WP_Error on failure. … … 135 130 * is no need to invoke it directly. 136 131 * 137 132 * @since 4.5.0 138 * @access public139 133 * 140 134 * @param mixed $check The `$check` param passed from the 'get_term_metadata' hook. 141 135 * @return mixed In order not to short-circuit `get_metadata()`. Generally, this is `null`, but it could be -
src/wp-includes/class-wp-network-query.php
20 20 * SQL for database query. 21 21 * 22 22 * @since 4.6.0 23 * @access public24 23 * @var string 25 24 */ 26 25 public $request; … … 29 28 * SQL query clauses. 30 29 * 31 30 * @since 4.6.0 32 * @access protected33 31 * @var array 34 32 */ 35 33 protected $sql_clauses = array( … … 45 43 * Query vars set by the user. 46 44 * 47 45 * @since 4.6.0 48 * @access public49 46 * @var array 50 47 */ 51 48 public $query_vars; … … 54 51 * Default values for query vars. 55 52 * 56 53 * @since 4.6.0 57 * @access public58 54 * @var array 59 55 */ 60 56 public $query_var_defaults; … … 63 59 * List of networks located by the query. 64 60 * 65 61 * @since 4.6.0 66 * @access public67 62 * @var array 68 63 */ 69 64 public $networks; … … 72 67 * The amount of found networks for the current query. 73 68 * 74 69 * @since 4.6.0 75 * @access public76 70 * @var int 77 71 */ 78 72 public $found_networks = 0; … … 81 75 * The number of pages. 82 76 * 83 77 * @since 4.6.0 84 * @access public85 78 * @var int 86 79 */ 87 80 public $max_num_pages = 0; … … 92 85 * Sets up the network query, based on the query vars passed. 93 86 * 94 87 * @since 4.6.0 95 * @access public96 88 * 97 89 * @param string|array $query { 98 90 * Optional. Array or query string of network query parameters. Default empty. … … 152 144 * 153 145 * @since 4.6.0 154 146 * 155 * @access public156 147 * 157 148 * @param string|array $query WP_Network_Query arguments. See WP_Network_Query::__construct() 158 149 */ … … 177 168 * Sets up the WordPress query for retrieving networks. 178 169 * 179 170 * @since 4.6.0 180 * @access public181 171 * 182 172 * @param string|array $query Array or URL query string of parameters. 183 173 * @return array|int List of networks, or number of networks when 'count' is passed as a query var. … … 191 181 * Gets a list of networks matching the query vars. 192 182 * 193 183 * @since 4.6.0 194 * @access public195 184 * 196 185 * @return int|array The list of networks. 197 186 */ … … 284 273 * Used internally to get a list of network IDs matching the query vars. 285 274 * 286 275 * @since 4.6.0 287 * @access protected288 276 * 289 277 * @global wpdb $wpdb WordPress database abstraction object. 290 278 * … … 461 449 * if the limit clause was used. 462 450 * 463 451 * @since 4.6.0 464 * @access private465 452 * 466 453 * @global wpdb $wpdb WordPress database abstraction object. 467 454 */ … … 487 474 * Used internally to generate an SQL string for searching across multiple columns. 488 475 * 489 476 * @since 4.6.0 490 * @access protected491 477 * 492 478 * @global wpdb $wpdb WordPress database abstraction object. 493 479 * … … 513 499 * Parses and sanitizes 'orderby' keys passed to the network query. 514 500 * 515 501 * @since 4.6.0 516 * @access protected517 502 * 518 503 * @global wpdb $wpdb WordPress database abstraction object. 519 504 * … … 547 532 * Parses an 'order' query variable and cast it to 'ASC' or 'DESC' as necessary. 548 533 * 549 534 * @since 4.6.0 550 * @access protected551 535 * 552 536 * @param string $order The 'order' query variable. 553 537 * @return string The sanitized 'order' query variable. -
src/wp-includes/class-wp-network.php
30 30 * @since 4.6.0 Converted from public to private to explicitly enable more intuitive 31 31 * access via magic methods. As part of the access change, the type was 32 32 * also changed from `string` to `int`. 33 * @access private34 33 * @var int 35 34 */ 36 35 private $id; … … 39 38 * Domain of the network. 40 39 * 41 40 * @since 4.4.0 42 * @access public43 41 * @var string 44 42 */ 45 43 public $domain = ''; … … 48 46 * Path of the network. 49 47 * 50 48 * @since 4.4.0 51 * @access public52 49 * @var string 53 50 */ 54 51 public $path = ''; … … 62 59 * A numeric string, for compatibility reasons. 63 60 * 64 61 * @since 4.4.0 65 * @access private66 62 * @var string 67 63 */ 68 64 private $blog_id = '0'; … … 71 67 * Domain used to set cookies for this network. 72 68 * 73 69 * @since 4.4.0 74 * @access public75 70 * @var string 76 71 */ 77 72 public $cookie_domain = ''; … … 82 77 * Named "site" vs. "network" for legacy reasons. 83 78 * 84 79 * @since 4.4.0 85 * @access public86 80 * @var string 87 81 */ 88 82 public $site_name = ''; … … 91 85 * Retrieve a network from the database by its ID. 92 86 * 93 87 * @since 4.4.0 94 * @access public95 88 * 96 89 * @global wpdb $wpdb WordPress database abstraction object. 97 90 * … … 128 121 * default properties based on that information. 129 122 * 130 123 * @since 4.4.0 131 * @access public132 124 * 133 125 * @param WP_Network|object $network A network object. 134 126 */ … … 147 139 * Allows current multisite naming conventions when getting properties. 148 140 * 149 141 * @since 4.6.0 150 * @access public151 142 * 152 143 * @param string $key Property to get. 153 144 * @return mixed Value of the property. Null if not available. … … 171 162 * Allows current multisite naming conventions when checking for properties. 172 163 * 173 164 * @since 4.6.0 174 * @access public175 165 * 176 166 * @param string $key Property to check if set. 177 167 * @return bool Whether the property is set. … … 193 183 * Allows current multisite naming conventions while setting properties. 194 184 * 195 185 * @since 4.6.0 196 * @access public197 186 * 198 187 * @param string $key Property to set. 199 188 * @param mixed $value Value to assign to the property. … … 216 205 * Set the site name assigned to the network if one has not been populated. 217 206 * 218 207 * @since 4.4.0 219 * @access private220 208 */ 221 209 private function _set_site_name() { 222 210 if ( ! empty( $this->site_name ) ) { … … 234 222 * @todo What if the domain of the network doesn't match the current site? 235 223 * 236 224 * @since 4.4.0 237 * @access private238 225 */ 239 226 private function _set_cookie_domain() { 240 227 if ( ! empty( $this->cookie_domain ) ) { … … 258 245 * requested site address. 259 246 * 260 247 * @since 4.4.0 261 * @access public262 248 * @static 263 249 * 264 250 * @param string $domain Domain to check. -
src/wp-includes/class-wp-oembed-controller.php
20 20 * Register the oEmbed REST API route. 21 21 * 22 22 * @since 4.4.0 23 * @access public24 23 */ 25 24 public function register_routes() { 26 25 /** … … 101 100 * Returns the JSON object for the post. 102 101 * 103 102 * @since 4.4.0 104 * @access public105 103 * 106 104 * @param WP_REST_Request $request Full data about the request. 107 105 * @return WP_Error|array oEmbed response data or WP_Error on failure. … … 132 130 * Checks if current user can make a proxy oEmbed request. 133 131 * 134 132 * @since 4.8.0 135 * @access public136 133 * 137 134 * @return true|WP_Error True if the request has read access, WP_Error object otherwise. 138 135 */ … … 149 146 * Returns the JSON object for the proxied item. 150 147 * 151 148 * @since 4.8.0 152 * @access public153 149 * 154 150 * @see WP_oEmbed::get_html() 155 151 * @param WP_REST_Request $request Full data about the request. -
src/wp-includes/class-wp-post-type.php
19 19 * Post type key. 20 20 * 21 21 * @since 4.6.0 22 * @access public23 22 * @var string $name 24 23 */ 25 24 public $name; … … 28 27 * Name of the post type shown in the menu. Usually plural. 29 28 * 30 29 * @since 4.6.0 31 * @access public32 30 * @var string $label 33 31 */ 34 32 public $label; … … 42 40 * @see get_post_type_labels() 43 41 * 44 42 * @since 4.6.0 45 * @access public46 43 * @var object $labels 47 44 */ 48 45 public $labels; … … 53 50 * Default empty. 54 51 * 55 52 * @since 4.6.0 56 * @access public57 53 * @var string $description 58 54 */ 59 55 public $description = ''; … … 67 63 * Default false. 68 64 * 69 65 * @since 4.6.0 70 * @access public71 66 * @var bool $public 72 67 */ 73 68 public $public = false; … … 78 73 * Default false. 79 74 * 80 75 * @since 4.6.0 81 * @access public82 76 * @var bool $hierarchical 83 77 */ 84 78 public $hierarchical = false; … … 90 84 * Default is the opposite value of $public. 91 85 * 92 86 * @since 4.6.0 93 * @access public94 87 * @var bool $exclude_from_search 95 88 */ 96 89 public $exclude_from_search = null; … … 106 99 * Default is the value of $public. 107 100 * 108 101 * @since 4.6.0 109 * @access public110 102 * @var bool $publicly_queryable 111 103 */ 112 104 public $publicly_queryable = null; … … 117 109 * Default is the value of $public. 118 110 * 119 111 * @since 4.6.0 120 * @access public121 112 * @var bool $show_ui 122 113 */ 123 114 public $show_ui = null; … … 132 123 * Default is the value of $show_ui. 133 124 * 134 125 * @since 4.6.0 135 * @access public136 126 * @var bool $show_in_menu 137 127 */ 138 128 public $show_in_menu = null; … … 143 133 * Default is the value $public. 144 134 * 145 135 * @since 4.6.0 146 * @access public147 136 * @var bool $show_in_nav_menus 148 137 */ 149 138 public $show_in_nav_menus = null; … … 154 143 * Default is the value of $show_in_menu. 155 144 * 156 145 * @since 4.6.0 157 * @access public158 146 * @var bool $show_in_admin_bar 159 147 */ 160 148 public $show_in_admin_bar = null; … … 165 153 * To work, $show_in_menu must be true. Default null (at the bottom). 166 154 * 167 155 * @since 4.6.0 168 * @access public169 156 * @var int $menu_position 170 157 */ 171 158 public $menu_position = null; … … 181 168 * Defaults to use the posts icon. 182 169 * 183 170 * @since 4.6.0 184 * @access public185 171 * @var string $menu_icon 186 172 */ 187 173 public $menu_icon = null; … … 194 180 * array( 'story', 'stories' ). Default 'post'. 195 181 * 196 182 * @since 4.6.0 197 * @access public198 183 * @var string $capability_type 199 184 */ 200 185 public $capability_type = 'post'; … … 205 190 * Default false. 206 191 * 207 192 * @since 4.6.0 208 * @access public209 193 * @var bool $map_meta_cap 210 194 */ 211 195 public $map_meta_cap = false; … … 216 200 * Do `remove_meta_box()` and `add_meta_box()` calls in the callback. Default null. 217 201 * 218 202 * @since 4.6.0 219 * @access public220 203 * @var string $register_meta_box_cb 221 204 */ 222 205 public $register_meta_box_cb = null; … … 229 212 * Default empty array. 230 213 * 231 214 * @since 4.6.0 232 * @access public233 215 * @var array $taxonomies 234 216 */ 235 217 public $taxonomies = array(); … … 240 222 &nbs