Other advanced stuff, Using server side session variables, Advanced a/b testing – Google Website Optimizer v 1.0 The Techie Guide User Manual
Page 23: Other advanced stuff 23
23
The Techie Guide to Google Website Optimizer
Other Advanced Stuff
Other Advanced Stuff
Using Server Side Session Variables
If you’re using a single physical page, and multiple virtual versions, you may also add back-end code that
uses a server-side session variable to remember what variation to display for the user. Naturally, this requires
some experience using session variables.
The advantage to this is that visitors will be redirected only once per session -- the first time they visit the
test page. Later visits to the test page will use the session variable to show the correct version, so there’s no
need to redirect the user.
You’ll need to add some server-side code to check the URL, and set a server-side session variable to store the
variation value.
Here’s some pseudo-code that adds the support of a session variable. (Changes from previous example are
in
blue.
)
<$session_variation = variation value from URL>
$session_variation is not defined )
_stuff before the section we want to test_
$session_variation is not defined )> $session_variation ).php>
_stuff after the section we want to test_
Advanced A/B Testing
There are situations in which the A/B testing interface won’t allow you to make the customizations you may
want -- experiments that span multiple domains or copied experiments, for example.
In these situations, Website Optimizer supports a more manual implementation of A/B testing. You’ll use the
multivariate experiment creation flow in Website Optimizer to accomplish this:
1. Sign in to Website Optimizer.
2. Click
Create another experiment.
3. From the Multivariate Experiment box, click
Create.
Identify experiment pages
1. Enter an experiment name.
2. Enter your
Test page URL and Conversion page URL. You’ll identify your variation pages in a later step.
3. Click
Continue. Website Optimizer will check for the existence of these pages on your server -- if
they’re not present or not accessible, select
The URL is correct from the warning message and click
Continue again.