Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Google ad word tracking code

Community Beginner ,
Apr 18, 2016 Apr 18, 2016

Hi,

I don't use CF too often and forget what little I did know.  I've been asked to insert some javascript into the header section of a CF page per the following:

<cfif FindNoCase("store.cfm?do=checkout&area=Purchase",cgi.http_referer)>

    <script type="text/javascript">

/* <![CDATA[ */

var google_conversion_id = 1070946261;

var google_conversion_language = "en";

var google_conversion_format = "3";

var google_conversion_color = "ffffff";

var google_conversion_label = "BslPCPb--mQQ1a_V_gM";

var google_remarketing_only = false;

/* ]]> */

</script>

<script type="text/javascript"

src="//www.googleadservices.com/pagead/conversion.js">

</script>

<noscript>

<div style="display:inline;">

<img height="1" width="1" style="border-style:none;" alt=""

src="//www.googleadservices.com/pagead/conversion/1070946261/?label=BslPCPb--mQQ1a_V_gM&guid=ON&script=0"/>

</div>

</noscript>

</cfif>

When I do, the page immediately pukes in CF 9.  I'm sure there is something I'm overlooking but just can't see it.  Any advice gratefully accepted.

Thanks!

--Ben

844
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Beginner , Apr 20, 2016 Apr 20, 2016

Ah geez.  I found it.  A comment prior to this code didn't have all 3 '-' in it in the closing string, which caused a large chunk of code to be commented out.  Sigh.

Thanks!

--Ben

Translate
Guide ,
Apr 19, 2016 Apr 19, 2016

Can you elaborate on "pukes"?  Do you get a ColdFusion error?  Does the page load in an unexpected way?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Apr 19, 2016 Apr 19, 2016

Hi Carl,

I get a 500 internal server error:

Server Error

500 - Internal server error.

There is a problem with the resource you are looking for, and it cannot be displayed.

   ‹ í” Ê«‹¿ dñË%Ö{Ý‰Ú à$ýÖˆ?Ç?M Ä 4"ïýiOí¶‡HÑ`x9æ/1)/NÚãîHåEÎ# ˆˆF- „oe<áÒ õZ]Ç/8x4Ʊ(-Ä2iõ "D5QzJ› ú­ ⛨ãî E †œØÉô’?GÑÅåú

...

Õ£Ò ‘›é‰èø×Ljì  XE£üQZÄfn´†¾ÈCÄA`5î ²¤1 ÷È ¿y38 „²HªSJëb¨DV·ñ'ìµG¥Ì¨Ä$cfATŸ2ñ`xNÊÕ0X · 2_ c  ÎÉPn ºý ýC „yC

That's pretty pukey to me.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Apr 20, 2016 Apr 20, 2016
LATEST

Ah geez.  I found it.  A comment prior to this code didn't have all 3 '-' in it in the closing string, which caused a large chunk of code to be commented out.  Sigh.

Thanks!

--Ben

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources