Release - Now Playing - (Displays what you're playing in Kodi on your web site!)

  Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Photo  Now Playing - (Displays what you're playing in Kodi on your web site!)
Post: #1
http://projects.lanik.org/KodiProject_NowPlaying.htm

Kodi Now Playing plugin


This is a KODI plugin I wrote for myself but I thought it might be useful to somebody else, so here it is.

On my old HTPC (Xlobby), I had a script that displayed what was playing on my web page. So when my HTPC died and I switched to KODI, I tried doing the same. Here is the result Smile This probably won't be interesting to many people, but I had this idea that my web pages would display what was playing on my HTPC. So the way I did it (since I couln't allow some script inside my LAN) is to monitor what was playing and create XML file, which then I would send via FTP to my web-server and render it on a web-page to display the "Now Playing" info.

Here is what it looks like (probably now won't be playing anything) Smile : Lanik.org Now Playing

And this is what this plugin does. It monitors what is playing, creates XML file, uploads it to chosen FTP server, to a chosen FTP folder (along with the coverart, if it can't be linked from the web), and then there's web page part in JavaScript, which reads XML file and displays the info on the HTML page.

Since there could be a content that is not for "advertizing", I also made it possible to exclude certain plugins, i.e. Whitecream and what have you. So I took advantage of the "PinSentry" plugin. If you don't want something you're watching to show online, you'd probably want it pin-protected localy as well Smile So my plugin supports pin-sentry on the level of plugins. It reads PinSentry database and gets locked plugins. If something is locked in PinSentry, it won't show on "Now Playing". Ofcourse, you can trun this option on/off.

HTML/Javascript example included.

In order to install it, first install my REPO: Lanik Repo

Then install add-on, and configure it.

This should work on all platforms. Any comments wellcome. Please don't be harsh, this is my first add on, and my first in Python Smile

D.

[Image: kodiplugin_nowplaying.jpg]




[Image: donate_button_1.png]
(This post was last modified: 2017-02-01 15:19 by DaLanik.)
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #2
v1.4
- Code cleanup
- Added Serbian, Serbian Cyrillic and Czech translations
find quote
Atreyu Offline
Donor
Posts: 935
Joined: Sep 2015
Reputation: 22
Post: #3
Hi Dalibor,

I am surprised by the lack of responses.
This seems like a very neat little addon, so thanks for sharing!
(This post was last modified: 2016-07-20 23:38 by Atreyu.)
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #4
Thanx, glad someone finds it interesting Smile

BTW updated to new version:

v1.6
- Better debugging

v1.5
- Coding error fixed

Available in repository
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #5
v1.7
- Code cleanup
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #6
v1.8
- Strings read from language files
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #7
v1.9
- Removed excess logging
- new php example for server side processing
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #8
If you like this add on, please like the Faceook page: Now Playing
find quote
Ruckus Offline
Member
Posts: 63
Joined: Oct 2012
Reputation: 1
Location: Costa Rica
Post: #9
works really well. but where is the html/javascript?
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #10
it is in the folder "html_demo" in the plugin folder, so in kodi folder it is /addons/service.kodi.visualnowplaying/html_demo. There are both html/javascript and php examples.
find quote
Ruckus Offline
Member
Posts: 63
Joined: Oct 2012
Reputation: 1
Location: Costa Rica
Post: #11
ahh ok didnt look in there, got 'em thanks!
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #12
v2.0
- Re read settings on change, icon now visible under programs (opens settings)
find quote
Ruckus Offline
Member
Posts: 63
Joined: Oct 2012
Reputation: 1
Location: Costa Rica
Post: #13
great stuff, thanks for this addon.

As well as the regular usage for it, i'm also using it to see if kodi is idle before turning my lights off at night, so if i'm still up and watching something then it'll leave my lights running (as i also use them for amblights for kodi)

thanks again!
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #14
v2.1
- fix for log when FTP fails
find quote
DaLanik Online
Fan
Posts: 724
Joined: Apr 2016
Reputation: 30
Location: Prague, CZ
Post: #15
v2.2
- On/Off switch
- Code cleanup
find quote
Post Reply