I'm trying to fill in the blank for a string to display the Order total on the /Checkout/Receipt.aspx page. This is for a tracking script that looks like:
script language="javascript" type="text/javascript">var gdf_orderTotal = '0.00';
I need to insert the correct total instead of 0.00.
I was unable to make Nvelocity code work for this and now I'm stumped. Can anybody help me get past this?
order total
order total
Last edited by troutlet on Mon Mar 24, 2008 3:28 pm, edited 1 time in total.
- jmestep
- AbleCommerce Angel
- Posts: 8164
- Joined: Sun Feb 29, 2004 8:04 pm
- Location: Dayton, OH
- Contact:
It looks like it would be this:
Order.TotalCharges
In 5.5, we used to be able to refer to it in tracking code like:
<%=Order.TotalCharges%>
Order.TotalCharges
In 5.5, we used to be able to refer to it in tracking code like:
<%=Order.TotalCharges%>
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
nope
Thanks Judy. I tried and it did not do it. hmmmmmmmmmmm
order total
Well I talked with the people providing the tracking code to help, they talked to Able Commerce people over Live Chat and were told to search the forum (thanks).
At first I felt slighted but then I realized that it's not a Support contract that we have by buying AC7, it's only a software upgrade contract so it's really no fault of AC.
I admit I'm no expert on this type of thing but I've searched through existing scripts in ConLib and tried everything that even remotely resembles an order total and nothing works. I WAS able to collect the order total using Nvelocity however that page (receipt.aspx) does not support Nvelocity so that's no help at all. The total needs to appear in a javascript call.
Any thoughts?
At first I felt slighted but then I realized that it's not a Support contract that we have by buying AC7, it's only a software upgrade contract so it's really no fault of AC.
I admit I'm no expert on this type of thing but I've searched through existing scripts in ConLib and tried everything that even remotely resembles an order total and nothing works. I WAS able to collect the order total using Nvelocity however that page (receipt.aspx) does not support Nvelocity so that's no help at all. The total needs to appear in a javascript call.
Any thoughts?
- jmestep
- AbleCommerce Angel
- Posts: 8164
- Joined: Sun Feb 29, 2004 8:04 pm
- Location: Dayton, OH
- Contact:
It will pull the correct amount, but I don't know your Javascript code. I just put
<% Response.Write(Order.TotalCharges);%>
into a a visible place on the Receipt.aspx and it showed the correct order total.
Your tracking code people should be able to figure it out from there. For example, to use my old Google tracking code in an AC7 page, it would be:
<script language="JavaScript" type="text/javascript">
<!--
var google_conversion_id = xxxxxxxxx;
var google_conversion_language = "en_US";
var google_conversion_format = "1";
var google_conversion_color = "efefef";
if (<%=objOrder.TotalCharges%>) {
var google_conversion_value = <%=Order.TotalCharges%>;
}
var google_conversion_label = "Purchase";
//-->
</script>
<% Response.Write(Order.TotalCharges);%>
into a a visible place on the Receipt.aspx and it showed the correct order total.
Your tracking code people should be able to figure it out from there. For example, to use my old Google tracking code in an AC7 page, it would be:
<script language="JavaScript" type="text/javascript">
<!--
var google_conversion_id = xxxxxxxxx;
var google_conversion_language = "en_US";
var google_conversion_format = "1";
var google_conversion_color = "efefef";
if (<%=objOrder.TotalCharges%>) {
var google_conversion_value = <%=Order.TotalCharges%>;
}
var google_conversion_label = "Purchase";
//-->
</script>
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx
Thanks
Thank you very much Judy that did it.
Before I was actually trying to drop this script after the Receiptpage. When I was trying it would not work. Once I reread your post a little more carefully I placed this WITHIN receiptpage.aspx (just like you said) and it worked perfectly. I then embedded the javascript within receiptpage as well using your google example of and it worked like a charm.
You've cured a serious headache for me! thank you, thank you , thank you.
Before I was actually trying to drop this script after the Receiptpage. When I was trying
Code: Select all
<% Response.Write(Order.TotalCharges);%>
Code: Select all
<%=Order.TotalCharges%>
You've cured a serious headache for me! thank you, thank you , thank you.