SlideShare a Scribd company logo
1 of 59
#SMX #24B @armondhammer
Decoding Code
The Secret Code
of AdWords
Scripts
Steve Hammer
President,
RankHammer
#SMX #24B @armondhammer
Breaking the Code
#SMX #24B @armondhammer
Is this how code feels
#SMX #24B @armondhammer
From Fear to Confidence
#SMX #24B @armondhammer
#SMX #24B @armondhammer
About Me
FAMILY
What it’s all about
FOOD AND
WINE
Eating as an art
form?
HOCKEY
Go Stars
RANKHAMMER
Dallas Based Digital
Marketing Agency
#SMX #24B @armondhammer
What do we do every day?
#SMX #24B @armondhammer
Manage by rules
Exceeds
Goal
CPA
Too
High
Bid
Reduce
by 15%
Action
#SMX #24B @armondhammer
Let’sTranslate
#SMX #24B @armondhammer
#SMX #24B @armondhammer11
Basic Logic
When
• Conditions
In
• Item Scope
Change
• Operation
Unless
• Limits
Selector Iterator logic
#SMX #24B @armondhammer
Specifying a Script
When
• Conditions
In
• Item Scope
Change
• Operation
Unless
• Limits
When
• CPA is
higher than
XXX
In
• Target
Campaign
Change
• Bids by -
10%
Unless
• Impression
share is
<50%
#SMX #24B @armondhammer
Code.org/starwars
#SMX #24B @armondhammer
Blockly
https://developers.google.com/blockly/
#SMX #24B @armondhammer
Loops and Conditions
#SMX #24B @armondhammer
http://www.codecademy.com/tracks/javasc
ripthttp://www.w3schools.com/js/default.
asp
http://www.learn-js.org/
Learning a little JavaScript
https://www.khanacademy.org/computing/computer-
programming
#SMX #24B @armondhammer
Make the blocks your own
#SMX #24B @armondhammer
Worst Script Ever
#SMX #24B @armondhammer
Function
#SMX #24B @armondhammer
Comments
#SMX #24B @armondhammer
Statements
#SMX #24B @armondhammer
Logger – Line 2
Bulk Operations >
Logs>
Details>
Logs>
#SMX #24B @armondhammer
Selector – Line 3 - 6
Makes an array of the type
Filtered by conditions
Finished with get();
#SMX #24B @armondhammer
Selector
Conditions are AND
Connect with .
End with ;
#SMX #24B @armondhammer
Selectable?
https://developers.google.com/adwords/scripts/docs/reference/adwordsapp/adwordsapp_adselector
#SMX #24B @armondhammer
Variables
Discreet
• 5.23
• ‘Office’
• 5+3
• ‘Today’ + variable
Arrays
• [4, 5, 7, 9]
• [‘Home’,’Office’,’Hotel’]
Objects
• {name:’Steve’,zip:75204,car:’Subaru’}
• {1:Array1,2:Array2}
#SMX #24B @armondhammer
Selector
Get all keywords
With a CTR greater than 0.01
For all time
#SMX #24B @armondhammer
We Now Have
Selected every
keyword
That has ever
Gotten a click
#SMX #24B @armondhammer
While Next
Sets up the repeating
#SMX #24B @armondhammer
Payload
Calls a method to make a
change
#SMX #24B @armondhammer
Iterator
Find the maximum CPC
Add 1%
Set as new Max CPC
#SMX #24B @armondhammer
Worst Script Ever
#SMX #24B @armondhammer
First Change
#SMX #24B @armondhammer
First Change
#SMX #24B @armondhammer
End Product
#SMX #24B @armondhammer
Change {almost}
anything
#SMX #24B @armondhammer
Next Level
Prewritten Scripts
+
Code Snippets
#SMX #24B @armondhammer
Starting Scripts
http://www.rankhammer.com/blog/2541/i-heard-you-like-adwords-scripts
https://developers.google.com/adwords/scripts/docs/solution/
http://freeadwordsscripts.com
#SMX #24B @armondhammer
Defining a Function
Functions can return values to
feed a variable
Functions can also just be
invoked, even without
parameters
#SMX #24B @armondhammer
Snippets
https://developers.google.com/adwords/scripts/docs/examples/
#SMX #24B @armondhammer
Not exactly ready to use
#SMX #24B @armondhammer
Odd Selector Logic
Values have to become
strings
#SMX #24B @armondhammer
ODD Selector LOGIC
To make it flexible it has to
be:
“Column Operator” +Value
'Name = "' + var + '"'
Odd Selector Logic
#SMX #24B @armondhammer
Tweak The Selector
#SMX #24B @armondhammer45
Organize Protip:
Make aText Document
Store modified function snippets
Copy Paste next time
#SMX #24B @armondhammer
Multiple Functions
#SMX #24B @armondhammer
Look at real needs
#SMX #24B @armondhammer
Good Candidates
DailyActivities
• Scale Changes
• Profit bidding
Bulk Changes
• KW addition
Rapid Movement
• Limited Inventory
• Price Changes
Creative Models
• Correlated Bidding
Ad Copy
Rotation
• Timely Changes
#SMX #24B @armondhammer
Specifying a Script
When
• Conditions
In
• Item Scope
Change
• Operation
Unless
• Limits
When
• CPA is
higher than
XXX
In
• Target
Campaign
Change
• Bids by -
10%
Unless
• Impression
share is
<50%
#SMX #24B @armondhammer
Franchises – Locations growing
#SMX #24B @armondhammer
Our problem
When
• Conditions
In
• Item Scope
Change
• Operation
Unless
• Limits
When
• A new
location
launches
In
• New
adgroup
Change
• Add city
name to
base
keywords
Unless
• N/A
#SMX #24B @armondhammer
The goal – another way
Marketing
+marketing
+plano
“marketing
plano”
“plano
marketing”
#SMX #24B @armondhammer
Flesh out the basic idea – all comments
#SMX #24B @armondhammer
Find snippets and modify
#SMX #24B @armondhammer
Flesh out the details
#SMX #24B @armondhammer
Test and Preview
#SMX #24B @armondhammer
I expect you to die try
#SMX #24B @armondhammer
Protip:
CopyTo Editor
Review Changes as “proposed”
Reject to undo
#SMX #24B @armondhammer
LEARN MORE: UPCOMING @SMX EVENTS
THANK YOU!
SEE YOU AT THE NEXT #SMX

