Add the PPA
sudo add-apt-repository ppa:ondrej/php
Update repos
sudo apt-get update
| var waitForEl = function(selector, callback) { | |
| if (jQuery(selector).length) { | |
| callback(); | |
| } else { | |
| setTimeout(function() { | |
| waitForEl(selector, callback); | |
| }, 100); | |
| } | |
| }; |
| <?php | |
| //Works with WooCommerce 3.2.6 | |
| add_action( 'woocommerce_shipping_init', 'econt_shipping_method' ); | |
| function econt_shipping_method() { | |
| if ( ! class_exists( 'WC_Econt_Shipping_Method' ) ) { | |
| class WC_Econt_Shipping_Method extends WC_Shipping_Method { | |
| public function __construct( $instance_id = 0 ) { | |
| $this->instance_id = absint( $instance_id ); | |
| $this->id = 'econt';//this is the id of our shipping method |
| <?php | |
| add_filter( 'fg_easypassthrough_populate_same_form', '__return_false' ); |
| /** | |
| * Custom account fields | |
| */ | |
| add_action( 'woocommerce_edit_account_form', 'my_woocommerce_edit_account_form' ); | |
| add_action( 'woocommerce_save_account_details', 'my_woocommerce_save_account_details' ); | |
| function my_woocommerce_edit_account_form() { | |
| $user_id = get_current_user_id(); |
| <?php | |
| /** | |
| * post-process.php | |
| * make sure to include post-process.php in your functions.php. Use this in functions.php: | |
| * | |
| * get_template_part('post-process'); | |
| * | |
| */ | |
| function do_insert() { | |
| if( 'POST' == $_SERVER['REQUEST_METHOD'] |
| <?php | |
| /* | |
| Plugin Name: PMPro Limit Available Plugins and Themes | |
| Plugin URI: http://www.paidmembershipspro.com/wp/pmpro-limit-available-plugins/ | |
| Description: Limits Which Plugins are Available for Network Sites | |
| Version: .1 | |
| Author: Stranger Studios | |
| Author URI: http://www.strangerstudios.com | |
| 1. Place this file in wp-content/mu-plugins. |
| #!/bin/sh | |
| # Written by: Keefer Rourke <https://krourke.org> | |
| # Based on AUR package <https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=ttf-google-fonts-git> | |
| # dependancies: fonts-cantarell, ttf-ubuntu-font-family, git | |
| sudo apt-get install fonts-cantarell, ttf-ubuntu-font-family, git | |
| srcdir="/tmp/google-fonts" | |
| pkgdir="/usr/share/fonts/truetype/google-fonts" | |
| giturl="git://github.com/google/fonts.git" |
Add the PPA
sudo add-apt-repository ppa:ondrej/php
Update repos
sudo apt-get update