Skip to content

Instantly share code, notes, and snippets.

View joellewebfx's full-sized avatar

Joelle Abejero joellewebfx

View GitHub Profile
@joellewebfx
joellewebfx / LMFX-recaptcha-flagger-cf7.php
Created October 13, 2025 16:12
Detect Contact Form 7 spam submissions and dispatch a CustomEvent so front-end can react. Supports AJAX (wpcf7spam) and non-AJAX fallback.
<?php
/**
* Plugin Name: CF7 Spam Footer Injector
* Description: Detect Contact Form 7 spam submissions and dispatch a CustomEvent so front-end can react. Supports AJAX (wpcf7spam) and non-AJAX fallback.
* Version: 1.0.0
* Author: WebFX Dev Team
* License: GPLv2 or later
*/
if ( ! defined( 'ABSPATH' ) ) {
@joellewebfx
joellewebfx / product-page-estimated-tax.php
Last active April 14, 2025 00:36
Calculate tax with Avatax and Product Page Shipping Calculator
<?php
/*
Plugin Name: Product Page Estimated Tax
Description: Adds a custom estimated tax to the product page. Integrated with Avalara - Woocommerce and Product Page Shipping Calculator.
Author: WebFX
Version: 1.0
*/
// Add necessary JavaScript variables
add_action('wp_enqueue_scripts', 'fx_tax_estimate_scripts');
@joellewebfx
joellewebfx / parse_blocks_get_acf_value.php
Last active June 21, 2024 08:25
Retrieve ACF values from block
<?php
/**
* Retrieve ACF value from a block
*
* This function returns the category and image IDs in a repeater ACF
* that is located inside a block.
*
*/
function get_repeater_gallery() {
$gallery_categories = [];