Unix Error that i get
Server:
ERROR: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
Solution 💡
Run on Terminal
Unix Error that i get
Server:
ERROR: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
Solution 💡
Run on Terminal
class Customise_WordPress {
function __construct($name) {
// Remove the REST API HTML entities.
$post_type = "post";
add_filter( 'rest_prepare_ . $post_type', array( $this, 'decode_rest_api_title' ), 20, 3 );
}
/**
SELECT
wpp.post_title,
CONCAT(wpo_su.option_value, REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(wpo.option_value, '%year%', DATE_FORMAT(wpp.post_date, '%Y')), '%monthnum%', DATE_FORMAT(wpp.post_date, '%m')), '%day%', DATE_FORMAT(wpp.post_date, '%d')), '%postname%', wpp.post_name), '%category%', wpp.post_name)) AS permalink
FROM wp_posts wpp
INNER JOIN wp_options wpo
ON wpo.option_name = 'permalink_structure'
INNER JOIN wp_options wpo_su
ON wpo_su.option_name = 'siteurl'
INNER JOIN wp_term_relationships ON wpp.ID = wp_term_relationships.object_id
Try This one on your functions.php
or main Plugin file
add_filter('register_block_type_args', function ($settings, $name) {
if ($name == 'demo/content-with-sidebar') {
$settings['render_callback'] = 'demo_blocks_content_with_sidebar';
}
return $settings;
}, null, 2);
const websiteUrl = ""; | |
function mainLoop(){ | |
// createSheets(); | |
fetchApi( websiteUrl ); | |
} | |
const headersList = { | |
"Accept": "*/*", | |
"User-Agent": "Thunder Client (https://www.thunderclient.com)", |
PHP setup useful commands
phpcs_ipath=$(phpcs --config-show installed_paths); oldpath=${phpcs_ipath##*:}; phpcs --config-set installed_paths ${oldpath},$(pwd)
[ | |
{ | |
"Country Code": "AF", | |
"Country Name": "Afghanistan", | |
"GMT Offset": "UTC+04:30" | |
}, | |
{ | |
"Country Code": "AL", | |
"Country Name": "Albania", | |
"GMT Offset": "UTC+01:00" |
Individual site If you have a site with slug blog on a WordPress multisite instance using subdomains, you can use the full URL to run a command against the site:
wp --url=blog.example.com
Think of the --url= parameter as any URL you can put in your browser.
Multiple sites Need to run a given WP-CLI command against multiple sites on a WordPress multisite install? You can do so using a combination of wp site list and xargs.