I just implemented a pretty nifty mod for X-Cart and I wanted to share.
We are building a website for direct marketing products in 4x, and our product pages are very very long, as dictated by the genre and conversion data we have. We did not want to have the buy information at the top, as our customers respond better to reading through the content before being approached with price and options.
However, we did want to give buyers the option to click a "Get it Now" button placed periodically throughout the long description at strategic points that would automatically add the item to the cart with the default values set in the product options at the bottom of the page, where the full ordering area was.
The solution:
I created a file called ordersubmit_js.tpl and place it in /store/skin1/
with the code:
Quote:
{literal}
<SCRIPT type="text/javascript" language="JavaScript 1.2">
function submitorder()
{
document.orderform.submit();}
</SCRIPT>
{/literal}
|
in store/skin1/customer/main/product.tpl, after
Quote:
{include file="form_validation_js.tpl"}
|
paste:
Quote:
{include file="ordersubmit_js.tpl"}
|
Then, in the long product description, you can manually place code for a buy now button where ever you may want it with the following code:
I hope this is handy for anyone else in our situation! Our store is still in dev, so I can't show you how we are using it yet, but I'll keep you posted when it's live.
Belen
Designer/Developer
www.hypnosisnetwork.com
X-cart v4.08