Skip to content

Instantly share code, notes, and snippets.

John Turner seedprod

Block or report user

Report or block seedprod

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:fbaeaa2d3b5728f9871f57863b108a77
document.addEventListener('om.Campaign.afterShow', function(event) {
// exit offer
if(event.detail.Campaign.numericId == '212237'){
var offer_ajax_url = '/checkout/exit_offer';
console.log( _self.$data);
).then(function (response) {
View RafflePress frontend string
$rp_frontend_translations = array(
'txt_1'=>__('Total Entries', 'rafflepress-pro'),
'txt_2'=>__('Your Entries', 'rafflepress-pro'),
'txt_3'=>__('Log In to Enter this Giveaway:', 'rafflepress-pro'),
'txt_4'=>__('Enter', 'rafflepress-pro'),
'txt_5'=>__('Logout', 'rafflepress-pro'),
'txt_6'=>__('Hi', 'rafflepress-pro'),
'txt_7'=>__('Ways to Enter', 'rafflepress-pro'),
View gist:1b8be963b47d7f8aad72a248c474ee51
// assign entering entries if enabled
$entries_tablename = $wpdb->prefix . 'rafflepress_entries';
$insert_arrays[] = array(
'giveaway_id' =>$giveaway_id,
'contestant_id' => $contestant['id'],
'meta' => '{"action":"Entering Giveaway"}',
rafflepress_pro_wp_insert_rows($insert_arrays, $entries_tablename);
$contestant['total_entries'] = 1;
//end assign entering entries if enabled
View gist:5b366557c651f1d408457c819c2f5930
## Unsafe SQL calls
When making database calls, it's highly important to protect your code from SQL injection vulnerabilities. You need to update your code to use prepare() with your queries to protect them.
Please review the following:
View gist:3c933f89f908d4106927c510552163b5
cursor: pointer;
#wpnbio-alert ul {
list-style: none;
seedprod /
Created Mar 25, 2018 — forked from ianmjones/
A script for downloading the AWS PHP SDK v2, stripping down to S3 functionality and then applying a custom namespace.
#!/usr/bin/env bash
set -e
if [ ! -d src/amazon-s3-and-cloudfront ]; then
echo 'This script must be run from the repository root.'
exit 1
for PROG in composer find sed
View .js
<script type="type/javascript">
var language = navigator.language || navigator.browserLanguage;
// alert(language);
if (language.indexOf('en') > -1) {
document.location.href = '';
} else {
document.location.href = '';
View gist:22dc5be5ac96a7cca554026bb8fe7095
* API Updates
if( !class_exists( 'SeedProd_Updater_cspv5' ) ) {
// load our custom updater
include( dirname( __FILE__ ) . '/seedprod-updater-cspv5.php' );
function seed_cspv5_plugin_updater() {
View gist:e1f5fda3dcb141682c9e8e25a5be2a74
// Multisite Initial Install License Check
function seed_cspv5_check_license_updater(){
if(get_option('seed_cspv5_a') === false){
add_option('seed_cspv5_token',strtolower(wp_generate_password(32,false, false)));
$params = array(
'action' => 'info',
'license_key'=> SEED_CSP_API_KEY,
'slug' => SEED_CSPV5_SLUG,
View record_upsell.php
// Record Source
try {
$seedprod_source = $_COOKIE['seedprod_source'];
$source = '';
$source = explode("|",$seedprod_source)[0];
$dt = date("Y-m-d H:i:s",explode("|",$seedprod_source)[1]);
$order = Order::find($data['order']->id);
You can’t perform that action at this time.