Is there a way to pause Ads after x time (20 minutes) or a certain time of day ?

2017-03-16 Thread Dan Hai
Is there a way to pause Ads after x time (20 minutes) or a certain time of day ? The reason why I am trying to do this is, after I create new ads, I want the older ads to still be running until the newer ads recently created get approved. Please let me know of an example that is relevant in ter

When did the v201702 Google API for PHP release, and what are the changes since?

2017-03-13 Thread Dan Hai
To Whom This May Concern: I am writing because I recently noticed that v201702 is out and about, however, I have been using v201609 for a while now (1 month) and was wondering when exactly this took place and what are the noticeable changes since the previous version? If you would be able to a

Re: PHP Fatal error: Uncaught SoapFault exception: [soap:Client] Unmarshalling Error: cvc-elt.4.3: Type 'ns1:AdGroupAd' is not validly derived from the type definition, 'long', of element 'ns1:id

2017-03-13 Thread Dan Hai
do { // Retrieve ad group ads one page at a time, continuing to request pages // until all ad group ads have been retrieved. $page = $adGroupAdService->get($selector); // Print out some information for each ad group ad. if ($page->getEntries() !== null) { $totalNumEntries = $page->

PHP Fatal error: Uncaught SoapFault exception: [soap:Client] Unmarshalling Error: cvc-elt.4.3: Type 'ns1:AdGroupAd' is not validly derived from the type definition, 'long', of element 'ns1:id

2017-03-13 Thread Dan Hai
This is my code: class GetExpandedTextAds { const AD_GROUP_ID = '38776120257'; const PAGE_LIMIT = 500; public static function runExample(AdWordsServices $adWordsServices, AdWordsSession $session, $adGroupId) { $adGroupAdService = $adWordsServices->get($session, AdGroupAd

Re: Can I make changes to Ads in a AdGroup, if so how?

2017-03-10 Thread Dan Hai
r(Operator::SET); $operations[] = $operation; // Remove the ad on the server. $result = $adGroupAdService->mutate($operations); $adGroupAd = $result->getValue()[0]; printf("Ad with ID %d was removed.\n", $adGroupAd->getAd()->getId()); } On Friday, March 10, 20

Can I make changes to Ads in a AdGroup, if so how?

2017-03-10 Thread Dan Hai
Can I make changes to Ads in a AdGroup, if so how? Would I need to create an operation method and create a new Ad operation? -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDe

Re: Trying to run a script to remove multiple Adgroups

2017-03-09 Thread Dan Hai
tus::REMOVED); On Tuesday, March 7, 2017 at 10:45:00 AM UTC-6, Dan Hai wrote: > > Not sure where I am messing up. Here is my code: > > public static function runExample(AdWordsServices $adWordsServices, > AdWordsSession $session) > { > > > > $adGroupId = array(372

Trying to run a script to remove multiple Adgroups

2017-03-07 Thread Dan Hai
Not sure where I am messing up. Here is my code: public static function runExample(AdWordsServices $adWordsServices, AdWordsSession $session) { $adGroupId = array(3729748624, 37497486701); $adGroupCount = count($adGroupId); for ($x = 0; $x < $adGroupCount; $x++) { $arra

SET and ADD for Operator

2017-03-03 Thread Dan Hai
Can i use ADD for updating, or I would have to use SET ? -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDevelopers/posts =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You

Can i use the dateRange function to filter adGroups, campaigns, etc. ?

2017-03-03 Thread Dan Hai
Can i use the dateRange function to filter adGroups, campaigns, etc. ? -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDevelopers/posts =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

Re: Solution for creating a label when creating a TextAd

2017-03-03 Thread Dan Hai
Do you guys know if this is still the case? On Friday, October 3, 2014 at 5:37:01 AM UTC-5, Alan Coleman wrote: > > Hello everyone, > > I'd like to be able to add a *label* to a *TextAd *when creating the > TextAd. > > I'm creating the TextAd using AdGroupAdOperation >

Google API AddAdGroups error

2017-02-28 Thread Dan Hai
I am getting a "PHP Fatal error: Uncaught Google\AdsApi\AdWords\v201609\cm\ApiException: [RangeError.TOO_LOW @ operations[0].operand.campaignId.id, RangeError.TOO_LOW @ operations[1].operand.campaignId.id] in /home/danielhai/test/vendor/googleads/googleads-php-lib/src/Google/AdsApi/Common/Util