[ic] setting item price by radio selection

interchange-users@icdevgroup.org interchange-users@icdevgroup.org
Tue Aug 13 22:48:00 2002


On Tue, Aug 13, 2002 at 10:24:38PM -0400, Jim Toro wrote:
> 
> I have a customer with a big database which has several fields like
> pricedesc1, price1, pricedesc2, price2, pricedesc3, price3  which are
> descriptions of the SKU depending on the size you select. So for sku
> 001 there are three possible variants (3 pricedescs and 3 prices).
> There is no true "price" field, rather 3 price fields for each item.
> 
> What I want to do is to get the price of the item from either of the three
> once they select it with a radio button.
> 
> I got all the html/IC stuff done so it displays the fields, sets up the
> radio buttons and shows the descs and prices but once they click a radio
> button and hit the BUY button I cant figure out how to set the items price
> from the value stored by the radio click.
> 
> Here is the snippet of the radio selections of the items possible
> size/type choices:
> 
> [if-item-field pricetext1]
> <tr>
> <td>
> &nbsp;&nbsp;&nbsp;
> </td>
> <td noWrap><font face="arial, helvetica" color="#7b3e3e"
> size="2">[item-field pricetext1]</td>
> <td>
> <input type="radio" CHECKED value="[item-field price1]"
> name="selectprice">[item-field price1]
> </td>
> </tr>
> [/if-item-field]
> 
> [if-item-field pricetext2]
> <tr>
> <td>
> &nbsp;&nbsp;&nbsp;
> </td>
> <td noWrap><font face="arial, helvetica" color="#7b3e3e"
> size="2">[item-field pricetext2] </td>
> <td>
> <input type="radio" value="[item-field price2]"
> name="selectprice">[item-field price2]
> </td>
> </tr>
> [/if-item-field]
> 
> [if-item-field pricetext3]
> <tr>
> <td>
> &nbsp;&nbsp;&nbsp;
> </td>
> <td noWrap><font face="arial, helvetica" color="#7b3e3e"
> size="2">[item-field pricetext3]
> </td>
> <td>
> <input type="radio" value="[item-field price3]"
> name="selectprice">[item-field price3]</font></td>
> </tr>
> [/if-item-field]
> 
> The buy stuff is on the screen and when they click it does take them
> to the cart page with everything set but the price.
> 
> How do I get the "selectprice" to end up as the item price in the shopping
> cart?.
> 
> I fiddled with commonadjust but I dont think it works with this sort of
> price manipulation.
> 
> Any ideas?.

Some day I'm going to post code so that someone can run a catalog
with infinite items but just one single SKU.  Just lump it all
into one big attribute you can throw on the printer and let the
stock pickers figure it out.  :-)

The easy way, use three skus.  That's what they are for.

Ask the same question again and I'll have a different idea.



> 
> 
> 
> _______________________________________________
> interchange-users mailing list
> interchange-users@icdevgroup.org
> http://www.icdevgroup.org/mailman/listinfo/interchange-users
> 

-- 

Christopher F. Miller, Publisher                               cfm@maine.com
MaineStreet Communications, Inc           208 Portland Road, Gray, ME  04039
1.207.657.5078                                         http://www.maine.com/
Content/site management, online commerce, internet integration, Debian linux