E-Junkie Forum http://www.e-junkie.com/bb/ E-Junkie Forum RSS en-us Copyright 2012, 19.5 Degrees. All rights reserved. webmaster@e-junkie.com webmaster@e-junkie.com Thu, 19 Feb 2009 20:55:55 GMT Fri, 10 Feb 2012 17:45:25 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 #7 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 Thu, 19 Feb 2009 20:55:55 GMT
<input type="submit" value="Add to Cart" onClick="javascript:return EJEJC_lc(this.parentNode);">

The version I posted previously would not work if the buyer had disabled JavaScript, but this version will work with and without JS.]]>
E-junkie Discussions; E-junkieGuru
Post #6 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 Wed, 18 Feb 2009 22:05:56 GMT E-junkie Discussions; drumnjazz Post #5 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 Wed, 18 Feb 2009 21:51:17 GMT http://www.e-junkie.com/ej/help.custom.purchase-buttons.htm

You can even replace our fancy Add to Cart button with a regular Submit type of button in the browser's default style -- replace this:
<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);"/>

...with this:
<input type="button" value="Add to Cart" onClick="javascript:return EJEJC_lc(this.parentNode);">]]>
E-junkie Discussions; E-junkieGuru
Post #4 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 Wed, 18 Feb 2009 21:16:21 GMT
Also, thanks for the heads up with the Javascript issue. I suppose the only thing that would work to fix this would be to use the standard button. Is that right?]]>
E-junkie Discussions; drumnjazz
Post #3 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 Wed, 18 Feb 2009 21:16:19 GMT
Also, thanks for the heads up with the Javascript issue. I suppose the only thing that would work to fix this would be to use the standard button. Is that right?]]>
E-junkie Discussions; drumnjazz
Post #2 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 Wed, 18 Feb 2009 20:59:59 GMT
<form action="https://www.e-junkie.com/ecom/gb.php?c=cart&i=210879&cl=10022&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="Medium">Medium</option>
<option value="Large">Large</option>
<option value="Extra Large">Extra Large</option>
</select>
<br/>
<a href=# onClick="javascript:return EJEJC_lc(this.parentNode);">ADD TO CART [T-SHIRT+MP3 $15.99]</a>
</form>

The only drawback to this, and there's really no way around it, is that buyers who have JavaScript disabled in their browser will be unable to Add to Cart this item. HTML provides no "standard" way to submit a form using a text link instead of a button, so the only way of doing it involves JavaScript tricks, which of course won't work if JavaScript has been disabled.]]>
E-junkie Discussions; E-junkieGuru
Post #1 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 http://www.e-junkie.com/bb/topic/3197/pg/0#post9241 Wed, 18 Feb 2009 11:57:41 GMT
However, I just added a t-shirt to my store and have options for different sizes. I am not sure how to alter the code so that I can continue to use plain text formatting instead of the ej_add_to_cart.gif.

Here is my current code which forces me to use the gif and renders the plain text dead:

<form action="https://www.e-junkie.com/ecom/gb.php?c=cart&i=210879&cl=10022&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="Medium">Medium</option>
<option value="Large">Large</option>
<option value="Extra Large">Extra 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"/></form>ADD TO CART [T-SHIRT+MP3 $15.99]</a>


Here is my standard code which allows me to use plain text:

<a href="https://www.e-junkie.com/ecom/gb.php?c=cart&i=201769&cl=10022&ejc=2" target="ej_ejc" class="ec_ejc_thkbx" onClick="javascript:return EJEJC_lc(this);">ADD TO CART [CD+MP3 $7.99]</a>]]>
E-junkie Discussions; drumnjazz