View edd_perpetual_discounts.php
This file contains 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 | |
add_filter( 'edd_update_discount', 'edd_perpetual_discounts_add_meta' ); | |
add_filter( 'edd_insert_discount', 'edd_perpetual_discounts_add_meta' ); | |
add_action( 'edd_edit_discount_form_before_use_once', 'edd_perpetual_discounts_setting', 10, 2 ); | |
add_filter( 'edd_get_option_recurring_one_time_discounts', 'edd_perpetual_discounts_discounts' ); | |
function edd_perpetual_discounts_add_meta( $meta ) { | |
$meta['use_renewals'] = 0; |
View SyncGamesToNAS.ps1
This file contains 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
<# Source game library #> | |
$dir = dir "D:\Game Libraries\Steam Library\steamapps\common\" | ?{$_.PSISContainer}; | |
<# Mapped network drive / destination path. #> | |
$nasPath = "G:\Steam Library\steamapps\common"; | |
$log = "E:\gamecopy.log"; | |
Remove-Item $log; | |
$dir | ForEach-Object { |
View helpers.php
This file contains 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 | |
/** | |
* Extract shortcodes from content. | |
* | |
* @param string $content Content containing shortcodes. | |
* | |
* @return array Array of shortcodes found. | |
*/ | |
function get_shortcodes_from_content( $content ) { |
View eddsl-auto-activate.php
This file contains 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 | |
add_filter( 'edd_sl_is_site_active', 'your_namespace_is_site_active_auto_activate_site', 10, 3 ); | |
/** | |
* Allow active licenses to get updates if they're not at the limit, no matter what. | |
* | |
* @param false $is_active | |
* @param int $license_id | |
* @param string $passed_site_url |
View force-pm-asset-caching-on.php
This file contains 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 | |
add_action( 'wp_enqueue_scripts', 'custom_force_pm_asset_caching', 11 ); | |
function custom_force_pm_asset_caching() { | |
wp_deregister_script( 'popup-maker-site' ); | |
$cached = get_option( 'pum-has-cached-js' ); | |
if ( ! $cached ) { | |
PUM_AssetCache::cache_js(); | |
$cached = get_option( 'pum-has-cached-js' ); |
View beaver-themer-edd-aap-condition-callbacks.php
This file contains 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 | |
function custom_edd_all_access_check_current_download( $download_id = 0 ) { | |
static $cache = []; | |
if ( ! isset( $cache[ $download_id ] ) ) { | |
$cache[ $download_id ] = edd_all_access_check( [ | |
'download_id' => $download_id, | |
'price_id' => 0, |
View custom-click-block-method.php
This file contains 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 | |
add_filter( 'pum_registered_triggers', 'register_cutstom_click_block', 11 ); | |
function register_cutstom_click_block( $triggers = array() ) { | |
$triggers['click_block']['fields']['general']['requirements']['options']['form_submission'] = __( 'Form Submission' ); | |
return $triggers; | |
} | |
function cu_add_custom_popup_js( $js ) { |
View composer.json
This file contains 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
{ | |
"name": "popup-maker/test-plugin", | |
"description": "description", | |
"minimum-stability": "stable", | |
"require": { | |
"pimple/pimple": "^3.3" | |
}, | |
"autoload": { | |
"psr-4": { | |
"DLI\\": "src/" |
View Toggle Trigger Highlighting
This file contains 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
javascript:(function($){ $('style#pum-highlighted').remove(); $('body').append($('<style>').attr('id', 'pum-highlighted').text('.pum-highlighted { background-color: rgba(255, 255, 0, .75)!important; }')); function highlight() { if ($('.pum-highlight').hasClass('pum-highlighted')) { $('.pum-highlight').removeClass('pum-highlighted'); } else { $('.pum-highlight').addClass('pum-highlighted'); } } $('.pum-trigger').toggleClass('pum-highlight'); if (window.pum_bookmark_button_highlighter === undefined) { window.pum_bookmark_button_highlighter = setInterval(function(){highlight()}, 500); } }(jQuery)); |
View phpcs.xml
This file contains 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
<?xml version="1.0"?> | |
<ruleset name="Code Atlantic - Coding-Standards - Short Arrays"> | |
<description>Code Atlantic Coding-Standards, keeping short array syntax.</description> | |
<!-- Include main ruleset.xml --> | |
<rule ref="./ruleset.xml"/> | |
<!-- Use short arrays --> | |
<rule ref="Generic.Arrays"> | |
<exclude name="Generic.Arrays.DisallowShortArraySyntax.Found" /> |
NewerOlder