Страница 3 из 42

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 12:40 pm
directman66
А самое главное - можно также забирать историю голосовых запросов от колонок гугл хоум.

Код: Выделить всё

$cookie='/var/www/cms/google.txt';
$ch = curl_init('https://myactivity.google.com/item?restrict=vaa&hl=ru&utm_source=udc&utm_medium=r&utm_campaign=');
    curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie);
    curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($ch, CURLOPT_TIMEOUT, 3);
    curl_setopt($ch, CURLOPT_HEADER, 1);
    $response = curl_exec($ch);
    $info = curl_getinfo($ch);
    curl_close($ch);

echo $response;
Осталось туда передать какие-то параметры - и можно будет даже обработчик транслита прилепить для английских колонок.

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 2:16 pm
Pr0gra2Mer
Странно, не получает местоположение. Хотя куки выгрузил. Файл обновляется при нажатии "Get locations".
Правда у меня под Окнами Алиса.

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 2:24 pm
Eraser
Pr0gra2Mer писал(а): Чт апр 11, 2019 2:16 pm Странно, не получает местоположение. Хотя куки выгрузил. Файл обновляется при нажатии "Get locations".
Правда у меня под Окнами Алиса.
если debug галку поставить, что в логе пишет?

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 2:43 pm
Pr0gra2Mer
Eraser писал(а): Чт апр 11, 2019 2:24 pm
Pr0gra2Mer писал(а): Чт апр 11, 2019 2:16 pm Странно, не получает местоположение. Хотя куки выгрузил. Файл обновляется при нажатии "Get locations".
Правда у меня под Окнами Алиса.
если debug галку поставить, что в логе пишет?
Логи посмотреть Xray -> Debug?

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 2:50 pm
xor
Pr0gra2Mer писал(а):
Eraser писал(а): Чт апр 11, 2019 2:24 pm
Pr0gra2Mer писал(а): Чт апр 11, 2019 2:16 pm Странно, не получает местоположение. Хотя куки выгрузил. Файл обновляется при нажатии "Get locations".
Правда у меня под Окнами Алиса.
если debug галку поставить, что в логе пишет?
Логи посмотреть Xray -> Debug?
И в дебуге выбрать Файл лога с именем, напоминающим название модуля

Отправлено с моего Redmi 4X через Tapatalk


Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 2:53 pm
Pr0gra2Mer
xor писал(а): Чт апр 11, 2019 2:50 pm
Pr0gra2Mer писал(а):
Eraser писал(а): Чт апр 11, 2019 2:24 pm
Pr0gra2Mer писал(а): Чт апр 11, 2019 2:16 pm Странно, не получает местоположение. Хотя куки выгрузил. Файл обновляется при нажатии "Get locations".
Правда у меня под Окнами Алиса.
если debug галку поставить, что в логе пишет?
Логи посмотреть Xray -> Debug?
И в дебуге выбрать Файл лога с именем, напоминающим название модуля

Отправлено с моего Redmi 4X через Tapatalk

Код: Выделить всё

17:52:00 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:52:00 Location data : Connection successful, reponse : 0
17:50:00 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:50:00 Location data : Connection successful, reponse : 0
17:48:01 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:48:01 Location data : Connection successful, reponse : 0
17:46:00 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:46:00 Location data : Connection successful, reponse : 0
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(148): google_location->updateLocation()
#3 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(88): google_location->admin(Array)
#4 C:\_majordomo\htdocs\lib\jTemplate.class.php(713) : eval()'d code(8): google_location->run()
#5 C:\_majordomo\htdocs\lib\jTemplate.class.php(713): eval()
#6 C:\_majordomo\htdocs\lib\jTemplate.class.php(195): jTemplate->parseModules('<!DOCTYPE html>...', Array, './templates/')
#7 C:\_majordomo\htdocs\lib\jTemplate.class.php(109): jTemplate->parse('<!DOCTYPE html>...', Array, './templates/')
#8 C:\_majordomo\htdocs\lib\parser.class.php(93): jTemplate->__construct('./templates/pan...', Array, Object(panel))
#9 C:\_majordomo\htdocs\lib\parser.class.php(63): parser->jtemplate_parse('./templates/pan...', Array)
#10 C:\_majordomo\htdocs\modules\panel.class.php(192): parser->__construct('./templates/pan...', Array, Object(panel))
#11 C:\_majordomo\htdocs\admin.php(34): panel->run()
#12 {main}

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 3:20 pm
Eraser
Pr0gra2Mer писал(а): Чт апр 11, 2019 2:53 pm
xor писал(а): Чт апр 11, 2019 2:50 pm
Pr0gra2Mer писал(а):
Eraser писал(а): Чт апр 11, 2019 2:24 pm
Pr0gra2Mer писал(а): Чт апр 11, 2019 2:16 pm Странно, не получает местоположение. Хотя куки выгрузил. Файл обновляется при нажатии "Get locations".
Правда у меня под Окнами Алиса.
если debug галку поставить, что в логе пишет?
Логи посмотреть Xray -> Debug?
И в дебуге выбрать Файл лога с именем, напоминающим название модуля

