I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.
These are the steps I went through to set up an SSL cert.
//Add to funtctions.php file | |
//Adding Sales reps to the check out | |
add_action('woocommerce_after_order_notes', 'jmg_custom_checkout_field'); | |
function jmg_custom_checkout_field( $checkout ) { | |
echo '<div id="my_custom_checkout_field"><h2>'.__('Who Is Your EdiPure Sales Rep?').'</h2>'; | |
woocommerce_form_field( 'edipure_reps', array( | |
'type' => 'select', |
<?php | |
/** | |
* WordPress Plugin Isolation helper | |
* This helps your plugin/theme to have isolated webpages, keeping only your organized prefixed hooks. | |
* @package Hashtagg | |
* @subpackage Base | |
* @author Klipolis | |
* @copyright 2014 Klipolis | |
* @since 0.1.0 | |
* @version 0.1.0 |
# installs to /opt/gradle | |
# existing versions are not overwritten/deleted | |
# seamless upgrades/downgrades | |
# $GRADLE_HOME points to latest *installed* (not released) | |
gradle_version=2.9 | |
wget -N https://services.gradle.org/distributions/gradle-${gradle_version}-all.zip | |
sudo unzip -foq gradle-${gradle_version}-all.zip -d /opt/gradle | |
sudo ln -sfn gradle-${gradle_version} /opt/gradle/latest | |
sudo printf "export GRADLE_HOME=/opt/gradle/latest\nexport PATH=\$PATH:\$GRADLE_HOME/bin" > /etc/profile.d/gradle.sh | |
. /etc/profile.d/gradle.sh |
/** | |
for( $a=1; $a<20; $a++ ) { | |
echo '----------------------' . PHP_EOL; | |
echo 'PROJECT_ID :: ' . $a . PHP_EOL; | |
$last = $c[ 'predis' ]->get( 'round-robin-dispatch' ); | |
$i = $j = -1; | |
$n = count( $array ); |
#!/bin/bash | |
# uses imagemagick to stich together all images in a folder. | |
# ex command: ./spriter.sh rivendell-title jpg 640 400 | |
if [ $# -gt 3 ] | |
then | |
folder=$1; | |
name=$1; # output will be placed in a folder named this |
I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.
These are the steps I went through to set up an SSL cert.
/* | |
Only let level 1 members sign up if they use a discount code. | |
Place this code in your active theme's functions.php or a custom plugin. | |
*/ | |
function my_pmpro_registration_checks_require_code_to_register($pmpro_continue_registration) | |
{ | |
//only bother if things are okay so far | |
if(!$pmpro_continue_registration) | |
return $pmpro_continue_registration; |
/* | |
* goes in theme functions.php or a custom plugin. Replace the image filename/path with your own :) | |
* | |
**/ | |
add_action( 'init', 'custom_fix_thumbnail' ); | |
function custom_fix_thumbnail() { | |
add_filter('woocommerce_placeholder_img_src', 'custom_woocommerce_placeholder_img_src'); | |
function custom_woocommerce_placeholder_img_src( $src ) { |
<?php | |
/* | |
Plugin Name: R Debug | |
Description: Set of dump helpers for debug. | |
Author: Andrey "Rarst" Savchenko | |
Author URI: https://www.rarst.net/ | |
License: MIT | |
*/ |
<?php /* This function attaches the image to the post in the database, add it to functions.php */ | |
function insert_attachment($file_handler,$post_id,$setthumb='false') { | |
// check to make sure its a successful upload | |
if ($_FILES[$file_handler]['error'] !== UPLOAD_ERR_OK) __return_false(); | |
require_once(ABSPATH . "wp-admin" . '/includes/image.php'); | |
require_once(ABSPATH . "wp-admin" . '/includes/file.php'); | |
require_once(ABSPATH . "wp-admin" . '/includes/media.php'); |