[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date
][Minivend by thread
]
[mv] combine values to generate product sku and place in basket
****** message to minivend-users from Scott Benson <scott@rant.tzo.com> ******
I have been pounding my head for over a week trying to figure this
out...
The catalog (using Minivend 4.04a) is being built for clothing, which
even though minivend supports item-modifiers (color, size) they didn't
suit my needs . I changed the database tables layout and wrote some
pages to display the products - everthing is working ok for that.
The product sku is comprised of the style, color and size (each with
individual columns in the products database)
example: sku is 1020314. the style is 102, the color is 03, and the size
is 14. The descriptions for them are in arbitrary databases.
The problem I am having is trying to get the sku passed in to the basket
from a product's page (like flypage.html) so that it will append the
values of style (that is known on that page) with the color and size
values - which are selected from drop down boxes.
the code i have for the order button is:
<FORM NAME=orderform ACTION="[process-target]" METHOD=POST>
<INPUT TYPE=submit VALUE="Order">
<INPUT TYPE=hidden NAME=mv_todo VALUE=refresh>
<INPUT TYPE=hidden NAME=style VALUE="[scratch style]">
<INPUT TYPE=hidden NAME=mv_separate_items VALUE="1">
[query sql="select distinct size from products where style = [scratch
style] order by size" list=1]
[if type=scratch term=size op="==" compare="[sql-param size]"]
<OPTION name=size value=[sql-param size] SELECTED>[sql-param size]
[else]
<OPTION name=size value=[sql-param size]>[sql-param size]
[/else][/if]
[/query]
</select>
<select name="color">
[loop search="se=[scratch style]/sf=style/"]
[loop-change 1][condition][loop-field color][/condition]
<OPTION name=color value=[loop-field color]>[data table=colors col=name
key="[loop-field color]"]
[/loop-change 1]
[/loop]
</select>
</FORM>
so now what is the best way to get "[value style][value color][value
size]" as the product's sku pushed into the cart (basket.html)?
or is this just all crap and I should start over?
Thanks
Scott
-
To unsubscribe from the list, DO NOT REPLY to this message. Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list