This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Get the value for a docblock line. | |
* | |
* @param string $key The key for a docblock line. | |
* @return string The value for a docblock line. | |
*/ | |
function get_value_from_docblock( $key ) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function set_main_file_name() { | |
// Grab the slug name for this Bitbucket repo. | |
$slug = $this -> slug; | |
// Grab the list of file names in this repo. | |
$file_list = $this -> file_list; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Store a "shallow" list of repos. | |
*/ | |
public function set_repo_list() { | |
... | |
// Let's get 100 per page, which is the maximum. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* A class for handling errors. | |
* | |
* @package WordPress | |
* @subpackage WP_Multi_Error | |
* @since WP_Multi_Error 0.1 | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class myDemo { | |
public function __construct() { | |
// The url for a custom endpoint registered via register_rest_route(). | |
$this -> url = 'http://domain.com/wp-json/namespace/v1/endpoint'; | |
// The custom route happens to require a url param, 'meta_key' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$_tests_dir = getenv( 'WP_TESTS_DIR' ); | |
if ( ! $_tests_dir ) { | |
$_tests_dir = '../../../../'; | |
} | |
require_once $_tests_dir . '/includes/functions.php'; | |
function _manually_load_plugin() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* A custom control for picking a color with alpha trans. | |
* | |
* @see https://github.com/BraadMartin/components/tree/master/customizer/alpha-color-picker | |
* @see http://braadmartin.com/alpha-color-picker-control-for-the-wordpress-customizer/ | |
* | |
* @package WordPress | |
* @subpackage lxb-apple-fritter |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
array(2) { | |
["parent"] => string(16) "menu_item_parent" | |
["id"] => string(5) "db_id" | |
} | |
?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
array(3) { | |
[0]=> string(9) "post_type" | |
[1]=> string(8) "taxonomy" | |
[2]=> string(6) "custom" | |
} | |
?> |