Forum Replies Created
-
AuthorPosts
-
November 1, 2012 at 12:56 pm in reply to: eStore/NextGen – Limiting downloads to specific variations and securing links #50752HephaestusMember
In case anyone is wondering how to do this in the future, here are my modifications to paypal.php. Remember to mark your changes with comments so they are easy to find and reapply when upgrading eStore in the future
After
var $sandbox_mode = false;
on line 26 add://Hephaestus - 01/11/2012
var $download_variation; // only provide a download link for products with this variation
Find this code block around line 400:
//Generate link from Nextgen gallery if PID is present.
if(!empty($pictureID))
{
$download_link = eStore_get_ngg_image_url($pictureID,$cart_item_data_name);
$pictureID = "";
}
else
{
$download_link = generate_download_link($retrieved_product,$cart_item_data_name,$this->ipn_data);
}
$this->debug_log('Download Link : '.$download_link,true);
Replace this with:
//rbearman - 01/11/2012 - START
//Don't provide a download link if the variation is not as specified in $download_variation
if(strpos($cart_item_data_name, '('.$this->download_variation.')') !== false)
{
//Generate link from Nextgen gallery if PID is present.
if(!empty($pictureID))
{
$download_link = eStore_get_ngg_image_url($pictureID,$cart_item_data_name);
$pictureID = "";
}
else
{
$download_link = generate_download_link($retrieved_product,$cart_item_data_name,$this->ipn_data);
}
}
else
{
$download_link = "";
}
$this->debug_log('Download Link : '.$download_link,true);
//rbearman - 01/11/2012 - END
November 1, 2012 at 12:18 pm in reply to: eStore/NextGen – Limiting downloads to specific variations and securing links #50751HephaestusMemberSorry, my mistake, I didn’t realise the sandbox mode was on the General Settings rather than Payment Gateways.
November 1, 2012 at 11:01 am in reply to: eStore/NextGen – Limiting downloads to specific variations and securing links #50750HephaestusMemberUnfortunately you can’t pay yourself with PayPal and eStore doesn’t seem to support the PayPal Developer Sandbox for testing. Can I not just modify paypal.php to skip over the actual payment process and jump to the order email?
October 31, 2012 at 10:20 am in reply to: eStore/NextGen – Limiting downloads to specific variations and securing links #50748HephaestusMemberThanks for the help. Is the best way to quickly test this just to use the manual payment method?
October 29, 2012 at 9:28 am in reply to: eStore/NextGen – Limiting downloads to specific variations and securing links #50746HephaestusMemberHow would I access the selected variation at this point?
October 28, 2012 at 11:33 am in reply to: eStore/NextGen – Limiting downloads to specific variations and securing links #50744HephaestusMemberWe’re currently using PayPal, thanks.
October 27, 2012 at 12:54 pm in reply to: eStore/NextGen – Limiting downloads to specific variations and securing links #50742HephaestusMemberWould it not be possible for me to add a check on which variation has been selected when the confirmation email is sent out, and strip the URL and download information there? If it is, could you point me in the right direction for which files to look at?
-
AuthorPosts