More Related Content

More from Search Marketing Expo - SMX

More from Search Marketing Expo - SMX (20)

SMX SlideShare Announcement
SMX SlideShare AnnouncementSMX SlideShare Announcement
SMX SlideShare Announcement
 
SMX East 2018 - #SMXInsights
SMX East 2018 - #SMXInsightsSMX East 2018 - #SMXInsights
SMX East 2018 - #SMXInsights
 
SMX Advanced 2018 - #SMXInsights
SMX Advanced 2018 - #SMXInsights SMX Advanced 2018 - #SMXInsights
SMX Advanced 2018 - #SMXInsights
 
SMX West 2018 #SMXInsights
SMX West 2018 #SMXInsightsSMX West 2018 #SMXInsights
SMX West 2018 #SMXInsights
 
SMX Speaker Guidelines
SMX Speaker GuidelinesSMX Speaker Guidelines
SMX Speaker Guidelines
 
AMP: Do or Die? 2017 Audience Survey Results
AMP: Do or Die? 2017 Audience Survey ResultsAMP: Do or Die? 2017 Audience Survey Results
AMP: Do or Die? 2017 Audience Survey Results
 
Create for Someone, Not Just Anyone: Adobe's Audience Audit By Maria Corcoran
Create for Someone, Not Just Anyone: Adobe's Audience Audit By Maria CorcoranCreate for Someone, Not Just Anyone: Adobe's Audience Audit By Maria Corcoran
Create for Someone, Not Just Anyone: Adobe's Audience Audit By Maria Corcoran
 
Alexa, How Do I Do SEO For You? By Navneet Virk
Alexa, How Do I Do SEO For You? By Navneet VirkAlexa, How Do I Do SEO For You? By Navneet Virk
Alexa, How Do I Do SEO For You? By Navneet Virk
 
Consumer Lead Change: How to Stay Relevant and Build Success By Duane Forrester
Consumer Lead Change: How to Stay Relevant and Build Success By Duane ForresterConsumer Lead Change: How to Stay Relevant and Build Success By Duane Forrester
Consumer Lead Change: How to Stay Relevant and Build Success By Duane Forrester
 
Create Powerful Custom Automations With AdWords Scripts By Frederick Vallaeys
Create Powerful Custom Automations With AdWords Scripts By Frederick VallaeysCreate Powerful Custom Automations With AdWords Scripts By Frederick Vallaeys
Create Powerful Custom Automations With AdWords Scripts By Frederick Vallaeys
 
