Kodi Community Forum

Full Version: MediaFrontPage - Web interface with widget type architecture to control multiple apps
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Two things aren't working for me and I'm not sure why:
1-on the RSS widget, I have a drop-down selector for the various feeds but that's the only thing that works in this widget, its totally non-functional Sad
2-I noticed on most screenshots I have seen, people have little Edit buttons and X buttons on each widget's title bar. I don't have that stuff and also don't have the fancypants drag & drop functionality. Is this a function of my layout.php? How would I get such good stuff?
SleepyP Wrote:Two things aren't working for me and I'm not sure why:
1-on the RSS widget, I have a drop-down selector for the various feeds but that's the only thing that works in this widget, its totally non-functional Sad
2-I noticed on most screenshots I have seen, people have little Edit buttons and X buttons on each widget's title bar. I don't have that stuff and also don't have the fancypants drag & drop functionality. Is this a function of my layout.php? How would I get such good stuff?

This should be default! Did you make sure to rename default-layout to layout? Also check your permissions(755 or 777) since if they're wrong it will not save your reconfigured layout

@Deja -- Just noticed the shadow! Great addition, so cool!
Wait so should I be able to move / edit the widgets by default? Or is that NOT supposed to be available?
Just to be sure, I pulled default-layout.php from https://github.com/gugahoi/mediafrontpage, renamed it to layout.php, put it in my MFP directory and chmodded it to 777 permissions.

Here are the contents of my layout.php:
Code:
<?php
$arrLayout = array(
        "section1" => array(
            "wRecentTV" => array(
                "title" => "Recent TV",
                "display" => ""
            ),
            "wSabnzbd" => array(
                "title" => "Sabnzbd",
                "display" => ""
            ),
            "wXBMCLibrary" => array(
                "title" => "XBMC Library",
                "display" => ""
            ),
            "wControl" => array(
                "title" => "Control",
                "display" => ""
            ),
            "wNowPlaying" => array(
                "title" => "Now Playing",
                "display" => ""
            )
        ),
        "section2" => array(
            "wSearch" => array(
                "title" => "Search",
                "display" => ""
            ),
            "wComingEpisodes" => array(
                "title" => "Coming Episodes",
                "display" => ""
            ),
            "wuTorrent" => array(
                "title" => "uTorrent",
                "display" => ""
            )
        ),
        "section3" => array(
            "wRecentMovies" => array(
                "title" => "Recent Movies",
                "display" => ""
            ),
            "wTransmission" => array(
                "title" => "Transmission",
                "display" => ""
            ),
            "wHardDrives" => array(
                "title" => "Hard Drives",
                "display" => ""
            ),
            "wRSS" => array(
                "title" => "RSS Feed",
                "display" => ""
            )
        )
    );
/*
            "wExample" => array(
                "title" => "Example Widget",
                "display" => ""
            )
*/
?>
Layout.php is not responsible for the widget type architecture, but I find that every now and then, when permissions magically change, it prevents me from saving my layout. The widget architecture is done through jQuery I believe, and it usually breaks when there's a problem on one of the widgets.

Are you using the last version from the repo? Could also be from the modifications you made on the json stuff.
Hernandito and DejaVu, I think I fixed the submenu problem!! Could you test it out and let me know?
SleepyP Wrote:Two things aren't working for me and I'm not sure why:
1-on the RSS widget, I have a drop-down selector for the various feeds but that's the only thing that works in this widget, its totally non-functional Sad
2-I noticed on most screenshots I have seen, people have little Edit buttons and X buttons on each widget's title bar. I don't have that stuff and also don't have the fancypants drag & drop functionality. Is this a function of my layout.php? How would I get such good stuff?

1. Sounds like an issue with javascript in your browser. You browser giving any error messages? Have you tried with different browsers? can you access the rss feeds manually?

2. Sounds again like an issue with javascript/jquery. This should all work out of the box even if widgets have errors. Again try a different browser and report your results. Otherwise maybe make sure you have all the files and they are upto date. Not having the edit/X is a clear sign of a problem. widget.js/widget.css is responsible for this from memory but sounds like something wrong with your files.


Thanks for updating the jsonrpc calls.
Hmm... I just noticed that the sab widget doesn't actually work when sab is using ssl. Not that it really matters though.
DPickles Wrote:Hmm... I just noticed that the sab widget doesn't actually work when sab is using ssl. Not that it really matters though.

What do you get? Errors galore or nothing at all?
gugahoi Wrote:Hernandito and DejaVu, I think I fixed the submenu problem!! Could you test it out and let me know?

Thank you Guga... it works really good!

A couple of minor things I edited...

The bottom subnav bar was too tall. Without really understanding the code, just trial and error, on index.php, I changed the line below:
Code:
<frameset rows="<?php echo ($submenu)?"9%":"5%";?>, *" frameborder="0" border="0" framespacing="0">

to:

Code:
<frameset rows="<?php echo ($submenu)?"6%":"5%";?>, *" frameborder="0" border="0" framespacing="0">

