does know can change email address messages go to? cant find anywhere!
i have tried looking on google alerts me change notifications. not notification email addresses go.
$search_console = new google_service_webmasters($client); $site_list = $search_console->sites->listsites()->siteentry; foreach ($site_list $key => $list) { $url=$list->siteurl; $request = new \google_service_webmasters_searchanalyticsqueryrequest; $request->setstartdate('2015-01-01'); // startdate required $request->setenddate( $end ? $end : date( 'y-m-d', strtotime( 'now' ) ) ); $dimensions[] = 'query'; $request->setdimensions($dimensions); $options=array(); $search=$request; try{ $results = $service->searchanalytics->query($url, $search, $options )->getrows(); foreach ( $results $key => $result ) { $data[$key]['keywords']=$result->keys[0]; $data[$key]['avg_position']=$result->position; $data[$key]['clicks']=$result->clicks; $data[$key]['ctr'] = $result->ctr; $data[$key]['impressions'] = $result->impressions; } //search console gor particular location data } catch(\exception $e ) { echo '<pre>'; echo $e->getmessage(); } }
Comments
Post a Comment