Skip to content

Instantly share code, notes, and snippets.

View marcos-alexandre82's full-sized avatar

Marcos Alexandre marcos-alexandre82

View GitHub Profile
@marcos-alexandre82
marcos-alexandre82 / kill-adobe-daemons.sh
Created May 10, 2021 23:55 — forked from jivanpal/kill-adobe-daemons.sh
Stop Adobe Creative Cloud daemons (background processes) in their tracks
#!/bin/bash
if [ "$1" = "-s" ] || [ "$1" = "--show" ]; then
show=true
else
show=false
fi
if $show || [ "$1" = "-v" ] || [ "$1" = "--verbose" ]; then
verbose=true
/**
* Register term fields
*/
add_action( 'init', 'register_vendor_custom_fields' );
function register_vendor_custom_fields() {
add_action( WC_PRODUCT_VENDORS_TAXONOMY . '_add_form_fields', 'add_vendor_custom_fields' );
add_action( WC_PRODUCT_VENDORS_TAXONOMY . '_edit_form_fields', 'edit_vendor_custom_fields', 10 );
add_action( 'edited_' . WC_PRODUCT_VENDORS_TAXONOMY, 'save_vendor_custom_fields' );
add_action( 'created_' . WC_PRODUCT_VENDORS_TAXONOMY, 'save_vendor_custom_fields' );
}
@marcos-alexandre82
marcos-alexandre82 / example.php
Created July 29, 2020 21:44 — forked from hounw/example.php
card.js in woocommerce payment gateway
<?php
/*
... omitted all other functions...
*/
/**
* Add custom credit card form
*/
public function payment_fields() {