Using AdWords Scripts to Create Your Own Ad Tech Landscape By Mitch Larson
Using AdWords Scripts to Create Your Own Ad Tech Landscape By Mitch LarsonUsing AdWords Scripts to Create Your Own Ad Tech Landscape By Mitch Larson
Using AdWords Scripts to Create Your Own Ad Tech Landscape By Mitch Larson
 
Busting Google's Black Box: Navigating Google Algorithms in a Post-Update Wor...
Busting Google's Black Box: Navigating Google Algorithms in a Post-Update Wor...Busting Google's Black Box: Navigating Google Algorithms in a Post-Update Wor...
Busting Google's Black Box: Navigating Google Algorithms in a Post-Update Wor...
 
Solving SEO Issues In Google's Post Update World: How To Track Unconfirmed Al...
Solving SEO Issues In Google's Post Update World: How To Track Unconfirmed Al...Solving SEO Issues In Google's Post Update World: How To Track Unconfirmed Al...
Solving SEO Issues In Google's Post Update World: How To Track Unconfirmed Al...
 
The Journey To Cross-Device Nirvana By Mike Henderson
The Journey To Cross-Device Nirvana By Mike HendersonThe Journey To Cross-Device Nirvana By Mike Henderson
The Journey To Cross-Device Nirvana By Mike Henderson
 
Dating Tips to Maximize the Brand Agency Relationship By Chad Gingrich and Sh...
Dating Tips to Maximize the Brand Agency Relationship By Chad Gingrich and Sh...Dating Tips to Maximize the Brand Agency Relationship By Chad Gingrich and Sh...
Dating Tips to Maximize the Brand Agency Relationship By Chad Gingrich and Sh...
 
Let's Start Using Event Tracking For More Than Email Clicks By Joe Martinez
Let's Start Using Event Tracking For More Than Email Clicks By Joe MartinezLet's Start Using Event Tracking For More Than Email Clicks By Joe Martinez
Let's Start Using Event Tracking For More Than Email Clicks By Joe Martinez
 
Using Paid Search & Social Together To Deliver The Ultimate Knock-Out Punch B...
Using Paid Search & Social Together To Deliver The Ultimate Knock-Out Punch B...Using Paid Search & Social Together To Deliver The Ultimate Knock-Out Punch B...
Using Paid Search & Social Together To Deliver The Ultimate Knock-Out Punch B...
 
Paid Search Fundamentals By Matt Van Wagner
Paid Search Fundamentals By Matt Van WagnerPaid Search Fundamentals By Matt Van Wagner
Paid Search Fundamentals By Matt Van Wagner
 
Dynamic Remarketing for the Google Display Network By David Szetela
Dynamic Remarketing for the Google Display Network By David SzetelaDynamic Remarketing for the Google Display Network By David Szetela
Dynamic Remarketing for the Google Display Network By David Szetela
 
Brick & Mortar's Secret Weapon: Search Data By Andrew Ruegger
Brick & Mortar's Secret Weapon: Search Data By Andrew RueggerBrick & Mortar's Secret Weapon: Search Data By Andrew Ruegger
Brick & Mortar's Secret Weapon: Search Data By Andrew Ruegger
 

Recently uploaded

Recently uploaded (20)

Five Essential Tools for International SEO - Natalia Witczyk - SearchNorwich 15
Five Essential Tools for International SEO - Natalia Witczyk - SearchNorwich 15Five Essential Tools for International SEO - Natalia Witczyk - SearchNorwich 15
Five Essential Tools for International SEO - Natalia Witczyk - SearchNorwich 15
 
The+State+of+Careers+In+Retention+Marketing-2.pdf
The+State+of+Careers+In+Retention+Marketing-2.pdfThe+State+of+Careers+In+Retention+Marketing-2.pdf
The+State+of+Careers+In+Retention+Marketing-2.pdf
 
Choosing the Right White Label SEO Services to Boost Your Agency's Growth.pdf
Choosing the Right White Label SEO Services to Boost Your Agency's Growth.pdfChoosing the Right White Label SEO Services to Boost Your Agency's Growth.pdf
Choosing the Right White Label SEO Services to Boost Your Agency's Growth.pdf
 
BDSM⚡Call Girls in Sector 19 Noida Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Sector 19 Noida Escorts >༒8448380779 Escort ServiceBDSM⚡Call Girls in Sector 19 Noida Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Sector 19 Noida Escorts >༒8448380779 Escort Service
 
Kraft Mac and Cheese campaign presentation
Kraft Mac and Cheese campaign presentationKraft Mac and Cheese campaign presentation
Kraft Mac and Cheese campaign presentation
 
