dsparks |
06-21-2005 01:19 PM |
I'm not sure what buttons you are talking about, I only see a checkout button, then a continue button on the payment selection type, then the submit order button.
Anyway, here is the code in case this helps. This disables the submit order button after it is pressed.
>>>>>>>>>>>>>
You said you are using version 3.5.12. I could only find a release with the version of 3.5.1.
I never installed the 3.5.1 version but I did install the patch on the 3.5.4 version.
I compared the checkout.tpl files for both versions (3.5.4 and 3.5.1) and they are exactly the same.
I have included a version of the checkout.tpl file with the patch already applied. You can either replace your checkout.tpl file or do a file comparison and make your own changes.
Hope this helps...
Code:
{* $Id: checkout.tpl,v 1.37 2003/11/17 12:10:16 mclap Exp $ *}
{include file="location.tpl" last_location=$lng.lbl_payment_details}
{capture name=checkout_dialog}
<form action="cart.php" method=post name=cartform>
{if $config.Appearance.show_cart_details eq "Y" or ($config.Appearance.show_cart_details eq "L" and $smarty.get.paymentid ne "" and $smarty.get.mode eq "checkout")}
{include file="customer/main/cart_details.tpl"}
{else}
{include file="customer/main/cart_contents.tpl"}
{/if}
<HR noshade size=1>
{include file="customer/main/cart_totals.tpl"}
{if $js_enabled}
{include file="buttons/update.tpl"}
{else}
{include file="submit_wo_js.tpl" value=$lng.lbl_update}
{/if}
</form>
{/capture}
{include file="dialog.tpl" title="`$lng.lbl_checkout`: `$lng.lbl_step` `$checkout_step` `$lng.lbl_of` `$total_checkout_steps`" content=$smarty.capture.checkout_dialog extra="width=100%"}
{if $smarty.get.mode eq "auth"}
{include file="main/error_login_incorrect.tpl"}
{/if}
{if $payment_data.payment_method ne ""}
<h5>{$lng.lbl_payment_method}: {$payment_data.payment_method}</h5>
{capture name=dialog}
<table border=0 cellpadding=0 cellspacing=0 width=100%>
<form action="{$payment_data.payment_script_url}" method=post name=checkout_form>
<input type=hidden name=action value="place_order">
<tr><td>
<pre>
<font>
{include file="customer/main/customer_details.tpl"}
</font>
</pre>
{include file="buttons/modify.tpl"}
{if $ignore_payment_method_selection eq ""}
<div align=right>
{include file="buttons/change_payment_method.tpl"}
</div>
{/if}
<input type=hidden name={$XCARTSESSNAME} value={$XCARTSESSID}>
{if $payment_data.payment_template ne ""}
{include file=$payment_data.payment_template}
{/if}
{include file="customer/main/checkout_notes.tpl"}
<input type=hidden name=payment_method value="{$payment_data.payment_method}">
{$lng.txt_you_are_agree} "{$lng.lbl_terms_n_conditions}" {$lng.lbl_and} "{$lng.lbl_privacy_statement}".
<p align=center>
{* =+=+=+=+=+=+=+=+=+= 20 Feb 2004 Change: DCS00080 *}
{* {if $js_enabled} *}
{* {include file="buttons/submit_order.tpl" style="button"} *}
{* {else} *}
{* {include file="submit_wo_js.tpl" value=$lng.lbl_submit_order} *}
{* {/if} *}
{literal}
<SCRIPT language=JavaScript1.2>
<!--
function classChange(element,newclass) {
element.className = newclass;
}
if (document.getElementById){ //DynamicDrive.com change
document.write('<style type="text/css">\n')
document.write('.desc{display: none;}\n')
document.write('</style>\n')
}
function switchcontent(obj){
if(document.getElementById){
var el = document.getElementById(obj);
var ar = document.getElementById("meat").getElementsByTagName("span"); //DynamicDrive.com change
if(el.style.display != "block"){ //DynamicDrive.com change
for (var i=0; i<ar.length; i++){
if (ar[i].className=="sub") //DynamicDrive.com change
ar[i].style.display = "none";
}
el.style.display = "block";
}else{
el.style.display = "none";
}
}
}
function submit_checkout() {
//alert("'Submit' order button will be removed while we process your order, Press 'Ok' to continue processing your order.");
document.checkout_form.submit();
switchcontent('submit');
}
//-->
</SCRIPT>
{/literal}
{*** End of disable submit order scripts ***}
{*** Disable submit order button upon process of order ***}
{if $js_enabled}
<div id="meat">
<p align=center>
<span id="submit" class="sub" style="display:block;">
{include file="buttons/submit_order.tpl"}
</span>
</div>
{else}
{include file="submit_wo_js.tpl" value=$lng.lbl_submit_order}
{/if}
{* =+=+=+=+=+=+=+=+=+= 20 Feb 2004 Change: DCS00080 *}
</td></tr>
</form>
</table>
{/capture}
{include file="dialog.tpl" title=$lng.lbl_payment_details content=$smarty.capture.dialog extra="width=100%"}
{elseif $payment_methods ne ""}
{capture name=dialog}
<form method=get action="cart.php" name=checkout_form>
<table border=0 align=center>
{section name=payment loop=$payment_methods}
<tr>
<td width=1><input type=radio name=paymentid value={$payment_methods[payment].paymentid}{if $payment_methods[payment].is_default eq "1"} checked{/if}></td>
<td nowrap>{$payment_methods[payment].payment_method}</td>
<td>{$payment_methods[payment].payment_details}</td>
</tr>
{/section}
<input type=hidden name=mode value=checkout>
</table>
<div align=center>
{if $js_enabled}
{include file="buttons/continue.tpl" style="button"}
{else}
{include file="submit_wo_js.tpl" value=$lng.lbl_continue}
{/if}
</div>
</form>
{/capture}
{include file="dialog.tpl" title=$lng.lbl_payment_method content=$smarty.capture.dialog extra="width=100%"}
{/if}
|