Skip to content

Instantly share code, notes, and snippets.

try {
$subscription = new Recurly_Subscription();
$subscription->plan_code = 'fffvip';
$subscription->currency = 'USD';
$subscription->quantity = 1;
$accountcode = 'nplocalsgtf0301_14@yopmail.com';
$account = Recurly_Account::get($accountcode);
$billing_info = new Recurly_BillingInfo();
$account = new Recurly_Account();
$account->account_code = 'nishabadaddress@yopmail.com';
$account->email = 'nishabadaddress@yopmail.com';
$account->first_name = 'nisha';
$account->last_name = 'pan';
$address = array();
$address['address1'] = '123 main st';
$address['address2'] = '';
$address['city'] = 'los angeles';
// create address
$address = array();
$address['address1'] = '123 main st';
$address['address2'] = '';
$address['city'] = 'Los Angeles';
$address['state'] = 'CO';
$address['zip'] = '91202';
$address['country'] = 'US';
$address['phone'] = '(310)-123-1222';
<?php
use Phinx\Migration\AbstractMigration;
class InsertFriendbuyToReferralShare extends AbstractMigration
{
public function change()
{
// we only care about rows that are not duplicate
$friendbuyRows = $this->fetchAll("SELECT * FROM friendbuy_shares");
$referralTable = $this->table('referral_shares');
foreach ($friendbuyRows as $friendbuyRow) {
<?php
use Phinx\Migration\AbstractMigration;
class InsertFriendbuyToReferralConversion extends AbstractMigration
{
public function change()
{
// we only care about rows that are not duplicate
$friendbuyRows = $this->fetchAll("SELECT * FROM friendbuy_conversions WHERE is_duplicated = 0
AND new_order_id IS NOT NULL
");
$purchase = new Recurly_Purchase();
$purchase->currency = 'USD';
$purchase->account = new Recurly_Account();
$purchase->account->account_code = 'user1@hotmail.com';
$purchase->account->first_name = 'jane';
$purchase->account->last_name = 'doe';
$billing_info = new Recurly_BillingInfo();
$billing_info->number = '4111-1111-1111-1111';
$billing_info->country = 'US';
SELECT * FROM `users`
WHERE ship_zipcode = 91202
AND levenshtein('123 main st', `ship_address1`) BETWEEN 8 AND 10
AND levenshtein('suite 5', `ship_address2`) BETWEEN 8 AND 10
limit 5
DELIMITER $$
CREATE FUNCTION levenshtein( s1 VARCHAR(255), s2 VARCHAR(255) )
RETURNS INT
DETERMINISTIC
<head>
<meta name="viewport" content="initial-scale=1, maximum-scale=1">
<style>
#main-container{width:100%;overflow-x:hidden;}
#section1{width:100%;height:fit-content;background-color:#FEDAC9;text-align:center;margin:auto;}
#section2 {width:100%;height:fit-content;background-color: #FFF;display:flex; padding:30px 40px;}
#section3 {width:100%; background-color: #FEDAC9;margin:auto;text-align:center;padding-bottom:45px;}
#section4 {width:100%;background-color: #fff;display:flex;}
#section1 #edit-banner-img {width:550px;margin:-40px;}
#section1 #edit-banner-title{color: #000000;font-family: Montserrat;font-size: 22px;
<div class="col">
<div class="addon-description-reactivate" style="font-size: 16px;">
<div style="border: 1px solid #e5e5e5; background: #f5f5f5;">
<h2 style="text-align: center; margin-top: 40px;">You need a seasonal box to shop Add-Ons!</h2>
<div class="description" style="text-align: center; margin-bottom: 50px;">
<p>To participate in Add-Ons, you must have an upcoming Summer Box! <br/> Add-Ons will ship for free with your Summer Box after May 15th, 11:59 PM PST . Don't want to miss out on amazing discounts? Click below to purchase. </p>
<p> By purchasing the Summer Box, you will be charged $49.99* with the billing information we have on file. Your credit card will be charged that same amount each season. You may cancel your membership at any time online or by contacting FabFitFun Support. For more details, <a href="https://support.fabfitfun.com/hc/en-us/articles/201619963-What-s-your-cancellation-policy-">click here.</a></p>
<p>
<div class="col">
<div class="addon-description-reactivate" style="font-size: 16px;">
<div style="border: 1px solid #e5e5e5; background: #f5f5f5;">
<h2 style="text-align: center; margin-top: 40px;">You need a seasonal box to shop Add-Ons!</h2>
<div class="description" style="text-align: center; margin-bottom: 50px;">
<p>To participate in Add-Ons, you must have an upcoming Summer Box!<br/>Don't want to miss out on amazing discounts? Click below to activate your account</p>
<p>
<button class="btn-lg btn btn-cta popmake-early-activate btn-trial-activate-seasonal">Get the Summer Box Now! Hi Steve</button>
<p style="color: #999;">By clicking above, your subscription will be set to renew for Summer.</p>
</div>