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 | |
$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'), |
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
// 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 |
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
## 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: | |
* http://codex.wordpress.org/Class_Reference/wpdb#Protect_Queries_Against_SQL_Injection_Attacks | |
* http://codex.wordpress.org/Data_Validation#Database | |
* http://make.wordpress.org/core/2012/12/12/php-warning-missing-argument-2-for-wpdb-prepare/ | |
* http://ottopress.com/2013/better-know-a-vulnerability-sql-injection/ |
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
<style> | |
#wpnbio-close,#wpnbio-show{ | |
cursor: pointer; | |
} | |
#wpnbio-alert ul { | |
list-style: none; | |
} |
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 bash | |
set -e | |
if [ ! -d src/amazon-s3-and-cloudfront ]; then | |
echo 'This script must be run from the repository root.' | |
exit 1 | |
fi | |
for PROG in composer find sed |
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
<script type="type/javascript"> | |
var language = navigator.language || navigator.browserLanguage; | |
// alert(language); | |
if (language.indexOf('en') > -1) { | |
document.location.href = 'http://en.socialpos.com.ar'; | |
} else { | |
document.location.href = 'http://socialpos.com.ar'; |
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
/** | |
* API Updates | |
*/ | |
if( !class_exists( 'SeedProd_Updater_cspv5' ) ) { | |
// load our custom updater | |
include( dirname( __FILE__ ) . '/seedprod-updater-cspv5.php' ); | |
} | |
function seed_cspv5_plugin_updater() { |
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
// Multisite Initial Install License Check | |
function seed_cspv5_check_license_updater(){ | |
if(get_option('seed_cspv5_a') === false){ | |
add_option('seed_cspv5_license_key',SEED_CSP_API_KEY); | |
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, |
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 | |
// Record Source | |
try { | |
$seedprod_source = $_COOKIE['seedprod_source']; | |
$source = ''; | |
if(!empty($seedprod_source)){ | |
$source = explode("|",$seedprod_source)[0]; | |
$dt = date("Y-m-d H:i:s",explode("|",$seedprod_source)[1]); | |
$order = Order::find($data['order']->id); |
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 | |
// Set cookie of free user | |
add_action( 'wp', 'track_upsell' ); | |
function track_upsell() { | |
if(is_page('ultimate-coming-soon-page-vs-coming-soon-pro')){ | |
if(!isset($_COOKIE['seedprod_source'])) { | |
setcookie( 'seedprod_source', 'free_plugin|'.time(), strtotime("+1 year"),"/","seedprod.com" ); | |
} |