These are called in extensions. For example, the following module has some hooks:
local M = {}
M.onBeamNGTrigger = function(data)
-- ...
end
<?php | |
/** | |
* Define which Stripe webhook applications are permitted, then exclude any other webhook request coming through. | |
* | |
* This is expecially useful when you have multiple websites sharing the same Stripe account. | |
* Then, you gonna see multiple webhook requests coming from different applications. | |
* This snippet will allow you to filter out the ones you don't want to process. | |
*/ |
<?php | |
/** | |
* Don't apply coupons to the product addons from PPOM for WooCommerce plugin. | |
ì */ | |
add_filter( 'woocommerce_coupon_get_discount_amount', function ( $discount, $discounting_amount, $cart_item, $single, $coupon ) { | |
if ( ! function_exists( 'ppom_get_field_prices' ) || ! function_exists( 'ppom_price_get_addon_total' ) ) { | |
return $discount; | |
} | |
if ( $coupon->is_type( 'percent' ) ) { |
<?php | |
/** | |
* Remove "Cancel" button for cancelled subscriptions. | |
* | |
* The user is still able to cancel auto-renew, but can't completely cancel the membership. | |
*/ | |
add_filter( 'pmpro_member_action_links', function ( $pmpro_member_action_links ) { | |
global $current_user; | |
// bail if cancel link has been removed by someone else |
-- Simhub telemetry mod, Wotever 2023 | |
local M = {} | |
local ip = "127.0.0.1" | |
local port = 9999 | |
local updateRate = 100 | |
local udpSocket = nil | |
local lastSimHubFrameData = nil | |
local abs = math.abs | |
local ffi = require("ffi") |
/** | |
* @name MarkerClustererPlus for Google Maps V3 | |
* @version 2.1.2 [May 28, 2014] | |
* @author Gary Little | |
* @fileoverview | |
* The library creates and manages per-zoom-level clusters for large amounts of markers. | |
* <p> | |
* This is an enhanced V3 implementation of the | |
* <a href="http://gmaps-utility-library-dev.googlecode.com/svn/tags/markerclusterer/" | |
* >V2 MarkerClusterer</a> by Xiaoxi Wu. It is based on the |
<?php | |
add_action( 'wp_enqueue_scripts', function () { | |
wp_dequeue_style( 'wpml-legacy-horizontal-list-0' ); | |
wp_dequeue_style( 'wpml-menu-item-0' ); | |
} ); |
#!/usr/bin/env bash | |
# inspired by | |
# https://gist.github.com/JannikArndt/feb720c1f5d210b4820b880af23f2a07 | |
# which was inspired by | |
# https://github.com/fwartner/mac-cleanup/blob/master/cleanup.sh | |
# https://gist.github.com/jamesrampton/4503412 | |
# https://github.com/mengfeng/clean-my-mac/blob/master/clean_my_mac.sh | |
# https://github.com/szymonkaliski/Dotfiles/blob/master/Scripts/clean-my-mac | |
# http://brettterpstra.com/2015/10/27/vacuuming-mail-dot-app-on-el-capitan/ / https://github.com/pbihq/tools/blob/master/MailDBOptimiser.sh |
(function () { | |
jQuery(function ($) { | |
// iubenda + vimeo: don't suppress dnt=1 videos | |
$(document).on('elementor/popup/show', sedweb_gdpr_unsuppress_vimeo_dnt); | |
sedweb_gdpr_unsuppress_vimeo_dnt(); | |
function sedweb_gdpr_unsuppress_vimeo_dnt() { | |
let suppressedIframes = $('iframe[suppressedsrc]'); | |
suppressedIframes.each(function () { |
<?php | |
// these are the hooks sg-cachepress uses | |
add_action( 'upgrader_process_complete', 'clean_cache_after_critical_action' ); | |
add_action( 'automatic_updates_complete', 'clean_cache_after_critical_action' ); | |
add_action( '_core_updated_successfully', 'clean_cache_after_critical_action' ); | |
// this has been found in litespeed-cache | |
add_action( 'admin_action_do-plugin-upgrade', 'clean_cache_after_critical_action' ); | |
function clean_cache_after_critical_action() { |