Hello all,

Usually i make html websites. But now i had to make one with a cms, so i picked drupal. There is a script i want to implement in my website, but i don't know how to do that. Can someone help me with that? Thanks in advance.

M.

Comments

tnanek’s picture

What kind of script?

eejtje’s picture

a google AdWords script

arh1’s picture

check out the drupal_add_js function.

eejtje’s picture

Sorry, i wasn't very clear in my post. We paid google so that our site would appear in de AdWords block: http://www.google.nl/intl/eng/ads/

For that to work, we have to insert a script to our site:

<script type="text/javascript"> var gaJsHost = (("https:" == document.location.protocol) ? "... type='text/javascript'%3E%3C/script%3E")); </script> <script type="text/javascript"> var pageTracker ...pageTracker._trackPageview(); </script>

we have to put this before the tag. But where do we have to insert this script?? In page.tpl.php? Or in some other file? I really don't understand : (

arh1’s picture

i would assume this script should appear on every page of your site, just above the </body> tag. if that's true, then yes, you should just be able to copy/paste into your theme's page.tpl.php .

eejtje’s picture

I think it should appear on every site. I don't know how Google AdWords works. I just put it in the page.tpl.php. Thanks for your help.