Bitrix-D7
23.9
Загрузка...
Поиск...
Не найдено
Google.php
1
<?php
2
3
namespace
Bitrix\Seo\Webmaster\Engine
;
4
5
use
Bitrix\Main\Text\HtmlFilter
;
6
use
Bitrix\Main\Web\Json
;
7
use
Bitrix\Seo\Retargeting
;
8
use
Bitrix\Seo\Retargeting\Response
;
9
use
Bitrix\Seo\Webmaster
;
10
14
class
Google
extends
Retargeting\BaseApiObject
15
{
16
public
const
TYPE_CODE
= Webmaster\Service::TYPE_GOOGLE;
17
23
public
function
getSites
():
Response
24
{
25
return
$this->
getRequest
()->send([
26
'methodName'
=>
'webmaster.sites.get'
,
27
]);
28
}
29
36
public
function
addSite
(
string
$site):
Response
37
{
38
return
$this->
getRequest
()->send([
39
'methodName'
=>
'webmaster.sites.add'
,
40
'parameters'
=> [
41
'site'
=>
HtmlFilter::encode
($site),
42
],
43
]);
44
}
45
53
public
function
getVerifyToken
(array $data):
Response
54
{
55
return
$this->
getRequest
()->send([
56
'methodName'
=>
'webmaster.verify.token.get'
,
57
'parameters'
=> [
58
'data'
=> Json::encode($data),
59
],
60
]);
61
}
62
70
public
function
verifySite
(array $data):
Response
71
{
72
return
$this->
getRequest
()->send([
73
'methodName'
=>
'webmaster.verify.site'
,
74
'parameters'
=> [
75
'data'
=> Json::encode($data),
76
],
77
]);
78
}
79
}
Bitrix\Main\Response
Definition
response.php:5
Bitrix\Main\Text\HtmlFilter
Definition
htmlfilter.php:11
Bitrix\Main\Text\HtmlFilter\encode
static encode($string, $flags=ENT_COMPAT, $doubleEncode=true)
Definition
htmlfilter.php:12
Bitrix\Main\Web\Json
Definition
json.php:11
Bitrix\Seo\Engine\Google
Definition
google.php:17
Bitrix\Seo\Retargeting\BaseApiObject
Definition
baseapiobject.php:6
Bitrix\Seo\Retargeting\BaseApiObject\getRequest
getRequest()
Definition
baseapiobject.php:44
Bitrix\Seo\Webmaster\Engine\Google\verifySite
verifySite(array $data)
Definition
Google.php:70
Bitrix\Seo\Webmaster\Engine\Google\TYPE_CODE
const TYPE_CODE
Definition
Google.php:16
Bitrix\Seo\Webmaster\Engine\Google\getVerifyToken
getVerifyToken(array $data)
Definition
Google.php:53
Bitrix\Seo\Webmaster\Engine\Google\getSites
getSites()
Definition
Google.php:23
Bitrix\Seo\Webmaster\Engine\Google\addSite
addSite(string $site)
Definition
Google.php:36
Bitrix\Seo\Retargeting
Definition
account.php:3
Bitrix\Seo\Webmaster\Engine
Definition
Google.php:3
Bitrix\Seo\Webmaster
modules
seo
lib
Webmaster
Engine
Google.php
Создано системой
1.10.0