CODE BELOW IS CASUING THE ISSUE BECAUSE I ONLY SUPPORT GRAVITY FORM IN PRO VERSIOn..However feel free to modify it to make it work in simple ecomm.
public function gravityFormToCart($entry) {
if(SIMPLEECOMMCART_PRO) {
$formId = SimpleEcommCartGravityReader::getGravityFormIdForEntry($entry[‘id’]);
if($formId) {
$productId = SimpleEcommCartProduct::getProductIdByGravityFormId($formId);
if($productId > 0) {
$product = new SimpleEcommCartProduct($productId);
$qty = $product->gravityCheckForEntryQuantity($entry);
$options = $product->gravityGetVariationPrices($entry);
SimpleEcommCartSession::get(‘SimpleEcommCartCart’)->addItem($productId, $qty, $options, $entry[‘id’]);
$cartPage = get_page_by_path(‘store/cart’);
$cartPageLink = get_permalink($cartPage->ID);
SimpleEcommCartSession::set(‘SimpleEcommCartLastPage’, $_SERVER[‘HTTP_REFERER’]);
wp_redirect($cartPageLink);
exit;
}
}
}
}
Thank you so much for getting back to me. I see the code in SimpleEcommCartShortcodeManager.php but my coding knowledge is limited. I wasn’t attempting to run the Gravity Forms THROUGH the Simple E-Comm cart plugin. I thought they would function separately. Gravity Forms is set up to handle contact forms only.
As I said, I will purchase the pro version of the plugin for a paid project in the VERY near future but in the meantime can you please tell me how to adjust the code? Also where can I find pricing info for purchasing the pro version? I’ve done a search with no luck. MUCH APPRECIATED.
The above is NOT resolved, btw… I would REALLY appreciate help with this plugin conflict.
I resolved this on my own by deactivating Gravity Forms and installing a different contact form plugin (“Fast Secure Contact…”). There were no conflicts between your cart and this particular plugin. I also found info (on my own) in your “Orders” section of the dashboard (Simple Ecomm Cart plugin) as far as purchasing the Pro version of the cart. You might consider making this a little easier to find… I actually stumbled upon it after running some test transactions. (Renamed WpShopcart or http://smartwpplugin.com). We’re not ALL trying to rip you off or take advantage. We’re all in this together. I still like the plugin and hope to work with it again in the near future.
I will keep this in my mind for future.
Thanks
Niaz
I am having the same problem with my gravity forms. Can you tell me where to put the above code that you said would work:
public function gravityFormToCart($entry) {
if(SIMPLEECOMMCART_PRO) {
$formId = SimpleEcommCartGravityReader::getGravityFormIdForEntry($entry[‘id’]);
if($formId) {
$productId = SimpleEcommCartProduct::getProductIdByGravityFormId($formId);
if($productId > 0) {
$product = new SimpleEcommCartProduct($productId);
$qty = $product->gravityCheckForEntryQuantity($entry);
$options = $product->gravityGetVariationPrices($entry);
SimpleEcommCartSession::get(‘SimpleEcommCartCart’)->addItem($productId, $qty, $options, $entry[‘id’]);
$cartPage = get_page_by_path(‘store/cart’);
$cartPageLink = get_permalink($cartPage->ID);
SimpleEcommCartSession::set(‘SimpleEcommCartLastPage’, $_SERVER[‘HTTP_REFERER’]);
wp_redirect($cartPageLink);
exit;
}
}
}
}
Thank you,
DHailey
Hi,
This gravity form will only work with PRO version.
Thanks
Niaz