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 | |
/* | |
Plugin Name: Monochrome Pro - remove hero and avatar | |
Plugin URI: https://www.facebook.com/groups/genesiswp/posts/8077692698948523/ | |
Description: Remove the hero image and avatar from single posts in Monochrome Pro theme. | |
Author: Damien Carbery | |
Version: 0.1 | |
*/ | |
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 | |
/* | |
Plugin Name: Change Flatsome theme 'Out of Stock' label to 'Sold' | |
Plugin URI: https://www.damiencarbery.com/2020/06/change-flatsome-theme-out-of-stock-label-to-sold/ | |
Description: Change the 'Out of stock' banner in Flatsome theme to 'Sold'. Also works when [ux_products] shortcode is used. | |
Author: Damien Carbery | |
Author URI: https://www.damiencarbery.com | |
Version: 0.3 | |
*/ |
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 | |
/** | |
* Single Product tabs | |
* | |
* This template can be overridden by copying it to yourtheme/woocommerce/single-product/tabs/tabs.php. | |
* | |
* HOWEVER, on occasion WooCommerce will need to update template files and you | |
* (the theme developer) will need to copy the new files to your theme to | |
* maintain compatibility. We try to do this as little as possible, but it does | |
* happen. When this occurs the version of the template file will be bumped and |
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 | |
/* | |
Plugin Name: Add Tracking Provider | |
Plugin URI: https://www.damiencarbery.com/ | |
Description: Add new An Post (Irish postal service) as a tracking provider. | |
Author: Damien Carbery | |
Author URI: https://www.damiencarbery.com | |
Version: 0.1.20240414 | |
*/ |
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 | |
/* | |
Plugin Name: WooCommerce - Export order details as CSV | |
Plugin URI: https://www.damiencarbery.com/ | |
Description: Allow exporting the details . | |
Author: Damien Carbery | |
Author URI: https://www.damiencarbery.com | |
Version: 0.1 | |
*/ |
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 | |
$request_url = 'http://localhost/wp-json/list_product_stock/v1/list-product-stock/'; | |
$credentials = array(); | |
$credentials = array( 'username: basic_user', 'password: password_for_the_user' ); | |
$curl_handle = curl_init( ); | |
curl_setopt( $curl_handle, CURLOPT_URL, $request_url ); | |
curl_setopt( $curl_handle, CURLOPT_CONNECTTIMEOUT, 0 ); | |
curl_setopt( $curl_handle, CURLOPT_TIMEOUT, 15 ); |
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 | |
// Restrict who can access this script. | |
/*$permitted_ips = array( '12.34.56.78' ); | |
if ( false == in_array($_SERVER['REMOTE_ADDR'], $permitted_ips) ) { | |
header( 'HTTP/1.0 403 Forbidden' ); | |
die(); | |
}*/ | |
header('HTTP/1.1 200 OK'); |
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
package autosslftp; | |
use strict; | |
use warnings; | |
use Net::FTP; | |
use constant CONFIG_FIELDS => 10; # Number of fields in config file. | |
use Exporter qw(import); | |
# $Id: autosslftp.pm 5151 2020-07-01 19:50:11Z damien $ | |
our @EXPORT = qw(get_config); |
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 | |
/* | |
Plugin Name: View WooCommerce order on front end | |
Plugin URI: https://www.damiencarbery.com/2024/01/view-woocommerce-order-on-front-end/ | |
Description: Use an encrypted link to allow a customer view order details on the front end. | |
Author: Damien Carbery | |
Author URI: https://www.damiencarbery.com | |
Version: 0.2 | |
WC tested to: 8.5.1 | |
*/ |
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
// This code enables Select2 to dropdowns as they are rendered. | |
// Create a new object for custom validation of a custom field. | |
var dcwdDropdownFieldController = Marionette.Object.extend( { | |
initialize: function() { | |
// From: https://developer.ninjaforms.com/codex/field-view-rendering/ | |
this.listenTo( nfRadio.channel( 'listselect' ), 'render:view', this.renderView ); | |
}, | |
renderView: function( view ) { |
NewerOlder