BDSM⚡Call Girls in Vaishali Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Vaishali Escorts >༒8448380779 Escort ServiceBDSM⚡Call Girls in Vaishali Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Vaishali Escorts >༒8448380779 Escort Service
 
VIP Call Girls Dongri WhatsApp +91-9833363713, Full Night Service
VIP Call Girls Dongri WhatsApp +91-9833363713, Full Night ServiceVIP Call Girls Dongri WhatsApp +91-9833363713, Full Night Service
VIP Call Girls Dongri WhatsApp +91-9833363713, Full Night Service
 
Discover Ardency Elite: Elevate Your Lifestyle
Discover Ardency Elite: Elevate Your LifestyleDiscover Ardency Elite: Elevate Your Lifestyle
Discover Ardency Elite: Elevate Your Lifestyle
 
BDSM⚡Call Girls in Sector 144 Noida Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Sector 144 Noida Escorts >༒8448380779 Escort ServiceBDSM⚡Call Girls in Sector 144 Noida Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Sector 144 Noida Escorts >༒8448380779 Escort Service
 
Labour Day Celebrating Workers and Their Contributions.pptx
Labour Day Celebrating Workers and Their Contributions.pptxLabour Day Celebrating Workers and Their Contributions.pptx
Labour Day Celebrating Workers and Their Contributions.pptx
 
Digital-Marketing-Into-by-Zoraiz-Ahmad.pptx
Digital-Marketing-Into-by-Zoraiz-Ahmad.pptxDigital-Marketing-Into-by-Zoraiz-Ahmad.pptx
Digital-Marketing-Into-by-Zoraiz-Ahmad.pptx
 
BDSM⚡Call Girls in Sector 44 Noida Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Sector 44 Noida Escorts >༒8448380779 Escort ServiceBDSM⚡Call Girls in Sector 44 Noida Escorts >༒8448380779 Escort Service
BDSM⚡Call Girls in Sector 44 Noida Escorts >༒8448380779 Escort Service
 
Instant Digital Issuance: An Overview With Critical First Touch Best Practices
Instant Digital Issuance: An Overview With Critical First Touch Best PracticesInstant Digital Issuance: An Overview With Critical First Touch Best Practices
Instant Digital Issuance: An Overview With Critical First Touch Best Practices
 
Unraveling the Mystery of The Circleville Letters.pptx
Unraveling the Mystery of The Circleville Letters.pptxUnraveling the Mystery of The Circleville Letters.pptx
Unraveling the Mystery of The Circleville Letters.pptx
 
Busty Desi⚡Call Girls in Sector 49 Noida Escorts >༒8448380779 Escort Service
Busty Desi⚡Call Girls in Sector 49 Noida Escorts >༒8448380779 Escort ServiceBusty Desi⚡Call Girls in Sector 49 Noida Escorts >༒8448380779 Escort Service
Busty Desi⚡Call Girls in Sector 49 Noida Escorts >༒8448380779 Escort Service
 
Cash payment girl 9257726604 Hand ✋ to Hand over girl
Cash payment girl 9257726604 Hand ✋ to Hand over girlCash payment girl 9257726604 Hand ✋ to Hand over girl
Cash payment girl 9257726604 Hand ✋ to Hand over girl
 
Situation Analysis | Management Company.
Situation Analysis | Management Company.Situation Analysis | Management Company.
Situation Analysis | Management Company.
 
Busty Desi⚡Call Girls in Sector 135 Noida Escorts >༒8448380779 Escort Service
Busty Desi⚡Call Girls in Sector 135 Noida Escorts >༒8448380779 Escort ServiceBusty Desi⚡Call Girls in Sector 135 Noida Escorts >༒8448380779 Escort Service
Busty Desi⚡Call Girls in Sector 135 Noida Escorts >༒8448380779 Escort Service
 
Micro-Choices, Max Impact Personalizing Your Journey, One Moment at a Time.pdf
Micro-Choices, Max Impact Personalizing Your Journey, One Moment at a Time.pdfMicro-Choices, Max Impact Personalizing Your Journey, One Moment at a Time.pdf
Micro-Choices, Max Impact Personalizing Your Journey, One Moment at a Time.pdf
 
Press Release Distribution Evolving with Digital Trends.pdf
Press Release Distribution Evolving with Digital Trends.pdfPress Release Distribution Evolving with Digital Trends.pdf
Press Release Distribution Evolving with Digital Trends.pdf
 

The Secret Codes of AdWords Scripts By Steven Hammer