“hStation Media” Documentation by “ZpVs” v1.1


“hStation Media”

Created: 21/03/2014
Last Update: 26/04/2014
By: HM:SCRIPT
Email: support@hmscript.net Skype: abuss.solod

«hStation Media» - system with extremely simple controls for video broadcasting and IPTV, and the latest versions and broadcasts torrent . Flexible configuration and modules gives truly unlimited possibilities in creating your own website for internet television broadcast . Control modules viewing access , accept payment through payment gateways , generate playlists for consoles and home media centers , take suggestions and objections through the modules support. Freedom of choice in the provision of broadcast TV is the main task of «hStation Media».


Please Rate hStation Media
Please remember to rate this script! To do so, Please go to your Downloads page and click on the star rating in front of this script! Thanks!

Documentation contents

  1. Quick Setup Script
  2. Configuration after installation
  3. Adding Media
  4. Structure of a script
  5. Loading workflow script
  6. Engine variables for later use
  7. Templates system
  8. Templates short codes
  9. Version and Updates

A) Quick Setup Script - top

Brief instructions for installing the script, which is simplified and is of itself a minimum number of steps.

Step 1
Download and unzip the script available for you to place on the disk.
Step 2
Create a database for hStation Media on your web server, as well as a MySQL user who has all privileges for accessing and modifying it.
Step 3
Upload the hStation Media files to the desired location on your web server
Step 4
Run the hStation Media installation by accessing the URL in a web browser.(http://example.com/)
Step 5
Confirm the installation script. That's all.

B) Configuration after installation - top

After installing the script, we strongly recommend you to avoid problems with the performance and further work correctly. To configure you must login with the credentials that you specified during the installation script, and go to the panel profile.

and go to the Control Panel

Select the menu Options and make a section Common primary basic settings of the site.


To configure accepting payments online, go to Billing and fill in the details.

Payments are accepted using the gateway interkassa and to obtain the necessary data you need to register on the site http://interkassa.com

Configuring authorization through social networks:

Authorization for use through social networks you must click on the links listed below and register your application. When you register you get a client id and secret key, as well you will be able to provide return url. For every social network uses its own unique url to return.


Application for registration Vkontakte visit this page: Vkontakte APPredirect_uri = http://yousite.com/?auth&login&vk_auth

Application for registration Facebook visit this page: Facebook developers redirect_uri = http://yousite.com/?auth&login&fb_auth

Application for registration Google visit this page: Google API redirect_uri = http://yousite.com/?auth&login&gl_auth

After obtaining the necessary data, make them in the appropriate fields in the settings and activate the login authentication method.


C) Adding Media - top

When you specify that the media is Youtube media, if allowed, setting the http link to link Youtube or Vimeo but canceled the possibility to use the remote control playback.


hStation Media when viewing video content through the built-in player allows you to activate the opportunity to control the viewing via smartphones, tablets and other portable devices.

To activate the profile management should enable remote control and open the desired video. Then with the device, which will be provided by management should visit the URL http://example.com/?pult and you can use this feature.


D) Structure of a script - top

The structure of the files of the script, as well as the use of specification files at work or further study.

/core/
Backend - the control part
/configs/
Kernel configuration upload / db / access
[a-z]*.cfg.php
Configuration files
/control/
Manage script (control panel)
/additions/
File additional of the kernel functions
/kernel/
Kernel boot script
[a-z]*.php
Core files core classes
/engine/
Handlers kernel boot
/language/
Localization files script
/service/
Different files additions to service script
[a-z]*.inc.php
Files processing user queries
/content/
Frontend - displaying part
/scripts/
Predefined javascript files
/uploads/
Folder download various files by the user
/themes/
Templates
/hs-init.php
Initialization file and download all the required classes and variables for further work. Basic load file.
/index.php
Index file.
/hs-path.php
Definition file paths connect files.

E) Loading workflow script - top

Check and connect the path file

require_once __DIR__  . '/hs-path.php';

Connecting to initialize the class loader and add kernel namespace

require_once __DIR__  . '/core/kernel/HmClassLoader.php';
$loader = new \Core\Kernel\HmClassLoader;
$loader->register();
$loader->addNamespace('Core\Kernel', __DIR__.'/core/kernel');
        

Check and connect the configuration file for the working site

require_once( ABSPATH.'core/configs/kernel.cfg.php' );

Connect the configuration files

__include_kernel_configs(CONF);

Initialization core builder

$builder = new  \Core\Kernel\HmsBuilder;

Loading core system connecting all the necessary extensions

$core = $builder->compileKernel();

Initialize the data processing tools kernel

$core::$engine->initEngineHandler();

Initialize and draw the site template

$core::$template->initTheme();

F) Engine variables for later use - top

Variables responsible for the correct handling of requests from users and the correct operation of the script as a whole. Manipulation of these variables whenever a script can completely change the vector load or stop it completely.

        protected $load = true;                  /* Is it allowed loading tools kernel */
        public $handler = null;                  /* Basic handler Tools kernel */
        public $query_post = false;              /* Were there POST requests - by default does not come */
        public $a_post = array();                /* Array incoming POST requests - empty by default */
        public $a_post_index = array();          /* Array incoming POST requests data - empty by default */
        public $query_get = false;               /* Were there GET requests - by default do not come */
        public $a_get = array();                 /* Array incoming GET requests - empty by default */
        public $a_get_index = array();           /* Array incoming GET requests data - empty by default */
        

The main files that perform data manipulation variables are files in the folder /engine/ and having the name [a-z]*.inc.php, where [a-z]* is the name of the first $ _GET request. Where priority has primary rights file global.inc.php, and only then the other files.

Example:
When requesting http://example.com/?foo - global.inc.php control is passed and if allowed in this file further work that control will be passed foo.inc.php if available in the folder.


G) Templates system - top

To enable a quick change display to the user system is implemented templates. By default, the system loads the templating 3 main files from the folder /themes/name-template/, namely header.html, index.html, footer.html and they are responsible for the initial display of a site. In all the template files used only language HTML, php code will not execute.

Manipulating display pattern is made of managed files [a-z]*.inc.php folder /engine/, and allows , depending on the incoming requests and outgoing traffic display different patterns . To override the base 3 files need to change the control file template file call .

            $core::$template->parts[header]['file']
            $core::$template->parts['body']['file']
            $core::$template->parts[footer]['file']
        

Any output of dynamic information in the template is only through special short codes which are below.


H) Templates short codes - top

Types of short codes
{:[a-z]:}
Short code used to display data from different page templates to plain text.
{txt:[a-z]:}
Short code used to display the text localization.
{code:[a-z]:}
Short code used to execute arbitrary code php.

To define the data that needs to be replaced in the short code must file [a-z]*.inc.php folder /engine/ to determine in advance the necessary replacement tag by passing a value to the variable $core::$template->tags[[a-z]*]

Example

To replace short code {:foo:} with bar

$core::$template->tags['foo'] = 'bar';

In order to dynamically change the display information in this script uses short codes that allow the localization show the necessary data or execute arbitrary code php.


I) Version and Updates - top

Version 1.1
Added authorization system through social networks.
Added commenting system.
In the categories of media buttons added sorting media.
Fixed adding media options Youtube and Vimeo, you can now specify a link.
Added the possibility to compress code.
Made minor corrections and changes to improve the script.

Sources and Credits - top

If you have any questions about this player or you want to supplement or change some details, I will be glad if you contact because the product is not perfect and there is always something to add or modify.

ZpVs

Go to Documentation contents