Отправлено с моего Redmi 4X через Tapatalk

Код: Выделить всё

17:52:00 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:52:00 Location data : Connection successful, reponse : 0
17:50:00 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:50:00 Location data : Connection successful, reponse : 0
17:48:01 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:48:01 Location data : Connection successful, reponse : 0
17:46:00 Exception: Error connection : 0 => {"http_code":""} in C:\_majordomo\htdocs\modules\google_location\google_location.class.php:282
Stack trace:
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(183): google_location->updateLocation()
#3 C:\_majordomo\htdocs\lib\hooks.inc.php(146): google_location->processSubscription('MINUTELY', Array)
#4 C:\_majordomo\htdocs\objects\index.php(175): processSubscriptions('MINUTELY', Array)
#5 {main}
17:46:00 Location data : Connection successful, reponse : 0
#0 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(228): google_location->getLocationData()
#1 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(187): google_location->getLocation()
#2 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(148): google_location->updateLocation()
#3 C:\_majordomo\htdocs\modules\google_location\google_location.class.php(88): google_location->admin(Array)
#4 C:\_majordomo\htdocs\lib\jTemplate.class.php(713) : eval()'d code(8): google_location->run()
#5 C:\_majordomo\htdocs\lib\jTemplate.class.php(713): eval()
#6 C:\_majordomo\htdocs\lib\jTemplate.class.php(195): jTemplate->parseModules('<!DOCTYPE html>...', Array, './templates/')
#7 C:\_majordomo\htdocs\lib\jTemplate.class.php(109): jTemplate->parse('<!DOCTYPE html>...', Array, './templates/')
#8 C:\_majordomo\htdocs\lib\parser.class.php(93): jTemplate->__construct('./templates/pan...', Array, Object(panel))
#9 C:\_majordomo\htdocs\lib\parser.class.php(63): parser->jtemplate_parse('./templates/pan...', Array)
#10 C:\_majordomo\htdocs\modules\panel.class.php(192): parser->__construct('./templates/pan...', Array, Object(panel))
#11 C:\_majordomo\htdocs\admin.php(34): panel->run()
#12 {main}
интернет на сервере доступен?

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 6:17 pm
viktor6
Eraser писал(а): Чт апр 11, 2019 9:54 am
directman66 писал(а): Чт апр 11, 2019 9:42 am Как по простому скачать именно тот файл кукисов? Можно сделать загрузку файла на сервер? Пример загрузки файла есть у меня в модуле camshoter.
Чтобы получить файл с cookies:
  1. Зайти на https://www.google.ru/maps
  2. Авторизоваться там, если не авторизовались
  3. Сохранить файл с помощью cookies.txt
Насчет загрузки на сервер я подумаю, в планах было попробовать авторизоваться по логин/паролю и получить нужные cookies
Что значить сохранить с помощью cookies.txt

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 6:24 pm
Eraser
viktor6 писал(а): Чт апр 11, 2019 6:17 pm
Eraser писал(а): Чт апр 11, 2019 9:54 am
directman66 писал(а): Чт апр 11, 2019 9:42 am Как по простому скачать именно тот файл кукисов? Можно сделать загрузку файла на сервер? Пример загрузки файла есть у меня в модуле camshoter.
Чтобы получить файл с cookies:
  1. Зайти на https://www.google.ru/maps
  2. Авторизоваться там, если не авторизовались
  3. Сохранить файл с помощью cookies.txt
Насчет загрузки на сервер я подумаю, в планах было попробовать авторизоваться по логин/паролю и получить нужные cookies
Что значить сохранить с помощью cookies.txt
Cookie.txt - плагин для chrome, это ссылка на сам плагин

Re: [Модуль] Google Location

Добавлено: Чт апр 11, 2019 6:31 pm
viktor6
Eraser писал(а): Чт апр 11, 2019 6:24 pm
Cookie.txt - плагин для chrome, это ссылка на сам плагин
Я логику не улавливаю плагин устанавливается в браузер правильно? Но причем тут слова Сохранить файл с помощью cookies.txt написал бы установить плагин.
Тогда не понятно что указывать в Cookie path