Kodi Community Forum
MediaFrontPage - Web interface with widget type architecture to control multiple apps - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Supplementary Tools for Kodi (https://forum.kodi.tv/forumdisplay.php?fid=116)
+--- Thread: MediaFrontPage - Web interface with widget type architecture to control multiple apps (/showthread.php?tid=83304)



- Nick8888 - 2011-08-20

Could someone please explain the donation button? I couldn't find any discussion on this. Mainly which paypal account it is linked to and what the donations will be used for?


- lunias - 2011-08-20

I have my XBMC IP set to its internal address: 192.168.1.3 (I haven't bothered making this static yet, but I haven't turned the ATV off so it hasn't changed).

The port is correct too. I can pull data to populate the Recent Movies / Shows widgets. The web-interface works as well (It loses connection sometimes... I think the nowPlaying widget might be hammering the connection with its updates?)

Could it be a problem related to running XBMC on ATV2? I'm using a nightly build from a week ago or so too...

I'm going to keep looking into it.

lunias


- mdaddy - 2011-08-20

First time user, loving it....

2 questions...

1) How do I re-add widgets I've deleted? I can't seem to find a way to "Add Widget" from the library of widgets.

2) I have 2 XBMC instances (neither are on the webserver) -- how can I make 2 "Now Playing" widgets that each speak to a specific XBMC instance? (I'm able to point it at only one currently)

Thanks!


- _Mikie_ - 2011-08-20

mdaddy Wrote:First time user, loving it....

2 questions...

1) How do I re-add widgets I've deleted? I can't seem to find a way to "Add Widget" from the library of widgets.

2) I have 2 XBMC instances (neither are on the webserver) -- how can I make 2 "Now Playing" widgets that each speak to a specific XBMC instance? (I'm able to point it at only one currently)

Thanks!

1. Hi there. Currently to reaad widgets you have to open layout.php and manually add them. The names of the widgets follow the names of the widgets in the folder widgets. I have a solution that gives the option of on/off that will hopefully be added soon.

2. This is a bit more tricky but simple enough. If you open the widget folder and find the Now Playing widget and then copy it. Then paste is back into the folder and rename it to wNowPlaying2. Then edit the file and wherever it says wNowPlaying rename that to wNowPlaying2. Then open layout.php and add wNowPlaying2 and it should work. The reason for having to rename them is only one instance of a widget can be declared at once as far as I'm aware. There may be a simpler way though and someone will multiple xmbc instances might know something better but that's what I'd say off the top of my head.

Maybe we can integrate an option to target multiple machines in the future?


- _Mikie_ - 2011-08-20

For those who want basic Javascript lessons in a fun way http://www.codecademy.com


- Archigos - 2011-08-20

Ignore this post... it was about the secondary "Now Playing" but as I'm finding out there's a LOT more to it then the simple edit, so I'll fix this once I get all the info together.


- Archigos - 2011-08-20

gugahoi, Deja, etc.

I'm sure you've seen this by now, but ACE may be beneficial pending on your coding style.

Side Note (not that anyone cares): I dumped my current repo and going to grab from the official again shortly before getting back to attempting the iPad specific mobile interface.
Last Note: If I remember correctly, I showed a special image gallery (written in PHP) to guga (maybe Deja) awhile back and wondered if I supplied the source (possibly via GitHub repo) that something may be incorporated into MFC at some point in the future.


- mdaddy - 2011-08-20

_Mikie_ Wrote:1. Hi there. Currently to reaad widgets you have to open layout.php and manually add them. The names of the widgets follow the names of the widgets in the folder widgets. I have a solution that gives the option of on/off that will hopefully be added soon.

2. This is a bit more tricky but simple enough. If you open the widget folder and find the Now Playing widget and then copy it. Then paste is back into the folder and rename it to wNowPlaying2. Then edit the file and wherever it says wNowPlaying rename that to wNowPlaying2. Then open layout.php and add wNowPlaying2 and it should work. The reason for having to rename them is only one instance of a widget can be declared at once as far as I'm aware. There may be a simpler way though and someone will multiple XBMC instances might know something better but that's what I'd say off the top of my head.

Maybe we can integrate an option to target multiple machines in the future?

Thanks Mike! This is exactly what I was looking for. I suspect in #2 I will have to do some extra plumbing to make wNowPlaying2 talk to a *different* xbmc instance than what is set in the master config.


- Aenima99x - 2011-08-20

Nick8888 Wrote:Could someone please explain the donation button? I couldn't find any discussion on this. Mainly which paypal account it is linked to and what the donations will be used for?

It shows that the PayPal acct is - [email protected]


- _Mikie_ - 2011-08-20

mdaddy Wrote:Thanks Mike! This is exactly what I was looking for. I suspect in #2 I will have to do some extra plumbing to make wNowPlaying2 talk to a *different* xbmc instance than what is set in the master config.

O ya variables, forgot about those! You'll have to also rename all the variables that it uses (IP,PORT,USER,PASS) and then add those into config.php. Good luck! If you get stuck let me know and I'll give you a hand Smile


- Archigos - 2011-08-20

It's pretty involved, was going to do the edits for him, but the amount that needs to be done should probably be handled in repo as one missed variable or one wrong move norms the entire site. I'll send my notes to Deja when I get home from the hospital.


- mdaddy - 2011-08-20

Archigos Wrote:It's pretty involved, was going to do the edits for him, but the amount that needs to be done should probably be handled in repo as one missed variable or one wrong move norms the entire site. I'll send my notes to Deja when I get home from the hospital.

I'm pretty good with PHP, I'm sure I'll get it working... My concern is around merging with newer versions down the road Sad


- DejaVu - 2011-08-20

I use Dreamweaver to change site wide edits to certain parts. Wink

Makes life a lot easier instead of trying to dig out everything.


- Archigos - 2011-08-20

mdaddy Wrote:I'm pretty good with PHP, I'm sure I'll get it working... My concern is around merging with newer versions down the road Sad

If you want to attempt it, you need to edit the new wNowPlaying2.php obviously as well as layout.php, config.php, config.ini (possibly others).

For wNowPlaying2.php do the changes as mentioned earlier (think it was only 3 or 4 spots).

For layout.php just duplicate the original wNowPlaying and rename the new one ("wNowPlaying2").

For config.php and config.ini check for any variables that starts with $xbmc (like $XBMC_IP; $XBMC_PORT; etc.) and duplicate those ($XBMC2_IP; $XBMC2_PORT; etc.) Don't forget $xbmcjsonservice and ones like that.

Warning: While attempting this on my local copy (I didn't finish the edits) but somewhere it did bork my install. (iPhone auto-correct made 'bork' into 'norms' last post) Sad

If you get it working and found other files that are in need of edit, let us know.


- _Mikie_ - 2011-08-20

Personally instead of going through all the hassle of editing configs and ini's and because you don't know exactly what everything links to rather just hard code the values into the widget and then when you update your install just back up a copy of your layout and that widget. I haven't looked at the widget though so I don't know how much work it entails. I'll look at it later next week and maybe make a branch with it in so you can just download it from there with everything in place