Ошибки при открытии Сервисов
-
- Продвинутый
- Сообщения: 37
- Зарегистрирован: 31 дек 2011, 14:38
- Версия: 4.2.9@Amlogic, Vontar_X3, Android 9
- Версия 2: 4.5.1@Google, android TV, Android 14
- Приставки: Xtreamer
Ошибки при открытии Сервисов
Подскажите? НЕ открывается Сервис Избранное Пишет Ошибка.NOTICE:fav service inc:50(Undefined offset:3. С уважением Миша
- consros
- ГлавТВ
- Сообщения: 2137
- Зарегистрирован: 26 янв 2011, 21:36
- Версия: 5.0.0b2@Amazon, AFTMM, Android 7.1.2
- Версия 2: 5.0.0b3@Amazon, AFTMM, Android 7.1.2
- Приставки: Amazon Fire TV
- Конец дружбы: 29.03.2023
- Контактная информация:
Re: Ошибки при открытии Сервисов
Выложи сюда или пришли личным сообщением если скрываешься, содержимое cfg/favorites.ini файла.
Или прикрепи его к ответу.
Или прикрепи его к ответу.
-
- Продвинутый
- Сообщения: 37
- Зарегистрирован: 31 дек 2011, 14:38
- Версия: 4.2.9@Amlogic, Vontar_X3, Android 9
- Версия 2: 4.5.1@Google, android TV, Android 14
- Приставки: Xtreamer
Re: Ошибки при открытии Сервисов
Спасибо что так быстро откликнулись.Но если бы Вы ещё подсказали откуда я должен (могу) взять этот Файл-cfg/favorites.ini-и как его прикрепить. Моих познаний к сожалению не хватает. Но я быстро учусь. Михаил
- consros
- ГлавТВ
- Сообщения: 2137
- Зарегистрирован: 26 янв 2011, 21:36
- Версия: 5.0.0b2@Amazon, AFTMM, Android 7.1.2
- Версия 2: 5.0.0b3@Amazon, AFTMM, Android 7.1.2
- Приставки: Amazon Fire TV
- Конец дружбы: 29.03.2023
- Контактная информация:
Re: Ошибки при открытии Сервисов
Надо зайти на Xtreamer и там в sda1/scripts/xRodnoeTV/cfg/ лежит этот файл.
Обычно зайти можно просто набрав \\myxtreamer\ в проводнике или http://myxtreamer/ в браузере.
Обычно зайти можно просто набрав \\myxtreamer\ в проводнике или http://myxtreamer/ в браузере.
-
- Продвинутый
- Сообщения: 37
- Зарегистрирован: 31 дек 2011, 14:38
- Версия: 4.2.9@Amlogic, Vontar_X3, Android 9
- Версия 2: 4.5.1@Google, android TV, Android 14
- Приставки: Xtreamer
Re: Ошибки при открытии Сервисов
<?xml version="1.0" encoding="UTF-8" ?>
- <service>
<name>Favorites</name>
<description>Список избранных страниц всех сервисов. Практически любая понравившаяся Вам страница может быть добавлена в этот список с целью ускорения доступа к ней.</description>
<type>Internal service</type>
<version>1.0</version>
<author>GlavTV</author>
</service><?php
#############################################################################
# Author: consros 2011 #
#############################################################################
require_once 'interfaces/service.inc';
require_once 'interfaces/channel.inc';
require_once 'interfaces/item.inc';
require_once 'interfaces/exceptions.inc';
require_once 'interfaces/message.inc';
require_once 'tools/config.inc';
require_once 'services/utils/utilsService.inc';
class FavService extends Service {
const MAX_FAVORITES_ENTRIES = 100;
public function getServiceName() {
return 'Favorites';
}
public function startPage() {
return $this->show();
}
public function login() {
$channel = new Channel($this->lang->msg('Login'));
$channel->set(Channel::LINK,
$this->cfg->get('home_url') . '?srv=utils&req=login');
$channel->setSupportedTemplates('redirect');
return $channel;
}
public function show() {
$channel = new Channel($this->lang->msg('Favorites'));
$channel->set(Channel::THUMB_RATIO, 0);
$channel->setSupportedTemplates('detailed-list', 'icon-table');
$channel->addHotkey('enter', null,
$this->cfg->get('home_url') . '?srv=fav&req=count',
array('title' => Item::TITLE, 'url' => Item::LINK));
$channel->addHotkey('user1', $this->lang->msg('Delete'),
$this->cfg->get('home_url') . '?srv=fav&req=remove',
array('title' => Item::TITLE, 'url' => Item::LINK));
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt');
foreach ($cfgFav->getSectionNames() as $sectionName) {
$section = $cfgFav->getSection($sectionName);
foreach ($section as $title => $info) {
list($count, $time, $url, $descr) = explode('|', $info);
$item = new Item($title, $descr);
$item->set(Item::LINK, $url);
$thumb = $this->cfg->get('home_url') . "services/$sectionName/logo.png";
$item->set(Item::THUMBNAIL, $thumb);
$item->set('count', (int) $count);
$item->set(Item::TIME, $time);
$channel->addItem($item);
}
}
$channel->sortItems('!' . Item::TIME, '!count', Item::TITLE);
foreach ($channel->getItems() as $item) {
$item->set(Item::TIME, $this->tools->formatTime(
$item->get(Item::TIME)));
}
return $channel;
}
public function add() {
list($title, $url, $sectionName, $descr) = $this->getAddRemoveParams();
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt', $sectionName);
if (null != $cfgFav->get($title)) {
return new Message($this->lang->msg('Error'),
$this->lang->msg('Not added to favorites') . '. ' .
$this->lang->msg('Name already exists') . ': "' . $title .'"');
}
$time = date('Y-m-d H:i:s');
$info = "0|$time|$url|$descr";
$section = $cfgFav->getSection($sectionName);
$section = array($title => $info) + $section;
$section = array_slice($section, 0, self::MAX_FAVORITES_ENTRIES);
$cfgFav->setSection($sectionName, $section);
$cfgFav->saveFile();
return new Message($this->lang->msg('Message'),
$this->lang->msg('Added to favorites') . ': "' . $title .'"');
}
public function remove() {
list($title, $url, $sectionName) = $this->getAddRemoveParams();
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt', $sectionName);
if (null == $cfgFav->get($title)) {
return new Message($this->lang->msg('Error'),
$this->lang->msg('Not removed from favorites') . '. ' .
$this->lang->msg('No such name') . ': "' . $title .'"');
}
$section = $cfgFav->getSection($sectionName);
unset($section[$title]);
$cfgFav->setSection($sectionName, $section);
$cfgFav->saveFile();
return new Message($this->lang->msg('Message'),
$this->lang->msg('Removed from favorites') . ': "' . $title .'"');
}
public function count() {
list($title, $url, $sectionName) = $this->getAddRemoveParams();
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt');
$section = $cfgFav->getSection($sectionName);
$count = 0;
if (isset($section[$title])) {
list($count, $time, $url, $descr) = explode('|', $section[$title]);
$count++;
$time = date('Y-m-d H:i:s');
$info = "$count|$time|$url|$descr";
$section = array($title => $info) + $section;
$cfgFav->setSection($sectionName, $section);
$cfgFav->saveFile();
}
$channel = new Channel($this->lang->msg('Counter'),
$this->lang->msg('Counter increased') . ": $title, $count");
$channel->set(Channel::LINK, $this->getFullUrl($url));
$channel->setSupportedTemplates('redirect');
return $channel;
}
protected function getAddRemoveParams() {
$title = $this->getRequiredParam('title');
$url = $this->getSmallUrl($this->getRequiredParam('url'));
$descr = $this->getOptionalParam('descr', '');
$pos = strpos($url, '?');
$paramStr = false === $pos ? $url : substr($url, $pos + 1);
parse_str($paramStr, $params);
if (! isset($params['srv'])) {
throw new BadRequestException(
$this->lang->msg('Cannot parse data') . ": URL, SRV");
}
$descr = str_replace(array("\r", "\n", '\"', '"'), array(' ', ' ', '″', '″'), $descr);
$descr = ParserTools::removeHtmlTags($descr);
$title = str_replace(array("\r", "\n", '\"', '"', '=', '!'), array(' ', ' ', '″', '″', ' ', '.'), $title);
$title = ParserTools::removeHtmlTags($title);
return array($title, $url, $params['srv'], $descr);
}
protected function getFullUrl($url) {
return 0 === strpos($url, 'http:') ? $url : ($this->cfg->get('home_url') . "?$url");
}
protected function getSmallUrl($url) {
$prefix = $this->cfg->get('home_url') . '?';
return 0 === strpos($url, $prefix) ? substr($url, strlen($prefix)) : $url;
}
}
?>
Это?Не уверен
- <service>
<name>Favorites</name>
<description>Список избранных страниц всех сервисов. Практически любая понравившаяся Вам страница может быть добавлена в этот список с целью ускорения доступа к ней.</description>
<type>Internal service</type>
<version>1.0</version>
<author>GlavTV</author>
</service><?php
#############################################################################
# Author: consros 2011 #
#############################################################################
require_once 'interfaces/service.inc';
require_once 'interfaces/channel.inc';
require_once 'interfaces/item.inc';
require_once 'interfaces/exceptions.inc';
require_once 'interfaces/message.inc';
require_once 'tools/config.inc';
require_once 'services/utils/utilsService.inc';
class FavService extends Service {
const MAX_FAVORITES_ENTRIES = 100;
public function getServiceName() {
return 'Favorites';
}
public function startPage() {
return $this->show();
}
public function login() {
$channel = new Channel($this->lang->msg('Login'));
$channel->set(Channel::LINK,
$this->cfg->get('home_url') . '?srv=utils&req=login');
$channel->setSupportedTemplates('redirect');
return $channel;
}
public function show() {
$channel = new Channel($this->lang->msg('Favorites'));
$channel->set(Channel::THUMB_RATIO, 0);
$channel->setSupportedTemplates('detailed-list', 'icon-table');
$channel->addHotkey('enter', null,
$this->cfg->get('home_url') . '?srv=fav&req=count',
array('title' => Item::TITLE, 'url' => Item::LINK));
$channel->addHotkey('user1', $this->lang->msg('Delete'),
$this->cfg->get('home_url') . '?srv=fav&req=remove',
array('title' => Item::TITLE, 'url' => Item::LINK));
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt');
foreach ($cfgFav->getSectionNames() as $sectionName) {
$section = $cfgFav->getSection($sectionName);
foreach ($section as $title => $info) {
list($count, $time, $url, $descr) = explode('|', $info);
$item = new Item($title, $descr);
$item->set(Item::LINK, $url);
$thumb = $this->cfg->get('home_url') . "services/$sectionName/logo.png";
$item->set(Item::THUMBNAIL, $thumb);
$item->set('count', (int) $count);
$item->set(Item::TIME, $time);
$channel->addItem($item);
}
}
$channel->sortItems('!' . Item::TIME, '!count', Item::TITLE);
foreach ($channel->getItems() as $item) {
$item->set(Item::TIME, $this->tools->formatTime(
$item->get(Item::TIME)));
}
return $channel;
}
public function add() {
list($title, $url, $sectionName, $descr) = $this->getAddRemoveParams();
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt', $sectionName);
if (null != $cfgFav->get($title)) {
return new Message($this->lang->msg('Error'),
$this->lang->msg('Not added to favorites') . '. ' .
$this->lang->msg('Name already exists') . ': "' . $title .'"');
}
$time = date('Y-m-d H:i:s');
$info = "0|$time|$url|$descr";
$section = $cfgFav->getSection($sectionName);
$section = array($title => $info) + $section;
$section = array_slice($section, 0, self::MAX_FAVORITES_ENTRIES);
$cfgFav->setSection($sectionName, $section);
$cfgFav->saveFile();
return new Message($this->lang->msg('Message'),
$this->lang->msg('Added to favorites') . ': "' . $title .'"');
}
public function remove() {
list($title, $url, $sectionName) = $this->getAddRemoveParams();
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt', $sectionName);
if (null == $cfgFav->get($title)) {
return new Message($this->lang->msg('Error'),
$this->lang->msg('Not removed from favorites') . '. ' .
$this->lang->msg('No such name') . ': "' . $title .'"');
}
$section = $cfgFav->getSection($sectionName);
unset($section[$title]);
$cfgFav->setSection($sectionName, $section);
$cfgFav->saveFile();
return new Message($this->lang->msg('Message'),
$this->lang->msg('Removed from favorites') . ': "' . $title .'"');
}
public function count() {
list($title, $url, $sectionName) = $this->getAddRemoveParams();
$cfgFav = new ConfigFile($this->cfg->get('cfgPath') . '/favorites.txt');
$section = $cfgFav->getSection($sectionName);
$count = 0;
if (isset($section[$title])) {
list($count, $time, $url, $descr) = explode('|', $section[$title]);
$count++;
$time = date('Y-m-d H:i:s');
$info = "$count|$time|$url|$descr";
$section = array($title => $info) + $section;
$cfgFav->setSection($sectionName, $section);
$cfgFav->saveFile();
}
$channel = new Channel($this->lang->msg('Counter'),
$this->lang->msg('Counter increased') . ": $title, $count");
$channel->set(Channel::LINK, $this->getFullUrl($url));
$channel->setSupportedTemplates('redirect');
return $channel;
}
protected function getAddRemoveParams() {
$title = $this->getRequiredParam('title');
$url = $this->getSmallUrl($this->getRequiredParam('url'));
$descr = $this->getOptionalParam('descr', '');
$pos = strpos($url, '?');
$paramStr = false === $pos ? $url : substr($url, $pos + 1);
parse_str($paramStr, $params);
if (! isset($params['srv'])) {
throw new BadRequestException(
$this->lang->msg('Cannot parse data') . ": URL, SRV");
}
$descr = str_replace(array("\r", "\n", '\"', '"'), array(' ', ' ', '″', '″'), $descr);
$descr = ParserTools::removeHtmlTags($descr);
$title = str_replace(array("\r", "\n", '\"', '"', '=', '!'), array(' ', ' ', '″', '″', ' ', '.'), $title);
$title = ParserTools::removeHtmlTags($title);
return array($title, $url, $params['srv'], $descr);
}
protected function getFullUrl($url) {
return 0 === strpos($url, 'http:') ? $url : ($this->cfg->get('home_url') . "?$url");
}
protected function getSmallUrl($url) {
$prefix = $this->cfg->get('home_url') . '?';
return 0 === strpos($url, $prefix) ? substr($url, strlen($prefix)) : $url;
}
}
?>
Это?Не уверен
-
- Продвинутый
- Сообщения: 37
- Зарегистрирован: 31 дек 2011, 14:38
- Версия: 4.2.9@Amlogic, Vontar_X3, Android 9
- Версия 2: 4.5.1@Google, android TV, Android 14
- Приставки: Xtreamer
Re: Ошибки при открытии Сервисов
<?xml version="1.0"?>
<zend-config xmlns:zf="http://framework.zend.com/xml/zend-config-xml/1.0/">
<xjbInstallationUUID>fc7fdc0945726def303d11ccd3020405</xjbInstallationUUID>
<xjbDbUUID>3f8068c5357410114b199b42add9da15</xjbDbUUID>
<setup>1</setup>
<useOnlineScraper>
<lang>en</lang>
<name>Xjb_Scraper_Online_Tmdb</name>
</useOnlineScraper>
<usePictureScraper>
<name>Xjb_Scraper_Picture_Tmdb</name>
</usePictureScraper>
<movieOverview>
<lastPage>1</lastPage>
<sortBy>name</sortBy>
<sortMode>asc</sortMode>
<numberItemsPerPage>50</numberItemsPerPage>
<hideArtwork>0</hideArtwork>
</movieOverview>
<defaultMovieViewList>viewMovieList</defaultMovieViewList>
<useOnlineScraperOnFilesystemScan>1</useOnlineScraperOnFilesystemScan>
<filesystemScanUseAlwaysFolderNames>0
<zend-config xmlns:zf="http://framework.zend.com/xml/zend-config-xml/1.0/">
<xjbInstallationUUID>fc7fdc0945726def303d11ccd3020405</xjbInstallationUUID>
<xjbDbUUID>3f8068c5357410114b199b42add9da15</xjbDbUUID>
<setup>1</setup>
<useOnlineScraper>
<lang>en</lang>
<name>Xjb_Scraper_Online_Tmdb</name>
</useOnlineScraper>
<usePictureScraper>
<name>Xjb_Scraper_Picture_Tmdb</name>
</usePictureScraper>
<movieOverview>
<lastPage>1</lastPage>
<sortBy>name</sortBy>
<sortMode>asc</sortMode>
<numberItemsPerPage>50</numberItemsPerPage>
<hideArtwork>0</hideArtwork>
</movieOverview>
<defaultMovieViewList>viewMovieList</defaultMovieViewList>
<useOnlineScraperOnFilesystemScan>1</useOnlineScraperOnFilesystemScan>
<filesystemScanUseAlwaysFolderNames>0
-
- Продвинутый
- Сообщения: 37
- Зарегистрирован: 31 дек 2011, 14:38
- Версия: 4.2.9@Amlogic, Vontar_X3, Android 9
- Версия 2: 4.5.1@Google, android TV, Android 14
- Приставки: Xtreamer
Re: Ошибки при открытии Сервисов
[Default]
lang = "ru"
timezone = "America/Juneau"
marginX = "2"
marginY = "2"
lang = "ru"
timezone = "America/Juneau"
marginX = "2"
marginY = "2"
-
- Продвинутый
- Сообщения: 37
- Зарегистрирован: 31 дек 2011, 14:38
- Версия: 4.2.9@Amlogic, Vontar_X3, Android 9
- Версия 2: 4.5.1@Google, android TV, Android 14
- Приставки: Xtreamer
Re: Ошибки при открытии Сервисов
[Default]
lang = "ru"
timezone = "America/Juneau"
marginX = "2"
marginY = "2"
lang = "ru"
timezone = "America/Juneau"
marginX = "2"
marginY = "2"
- agent_wowa
- ГлавТВ
- Сообщения: 1520
- Зарегистрирован: 01 фев 2011, 15:49
- Версия: 4.5.3b1@Amazon, AFTR, Android 9
- Версия 2: 4.5.4@Amazon, AFTMM, Android 7.1.2
- Приставки: Xtreamer Prodigy, iNeXT HD1, Egreat R6S, Measy X5, DM800HD
- Конец дружбы: 31.03.2021
Re: Ошибки при открытии Сервисов
Не то, содержимое файла favorites.txt, каторый лежит тут >>> GlavTV/cfg/favorites.txt
-
- Продвинутый
- Сообщения: 37
- Зарегистрирован: 31 дек 2011, 14:38
- Версия: 4.2.9@Amlogic, Vontar_X3, Android 9
- Версия 2: 4.5.1@Google, android TV, Android 14
- Приставки: Xtreamer
Re: Ошибки при открытии Сервисов
<?xml version="1.0"?>
<zend-config xmlns:zf="http://framework.zend.com/xml/zend-config-xml/1.0/">
<xjbInstallationUUID>fc7fdc0945726def303d11ccd3020405</xjbInstallationUUID>
<xjbDbUUID>3f8068c5357410114b199b42add9da15</xjbDbUUID>
<setup>1</setup>
<useOnlineScraper>
<lang>en</lang>
<name>Xjb_Scraper_Online_Tmdb</name>
</useOnlineScraper>
<usePictureScraper>
<name>Xjb_Scraper_Picture_Tmdb</name>
</usePictureScraper>
<movieOverview>
<lastPage>1</lastPage>
<sortBy>name</sortBy>
<sortMode>asc</sortMode>
<numberItemsPerPage>50</numberItemsPerPage>
<hideArtwork>0</hideArtwork>
</movieOverview>
<defaultMovieViewList>viewMovieList</defaultMovieViewList>
<useOnlineScraperOnFilesystemScan>1</useOnlineScraperOnFilesystemScan>
<filesystemScanUseAlwaysFolderNames>0
<zend-config xmlns:zf="http://framework.zend.com/xml/zend-config-xml/1.0/">
<xjbInstallationUUID>fc7fdc0945726def303d11ccd3020405</xjbInstallationUUID>
<xjbDbUUID>3f8068c5357410114b199b42add9da15</xjbDbUUID>
<setup>1</setup>
<useOnlineScraper>
<lang>en</lang>
<name>Xjb_Scraper_Online_Tmdb</name>
</useOnlineScraper>
<usePictureScraper>
<name>Xjb_Scraper_Picture_Tmdb</name>
</usePictureScraper>
<movieOverview>
<lastPage>1</lastPage>
<sortBy>name</sortBy>
<sortMode>asc</sortMode>
<numberItemsPerPage>50</numberItemsPerPage>
<hideArtwork>0</hideArtwork>
</movieOverview>
<defaultMovieViewList>viewMovieList</defaultMovieViewList>
<useOnlineScraperOnFilesystemScan>1</useOnlineScraperOnFilesystemScan>
<filesystemScanUseAlwaysFolderNames>0