Skip to content

Instantly share code, notes, and snippets.

View digitalchild's full-sized avatar

Jamie Madden digitalchild

View GitHub Profile
@digitalchild
digitalchild / sotw.md
Created December 3, 2025 08:54
SOTW 2025 TL;DR;

TL;DR: State of the Word 2025 Key Updates

The State of the Word 2025 event highlighted the continued global expansion of WordPress, the launch of version 6.9, and foundational strategic investments in AI that focus on empowering users and contributors.

WordPress Growth and Global Reach

  • Market Dominance: WordPress powers over 40% of the web and accounts for approximately 60% of the CMS market.
  • Global Adoption: Over 56% of WordPress sites are now in non-English languages. Japanese is the second most popular language used in WordPress today.
  • Enterprise Use: WordPress is growing among top-tier sites, now used by 49.4% of the world's top 1000 websites, an increase of 2.3% from last year.
  • Ecosystem Health: The ecosystem features over 60,000 approved plugins (up 68% since 2024), totaling 74,000 plugins and themes. There have been 2.1 billion plugin downloads this year.
@digitalchild
digitalchild / playwright.js
Created June 24, 2025 04:24
Playwright session persistance
const { chromium } = require('playwright');
async function createPersistentSession() {
// Create a persistent context (saves cookies, localStorage, etc.)
const context = await chromium.launchPersistentContext('./user-data', {
headless: false, // Set to true for production
viewport: { width: 1920, height: 1080 },
userAgent: 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36',
args: [
'--disable-blink-features=AutomationControlled',
@digitalchild
digitalchild / gist:f012dd4a733ad7cf7e9f5c098bee9505
Created November 14, 2023 07:43
German Subtitles "What kind of WordPress theme do I have: classic, block, or something else?
Github Issue: https://github.com/WordPress/Learn/issues/1873
Prompt:
I need your help with translation from english to german. I have the english translation and the german translation. Would you be able to tell me if the german translation is correct?
Response:
Absolutely, I'd be happy to help with that. Please provide both the English text and the German translation, and I'll review the German version for accuracy and correctness.
# Setup for the Automating WordPress with no code commands
# Install npm
npm install -g npm@latest
# Install n8n with npm
npm install n8n -g
# Fix Authorization 401 for n8n and localwp WooCommerce REST API
# https://www.schakko.de/2020/09/05/fixing-http-401-unauthorized-when-calling-woocommerces-rest-api/
@digitalchild
digitalchild / MchIPUtils.php
Created February 11, 2023 03:24
Updated MchIPUtils file to support PHP8.0 for Invisible recaptcha plugin https://wordpress.org/plugins/invisible-recaptcha/
<?php
/**
* Copyright (c) 2016 Ultra Community (http://www.ultracommunity.com)
*
* Replace this file in invisible-recaptcha/includes/utils/MchIPUtils.php
*/
namespace InvisibleReCaptcha\MchLib\Utils;
final class MchIPUtils
<?php
function change_billing_fields( $fields ){
$fields['billing_postcode']['label'] = '';
$fields['billing_postcode']['placeholder'] = 'Postcode monkey*';
$fields['billing_email']['label'] = '';
$fields['billing_email']['placeholder'] = 'Email*';
$fields['billing_phone']['label'] = '';
$fields['billing_phone']['placeholder'] = 'Phone*';
return $fields;
@digitalchild
digitalchild / asset.js
Created February 1, 2023 05:29
Multiple file Gist Example
var somejsfile;
@digitalchild
digitalchild / functions.php
Created March 14, 2022 03:51
Add the vendor role to an instructor when they are approved.
<?php
/**
* Required Tutor LMS v.1.6.0
*/
add_action('tutor_new_instructor_after', 'wcv_add_vendor_role');
/**
* @param $instructor_id
*
@digitalchild
digitalchild / functions.php
Created February 9, 2022 04:01
Force product type, hide tabs and show only price field on WC Vendors Product Edit Standard form.
<?php
// Disable the product type drop down.
add_filter('wcv_disable_product_type', function() { return true; } );
add_filter( 'wcv_product_meta_tabs', function() { return array(); } );
// Adjust styles of the product tabs after removing them.
add_action('wp_head', 'wcv_add_custom_styles', 10);
function wcv_add_custom_styles() {
echo "<style>.tabs-nav { display: none!important;}</style>";
@digitalchild
digitalchild / functions.php
Created January 19, 2022 07:04
Disable the orders page on the WC Vendors Pro dashboard.
<?php
/**
* Disable existing order page hook into the dashboard links filter
*
* filter: wcv_pro_dashboard_urls
*/
add_filter( 'wcv_pro_dashboard_urls', 'wcv_remove_order_page' );
function wcv_remove_order_page( $pages ){