I'm going to be using Google Website Optimiser (GWO), possibly on quite a few different sites. In theory it's straightforward: paste the validation Javascript code in the head and footer of a few pages you want to test:
http://services.google.com/training/websiteoptimizeruserguide/
The problem is when you use a CMS with dynamically generated urls.
Let's say I know the url of the page I want to test is: ...index.php?option=com_content&view=article&id=54&Itemid=69
What I'd like to do is save the GWO javascript in a file like mygwo.js, then put some code in the head of index.php which will only call the javascript file if the url matches the url above.
This means I would be able to install all the GWO code by only editing index.php.
I'm guessing I need something like "php include only if", but I'm pretty green on php.
Thanks for your time.
Find a unique pattern in the URI or somewhere, for example if all pages with GWO have
&view=article
then: