Файл anycomment.php

обновление данных о новых комментариях anycomment.io. Подробнее...

См. исходные тексты.

Переменные

 $response = Wrong\Curl\API::req_external('https://anycomment.io/v1/client/comment?token=' . Wrong\Start\Env::$e->ANYCOMMENT_SECRET . '&url=https://' . Wrong\Start\Env::$e->HTTP_HOST . '/comments')
 
if(! $response->_meta) $data = file_exists($_SERVER['DOCUMENT_ROOT'] . '/../temp/comments') ? json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . '/../temp/comments'), true) : ['new' => 0, 'old' => 0]
 
if(isset($_POST['readed'])) else
 
 $data ['new'] = $data['new'] > 0 ? $data['new'] : 0
 

Подробное описание

обновление данных о новых комментариях anycomment.io.

См. определение в файле anycomment.php

Переменные

◆ $data [1/2]

if (! $response->_meta) $data = file_exists($_SERVER['DOCUMENT_ROOT'] . '/../temp/comments') ? json_decode(file_get_contents($_SERVER['DOCUMENT_ROOT'] . '/../temp/comments'), true) : ['new' => 0, 'old' => 0]

См. определение в файле anycomment.php строка 18

◆ $data [2/2]

$data[ 'new'] = $data['new'] > 0 ? $data['new'] : 0

См. определение в файле anycomment.php строка 24

◆ $response

$response = Wrong\Curl\API::req_external('https://anycomment.io/v1/client/comment?token=' . Wrong\Start\Env::$e->ANYCOMMENT_SECRET . '&url=https://' . Wrong\Start\Env::$e->HTTP_HOST . '/comments')

См. определение в файле anycomment.php строка 12

◆ else

if (isset( $_POST[ 'readed'])) else
Инициализатор
{
$data['new'] = $response->_meta->totalCount - $data['old']
if(! $response->_meta) $data
Definition: anycomment.php:18
$response
Definition: anycomment.php:12

См. определение в файле anycomment.php строка 22