E-Junkie Forum http://www.e-junkie.com/bb/ E-Junkie Forum RSS en-us Copyright 2013, 19.5 Degrees. All rights reserved. webmaster@e-junkie.com webmaster@e-junkie.com Mon, 7 May 2012 05:40:35 GMT Wed, 22 May 2013 18:42:43 GMT 681 E-JUNKIE 5 E-Junkie Forum http://www.e-junkie.com/bb/ http://www.e-junkie.com/ej/logo.gif 290 104 Post #3 http://www.e-junkie.com/bb/topic/5910/pg/0#post20944 http://www.e-junkie.com/bb/topic/5910/pg/0#post20944 Mon, 7 May 2012 05:40:35 GMT
It was the need to pass both the name and value that i had not realised - i've got it working now.

The key bit i could not find was this example:

on0=Size&os0=Large]]>
E-junkie Discussions; BabbleBib
Post #2 http://www.e-junkie.com/bb/topic/5910/pg/0#post20944 http://www.e-junkie.com/bb/topic/5910/pg/0#post20944 Mon, 7 May 2012 00:57:11 GMT http://www.e-junkie.com/ej/help.custom.purchase-buttons.htm#product

This help page explains Variations and Variants configuration:
http://www.e-junkie.com/ej/help.variants.htm

Our system can handle GET and POST variables interchangeably, so anything passed via a form field/menu can also be passed via URL parameter with the same variable name, and vice-versa -- e.g., this is our typical Cart button code for an item using Variations:

<form action="https://www.e-junkie.com/ecom/gb.php?c=cart&i=XXXXXX&cl=YYYYYY&ejc=2" target="ej_ejc" method="POST" accept-charset="UTF-8">
<input type="hidden" name="on0" value="Size"/>
Size:<br/>
<select name="os0">
<option value="Small">Small</option>
<option value="Large">Large</option>
</select>
<br/>
<input type="image" src="http://www.e-junkie.com/ej/ej_add_to_cart.gif" border="0" alt="Add to Cart" class="ec_ejc_thkbx" onClick="javascript:return EJEJC_lc(this.parentNode);"/>
</form>

...but you could also pass a predetermined Size parameter using Variations via this URL:

https://www.e-junkie.com/ecom/gb.php?c=cart&i=XXXXXX&cl=YYYYYY&ejc=2&on0=Size&os0=Large

Note that Variations parameters must be passed in pairs (on0/os0, on1/os1, on2/os2) but the values passed for those names can otherwise be completely arbitrary -- i.e., they don't need to match names/values specified in the product's Define Variations screen, and indeed you don't even need to enable "Variations which tell more..." in the product's settings (that setting and Define Variations are only used to auto-generate button code with the desired menus/fields).

However, if you're using Variants (as distinct from Variations), that must be enabled and configured in the product settings, and any Variants values (o1, o2, o3) passed via form menu or URL parameter must exactly match values you have configured in the product's Define Variants screen.]]>
E-junkie Discussions; E-junkieGuru
Post #1 http://www.e-junkie.com/bb/topic/5910/pg/0#post20944 http://www.e-junkie.com/bb/topic/5910/pg/0#post20944 Sun, 6 May 2012 09:09:07 GMT
What is the format for passing variations?

I am using this format for variants which works well:
https://www.e-junkie.com/ecom/gb.php?c=cart&i=1094184&cl=148641&ejc=2&o1=BABYBLUE-BT-BB&quantity=1

However I'm not sure how to pass variations through in the URL. My variations are 'text', 'colour' and 'font'.

many thanks]]>
E-junkie Discussions; BabbleBib