bookin / kinopoisk-parser
kinopoisk Parser
Installs: 61
Dependents: 0
Suggesters: 0
Security: 0
Stars: 4
Watchers: 3
Forks: 0
Open Issues: 0
Language:JavaScript
Requires
- php: >=5.4.0
This package is not auto-updated.
Last update: 2024-11-10 04:27:41 UTC
README
Configuring a server
Install nodejs from nvm:
sudo apt-get update
sudo apt-get install build-essential libssl-dev
curl -sL https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh -o install_nvm.sh
bash install_nvm.sh
source ~/.profile
nvm install node
nvm use node
Install Google Chrome:
sudo apt-get install google-chrome-stable
If you will use library in the PHP with composer, need install composer:
curl -sS https://getcomposer.org/installer | sudo php -- --install-dir=/usr/local/bin --filename=composer
Installation
NodeJs
TODO...
PHP
To install, either run
$ php composer.phar require bookin/kinopoisk-parser "@dev"
or add
"bookin/kinopoisk-parser": "@dev"
to the require
section of your composer.json
file.
Usage
Manual command:
parser.js https://www.kinopoisk.ru/film/telokhranitel-killera-2017-835877/
PHP class:
Kinopoisk::parseByUrl('https://www.kinopoisk.ru/film/telokhranitel-killera-2017-835877/')
Returns object:
{
'id' : '',
'name' : '',
'original_name' : '',
'description' : '',
'image' : {
'preview' : '',
'original' : '',
},
'trailer' : '',
'rating' : {
'mark' : '',
'count' : '',
},
'info' : {
'year':'',
'countries':['','',...],
'slogan':'',
'directors':[
{
'id':'',
'url':'',
'name':''
},
...
],
'scenario':[{},...],
'producer':[{},...],
'operator':[{},...],
'composer':[{},...],
'painter':[{},...],
'mounting':[{},...],
'genre':[{},...],
'premiere_world':'',
'premiere_rus':'',
'premiere_ua':'',
'age':'',
'time':{
'minutes':'',
'hours':''
}
},
'actors' : [{},...]
}