Skip to content

Instantly share code, notes, and snippets.

Last active Sep 13, 2017
What would you like to do?
// Set cookie of free user
add_action( 'wp', 'track_upsell' );
function track_upsell() {
if(!isset($_COOKIE['seedprod_source'])) {
setcookie( 'seedprod_source', 'free_plugin|'.time(), strtotime("+1 year"),"/","" );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment