A Pen by Uriel Wilson on CodePen.
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
WP_HOME=http://localhost | |
WP_SITEURL=http://localhost | |
DB_NAME= | |
DB_USER=root | |
DB_PASSWORD= | |
DB_HOST=127.0.0.1 | |
DB_PREFIX= | |
WP_ENV=production |
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
{ | |
"require": { | |
"php": "^7.0", | |
"roots/wp-config": "1.0.0", | |
"symfony/error-handler": "^5.1", | |
"symfony/var-dumper": "^5.1.4", | |
"vlucas/phpdotenv": "^5.2" | |
}, | |
"config": { | |
"optimize-autoloader": true, |
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 | |
if ( !function_exists( 'is_rest' ) ) { | |
/** | |
* Checks if the current request is a WP REST API request. | |
* | |
* Case #1: After WP_REST_Request initialisation | |
* Case #2: Support "plain" permalink settings | |
* Case #3: It can happen that WP_Rewrite is not yet initialized, | |
* so do this (wp-settings.php) |
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 | |
// https://make.wordpress.org/core/2020/11/02/introducing-auto-updates-interface-for-core-major-versions-in-wordpress-5-6/ | |
function my_plugin_after_core_auto_updates_settings_fields( $auto_update_settings ) { | |
if ( isset( $_POST['core-auto-updates-settings'] ) && wp_verify_nonce( $_POST['set_core_auto_updates_settings'], 'core-auto-updates-nonce' ) ) { | |
if ( isset( $_POST['my-plugin-core-auto-updates-minor'] ) && 1 === (int) $_POST['my-plugin-core-auto-updates-minor'] ) { | |
update_site_option( 'my_plugin_auto_update_core_minor', 1 ); | |
} else { | |
update_site_option( 'my_plugin_auto_update_core_minor', 0 ); | |
} |
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 | |
/** | |
* Insert an attachment from an URL address. | |
* | |
* @param String $url | |
* @param Int $parent_post_id | |
* @return Int Attachment ID | |
*/ | |
function crb_insert_attachment_from_url($url, $parent_post_id = null) { |
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
.loader | |
- 1..12.times do | |
.prong | |
.inner |
A Pen by Uriel Wilson on CodePen.
The popular open-source contract for web professionals by Stuff & Nonsense
- Originally published: 23rd December 2008
- Revised date: March 15th 2016
- Original post
A Pen by Sterling Heibeck on CodePen.