-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathPluginGostream.class.php
More file actions
58 lines (50 loc) · 1.46 KB
/
PluginGostream.class.php
File metadata and controls
58 lines (50 loc) · 1.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<?php
/*-------------------------------------------------------
*
* Project name: LSP-GoStream
* Official site: goweb.pro
* Contact e-mail: gowebpro@ya.ru
*
* GNU General Public License, version 2:
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
*
---------------------------------------------------------
*/
if (!class_exists('Plugin')) {
die('Hacking attemp!');
}
class PluginGostream extends Plugin
{
protected $aInherits = array(
'action' => array(
'ActionAjax'
),
'module' => array(
'ModuleViewer'
)
);
public function Init()
{
$this->Viewer_AppendScript(self::GetAssetsPath() . 'js/main.js');
$this->Viewer_AppendStyle(self::GetAssetsPath() . 'css/main.css');
$this->Viewer_AppendStyle(Plugin::GetTemplatePath(__CLASS__) . 'css/main.css');
}
/**
* Возвращает правильный серверный путь к директории ассетов плагина
*
* @return string
*/
public static function GetAssetsPath()
{
return Plugin::GetPath(__CLASS__) . 'frontend/assets/';
}
/**
* Возвращает правильный серверный путь к директории базовых шаблонов плагина
*
* @return string
*/
public static function GetFrontendPath()
{
return Plugin::GetPath(__CLASS__) . 'frontend/templates/';
}
}