Rich-text Reply

Dynamic Keyword Insertion?

Ed 01-28-15

Dynamic Keyword Insertion?

Hi I'm wondering if Optimizely allows for dynamic keyword insertion code as provided by Google? As I understand, it's possible to apply the following line of text to the .htaccess file: AddType application/x-httpd-php .htm .html

(a workaround to allow for using php codes within the html code), and then utilizing  <? echo $_GET[‘kw’] ?> on the landing page to dynamically insert an Adwords keyword on the landing page.

 

Is this process compatible with Optimizely? And if so, I assume the .htaccess file would be edited on my side on the landing page template, and the php code in the Optimizely editor? 

 

Took this process from this informative post.

Ed
Level 2

Brian_Abad 01-28-15
 

Re: Dynamic Keyword Insertion?

Hey Ed,

Thanks for your question!

The Optimizely editor, more specifically the < edit code > box accepts JavaScript (and by definition, jQuery). That said, is the AdWords keyword present within the URL of your experiment? An alternative could be to grab the keyword within the URL using JavaScript, saving that value to a variable, and editing the headline by inserting this variable.

Let me know how this sounds to you!
---
Brian Abad
Manager, Technical Support
Customer Success
Optimizely
Ed 01-28-15
 

Re: Dynamic Keyword Insertion?

Thanks Brian but I'm afraid that wouldn't work - the idea is to have just one landing page (and hence url) to drive many different keyword ads to, and dynamically insert each keyword from the ad that directed the user to the page, in the headline.

Im guessing by your answer the suggested process is not possible?
Ed
Level 2
Brian_Abad 01-28-15
 

Re: Dynamic Keyword Insertion?

Is there a referrer URL that contains the keyword, Ed? We can pull from this property as well if it contains a keyword.
---
Brian Abad
Manager, Technical Support
Customer Success
Optimizely
Ed 01-28-15
 

Re: Dynamic Keyword Insertion?

That is possible but not preferable. It would mean creating a different ad for every keyword and there are thousands of permuatations to its not practical. Nice idea but sounds like this isnt going to be possible
Ed
Level 2
anna_myus 06-24-16
 

Re: Dynamic Keyword Insertion?

[ Edited ]
 
anna_myus 06-29-16
 

Re: Dynamic Keyword Insertion?

Hi Brian, I know this post was from 2015 but along the same lines, I was wondering whether I would be able to take a user's country value (assuming it's a variable) and dynamically insert onto the page content.
Brian_Abad 06-29-16
 

Re: Dynamic Keyword Insertion?

Hey there,

This is possible if the following 2 items are met:

1. There is a developer resource available that is familiar with JavaScript / jQuery
2. The variable is present above the Optimizely snippet

If yes, the < edit code > box within the visual editor contains the JavaScript that is ran on the page to render experimental changes. Instead of using the visual editor tools to generate changes, custom JavaScript can be inserted within this feature to render the desired change. So if a developer is available they should be able to create the change you're looking to make!

Did you have any other questions I can help with?
---
Brian Abad
Manager, Technical Support
Customer Success
Optimizely