Forums / Setting Up Categories, Products, Attributes / php to Zen string and data transfer to add new unique products to cart after customiz

php to Zen string and data transfer to add new unique products to cart after customiz

Locked

Started by bolte on 12 May 2007, 12:38 PM · Views: 2,352

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
12 May 2007, 12:38 PM
#1
bolte avatar

bolte

New Zenner

Join Date:
May 2007
Posts:
3
Plugin Contributions:
0

php to Zen string and data transfer to add new unique products to cart after customiz

Hey All,

Does Zen have support for php POST importing? ie: a new product is generated as the result of a web-form, ie lettering or an infinitely customizable object, is resolved into three for four parameters - cost/data computed in the php script. The whole result is then passed into Zen for customer reg. and checkout.

Seeing as Zen is database driven this would require an on-the-fly generation of products and dynamic updates?

Cheers

13 May 2007, 5:54 PM
#2
wilt avatar

wilt

Oji-san

Join Date:
Jun 2003
Location:
Newcastle UK
Posts:
1,940
Plugin Contributions:
3

Re: php to Zen string and data transfer to add new unique products to cart after customiz

Zen Cart supports attributes and attribute types that allow customers to supply text based data.

Is that what you require.

14 May 2007, 6:44 AM
#3
bolte avatar

bolte

New Zenner

Join Date:
May 2007
Posts:
3
Plugin Contributions:
0

Re: php to Zen string and data transfer to add new unique products to cart after customiz

Sounds like it may be on the right track, for a customer to fill in data in a webform and then that data to be passed into Zen as a new product, or a function of a generic product with a new variation.

One of the hundred examples: Sign writing. Charged per letter. So the user enters the text for the sign in a from text box (the element). php calculates how many letters there are, multiplies by the cost/letter and then passes both the total cost and exact text string into Zen as a new product/variation of a product. The user can then continue to generate signs and add to the shopping cart. When complete, the number of signs can be processed with the exact text and cost on the reciept.

pseudo:

function(form element);
{
echo $Len = letters&numbersIn(element);
}

import math;
$Cost = $Len * factor;

% POST form as hidden

%In Zen
echo $TotalCost = $Post['Cost'];
echo $text_string = $Post['element'];

%Here ZEN would need to generate a product, or modify an existing product to recieve the TotalCost and text_string and put through the payment.

Cheers,

14 May 2007, 7:03 AM
#4
barco57 avatar

barco57

Totally Zenned

Join Date:
Apr 2006
Location:
West Salem, IL
Posts:
2,846
Plugin Contributions:
0

Re: php to Zen string and data transfer to add new unique products to cart after customiz

That function is already built in ....
in the attributes controller you can price by word or price by letter.....

Mike
AEIIA - Zen Cart Certified & PCI Compliant Hosting
The Zen Cart Forum...Better than a monitor covered with post-it notes!

14 May 2007, 8:02 AM
#5
bolte avatar

bolte

New Zenner

Join Date:
May 2007
Posts:
3
Plugin Contributions:
0

Re: php to Zen string and data transfer to add new unique products to cart after customiz

Thanks guys, when you know what your looking for...

Cheers