I also noticed that in nav.php you had the bottom subnav drop-down list code disabled by /*. I removed the /* */ to enable it. I don't think I will use it, but it may help others.

I like the shadow around the widgets. Where is that set?
hernandito Wrote:Thank you Guga... it works really good!

A couple of minor things I edited...

The bottom subnav bar was too tall. Without really understanding the code, just trial and error, on index.php, I changed the line below:

That's the correct place. In both chrome and FF it looked OK but I'll give it a try with 6%.
Quote:I also noticed that in nav.php you had the bottom subnav drop-down list code disabled by /*. I removed the /* */ to enable it. I don't think I will use it, but it may help others.
It's disabled because it looks weird with it, so I thought I'd find an alternative first.

Quote:I like the shadow around the widgets. Where is that set?

Widget css... look in #main .section .widget for this

Code:
-moz-box-shadow: 3px 3px 3px 0px #000;
-webkit-box-shadow: 3px 3px 3px 0px #000;
box-shadow: 3px 3px 3px 0px #000;

I played around with it too but found the values DejaVu picked to be pretty good.


Have you got any modifications you want on git? Maybe your lighttheme... Or are they not ready yet?
gugahoi Wrote:What do you get? Errors galore or nothing at all?

Nothing at all. I'll just run sab normally as the widget works fine this way. I can't believe I only just noticed this to be honest Big Grin
SleepyP Wrote:I updated xbmcjsonlib.php so that it works with the new JSON-RPC 2.0 interface that's in the nightly builds of XBMC. So far I have only updated the video library methods so that all the XBMC library widgets are working now.

One problem: seemingly at random, when I click stuff in the widgets I am getting a password prompt. I have the username / password set in my config.php, so I'm not sure what's up with that.

Also, I haven't done any work on making xbmcjsonlib.php be backward compatible with the 10.1 stable release of XBMC. Maybe tomorrow? I dunno where I should stash the file.
-EDIT-

zipped and uploaded HERE

Can anybody test this out and see if you are getting password prompts? It seems like it's doing it when it tries to load thumbnails, but I'm honestly not too sure.
I can confirm this works perfectly with the Video Library widgets in the nightlys. I do not use passwords for XBMC, so I do not get the moaning pop asking for it.

Thanks for fixing that. Smile
I'm getting a bit lost and confused myself now though. I'm on the nightlies, meaning there are now 2 versions of the file above for MFP (the option to choose in config.php).

I really like my git master, but it's different from Gugahoi in the way that the IMDB branch needs adding to it.

What we need is a Repo that's public/final as well as the one that dev's are working on.
So I decided to open a new Github with my master in it and it awaits the IMDB branch to be merged to it - I dunno how. Smile

I've opened a new central Repo for MediaFrontPage where it can have edits merged with it from different users forks.

Find it at - https://github.com/MediaFrontPage/mediafrontpage

I've sent all details to the collaborators in here (including the Gmail password for the email account).

If you want adding to the list, please PM me.

So far, added are.

Nick8888
Gugahoi
DejaVu77
gugahoi Wrote:Have you got any modifications you want on git? Maybe your lighttheme... Or are they not ready yet?

I am still trying to make all the minor changes that I did originally... its like learning to walk all over again.
Nick8888 Wrote:1. Sounds like an issue with javascript in your browser. You browser giving any error messages? Have you tried with different browsers? can you access the rss feeds manually?

2. Sounds again like an issue with javascript/jquery. This should all work out of the box even if widgets have errors. Again try a different browser and report your results. Otherwise maybe make sure you have all the files and they are upto date. Not having the edit/X is a clear sign of a problem. widget.js/widget.css is responsible for this from memory but sounds like something wrong with your files.


Thanks for updating the jsonrpc calls.

Just to isolate, I pulled a "fresh" copy of MFP from Gugahoi's github repository. I stuck this in an empty folder on my server. Then I did chown apache:apache -R ./* in that folder and chmod 777 -R ./* in that folder to make apache own everything there with full read/write access. I confirmed this in the file properties on a few files. Then I renamed default-config.php and default-layout.php to config.php and layout.php respectively.

This did nothing to resolve the issues with the editable layout and RSS feed widget, they both still do not work. Further, MFP has always looked this way in my experience, having viewed it from Firefox 3.6, Firefox 4, Opera 11, Chrome 11, and Safari 5 across Windows 7, Mac OS X, and Fedora 14. The only common thing is the server in question.

Since I have already ruled out permissions, modified files, and the browser as the source of the problem, is there something on the server side which is required to make that stuff work? I have looked at Firefox's Error Console, but its not very helpful, mostly some style-related errors and others, all attributed to the Coming Episodes widget.

Here's what my stuff looks like:
Image

Also, I will be updating the rest of the XBMC JSON-RPC calls, since there are still a bunch that need fixing (mostly the audio player stuff). It's been kinda busy at work, and I've been pre-occupied with troubleshooting the Jquery stuff.

-EDIT-
I think it may be my server's MIME settings, for how its handling .js files. This would explain why all the PHP files are working right, but the js stuff simply doesn't execute at all. Will research and report back.