This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
document.addEventListener( 'wpcf7mailsent', function( event ) { | |
window.dataLayer.push({ | |
"event" : "cf7submission", | |
"formId" : event.detail.contactFormId, | |
"response" : event.detail.inputs | |
}) | |
}); | |
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
var gaProperty = 'XXXXXX'; | |
var disableStr = 'ga-disable-' + gaProperty; | |
if (document.cookie.indexOf(disableStr + '=true') > -1) { | |
window[disableStr] = true; | |
} | |
function gaOptout() { | |
document.cookie = disableStr + '=true; expires=Thu, 31 Dec 2099 23:59:59 UTC; path=/'; | |
window[disableStr] = true; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function main() { | |
var date_range = 'THIS_MONTH'; | |
//Change this variable to whatever your account level monthly budget is to be. | |
//If you have a hard limit of total Cost in a month of $1,000.00 | |
//then you would change the value to 1000. | |
var total_monthly_budget = '1000'; | |
var currentAccount = AdWordsApp.currentAccount(); | |
var stats = currentAccount.getStatsFor(date_range); | |
var accountName = currentAccount.getName(); | |
Logger.log('Cost this month to date: $' + stats.getCost()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function main() { | |
// GET THE TOTAL SPEND OF THE ACCOUNT | |
// https://developers.google.com/adwords/scripts/docs/reference/adwordsapp/adwordsapp_keywordselector | |
var costReport = AdWordsApp.report("Select Cost from ACCOUNT_PERFORMANCE_REPORT"); | |
var reportRow = costReport.rows().next(); | |
var totalCost = reportRow["Cost"].replace(',', ''); // Remove thousand separator | |
var costReport = AdWordsApp.report("Select Cost from ACCOUNT_PERFORMANCE_REPORT DURING THIS_MONTH"); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// EMAIL FIELDS | |
var _mailto = '[email protected]'; | |
var _subject = 'Account Review Needed - '; | |
var _htmlBody = '<h1>Account Review Required</h1>'; | |
var _isEmailRequired = false; | |
//PARAMETERS CHECKED | |
var _impressionsTreshold = 1; | |
var _clickTreshold = 0; | |
var _conversionTreshold = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// EMAIL FIELDS | |
var _mailto = 'YOUR EMAIL'; | |
var _subject = 'Account Review Needed - '; | |
var _htmlBody = '<h1>Account Review Required</h1>'; | |
var _isEmailRequired = false; | |
//PARAMETERS CHECKED | |
var _impressionsTreshold = 1; | |
var _clickTreshold = 0; | |
var _conversionTreshold = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var workingDateRange = "LAST_14_DAYS"; | |
function main() { | |
lowerBidsToTopKeywords(); | |
raiseBidsToMidPositionKeywords(); | |
raiseBidsToLowPositionKeywords(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// EMAIL FIELDS | |
var _mailto = 'YOUR_EMAIL'; | |
var _subject = 'Account Review Needed - '; | |
var _htmlBody = '<h1>Account Review Required</h1>'; | |
var _isEmailRequired = false; | |
//PARAMETERS CHECKED | |
var _impressionsTreshold = 100; | |
var _clickTreshold = 10; | |
var _conversionTreshold = 2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// EMAIL FIELDS | |
var _mailto = 'YOUR_EMAIL'; | |
var _subject = 'Account Review Needed - '; | |
var _htmlBody = '<h1>Account Review Required</h1>'; | |
var _isEmailRequired = false; | |
//PARAMETERS CHECKED | |
var _impressionsTreshold = 100; | |
var _clickTreshold = 10; | |
var _conversionTreshold = 2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Edit this based on the max amount you want to spend on a given day. | |
var maxSpend = 1000; | |
function main () { | |
var currentAccount = AdWordsApp.currentAccount(); | |
var stats = currentAccount.getStatsFor("TODAY"); | |
var cost = stats.getCost(); | |
Logger.log("Account has spent " + cost + " so far."); | |
if (cost > maxSpend) { | |
campaign.pause(); |
NewerOlder