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 // only copy if needed | |
/** | |
* Removes coupon form, order notes, and several billing fields if the checkout doesn't require payment. | |
* | |
* Tutorial: http://skyver.ge/c | |
*/ | |
//function sv_free_checkout_fields() { | |
// first, bail if the cart needs payment, we don't want to do anything | |
if ( WC()->cart && WC()->cart->needs_payment() ) { |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import argparse | |
from swissknife.script import common_setup | |
import plotly.graph_objs as go | |
import plotly.io as pio | |
parser = argparse.ArgumentParser( |
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
class conf: | |
def __init__(self, path): | |
self.config = configparser.SafeConfigParser() | |
self.config.read(path) | |
self.path = path | |
def write(self, section, option, value): | |
""" | |
http://www.programcreek.com/python/example/1033/ConfigParser.SafeConfigParser |