Self Contained Web Server / Interface (1 Viewer)

risu

MP Donator
  • Premium Supporter
  • September 22, 2006
    279
    19
    Home Country
    Finland Finland
    I originally did not include the MP logo into the html templates as I thought it would be a bit pretentious for my little project. But I really like the look of what you are working on, so If the MP gurus don't mind, we could look at re-designing the non-PDA html template pages that are included in the install.
    Forgot to add on code but my idea of layout would also add a heading on the middle of the topbar (where's mediaportalwebinterface-text) so you'd know what page you are looking at (Scheduled programs, TV-server status etc) and username would be on the right. Same topbar offcourse would be on all pages and no separate mainmenu at all.

    The custom HTML is placed into a detail cell in the main program guide table. So creating a table in the cell should make it space correctly.
    Kev
    Actually it doesn't work. I know using <table> tag inside table's <td> cell SHOULD work as you described but what it actually does is it makes every channel display 100% screen width and program entries are placed next to other on same column until row ends and then they get to next row. I'm could maybe could tweak style.css somehow to display this stuff right, it's just that I'm not that familiar with css and I've done only little of this kind of work.

    Main problem is, that using custom HTML cell on management-program, program entries get automatically separated with <td>!!!data!!!</td> not <tr><td>!!!data!!!</td></tr> like on default setting (when there's nothing on custom detail cells).

    I know the code I posted isn't correct due it hasn't got <table> tag inside <td> cells, so it's not standard html because it breaks the syntax but it's so far only way I could set it even close what I'm after.

    To sum this up, problem is that there's <tr> missing before <td> when using custom html program entry. And same </tr> missing after </td>. I don't know how this is with other layouts as I'm only after vertical view. Also it's impossible to get current program on bolded for me as I think it's hardcoded to !!!showid!!! and I can only use !!!progid!!!. There's no "simple" way to get over it.. other than if you made !!!showid!!!-value customizable. But that's more work again. That way you could easily add javascript to links though.
     

    Big_Kev

    Portal Pro
    June 8, 2007
    338
    186
    Home Country
    Great progress on this, a couple of points/questions ...


    2. I have channels which have been scanned but not selected in MP, whilst these are not shown in MP they are shown in the guide - with empty data as I do not collect EPG for them. Can such channels be ignored by the web interface?

    The easiet way to fix this would be to create a channel group (within MediaPortal Tv Server setup program) that only has the channels that you want to see in the web interface and to set that group as the prefered channel group for your user in the manager program. (See "Users" page and edit your user to enter a default channel group).

    Regards
    Kev
     

    charli181

    Retired Team Member
  • Premium Supporter
  • August 3, 2007
    800
    111
    Sydney
    Home Country
    Australia Australia
    Hey Big_Kev,

    Are you getting close to porting this into IIS. I am still holding out on this until it can be ported.......pretty please....
     

    Big_Kev

    Portal Pro
    June 8, 2007
    338
    186
    Home Country
    New Version 0.1.2.7

    Lots of little changes....

    New Features:
    • Tooltips on guide screen: This will show the program description when you hover the mouse over the link. There are 2 methods for this - simple method, just adds a title tag to the link (works best in IE as FireFox shortens the line). Boxover method - this uses the Boxover javascritp from http://boxover.swazz.org/. There is a basic default script set up in the Manager Program on the HTML page, but have a look at the website for more details on the API. This is represented by 2 new special tags... !!!Boxover!!! in the page header to include the script reference, and !!!ToolTip!!! to insert the appropriate value.
    • Fixed lengths on custom HTML tags - any special tag (like !!!Title!!!) that is used in a HTML template or on the HTML page of the manager, can have a fixed length assigned by immediately following it with a length in characters surrounded by square brackets. For example, limiting the title to 35 characters would be done by !!!Title!!![35]. This will display the first 32 characters of the title, followed by "...".
    Fixes:
    • Navigation problems with days, groups, timespans.
    • Lengthened fields for translations.
    • Custom HTML for guide page. Does not place <td></td> tag around custom entry - you are responsible for all HTML within the Channel/Time Block cell. For example
      Code:
      <tr><th width=5%>!!!StartTime!!!</th>
      <td nowrap>
      <a !!!ToolTip!!! href=showdetail?ID=!!!ProgID!!!>!!!Title!!![35]</a>
      </td></tr>
      will give you the same result the vertical guide now gives by default.

    Now for something completely different...

    As you may have realised, the Web Interface does not use .NET. It is written in Borland C++.
    This was not a problem until I wanted to interact with the TV cards to inquire status, start/stop recordings etc as some have requested.

    To get around this, I loaded some of the Microsoft Visual Express components and knocked up my first web service that queries/starts/stops the cards no problem. However... I can't "publish" the web service from the express version AND I would much prefer that it run as an independent windows service than have to run under IIS as an ASP.NET application (much the same as TvScheduler by dvdfreak does).

    My question is... can anyone help with some more info and/or example code etc on how to do this?

    Regards
    Kev
     

    Big_Kev

    Portal Pro
    June 8, 2007
    338
    186
    Home Country
    Visual Studio Pro provides a windows service template (see image) is it not there in the express edition?
    I cant see one... I don't think that programs created with the Express edition can be run outside of the IDE, so they can not be distributed.

    Certainly the web service does not create a dll file in the bin directory, it just creates a temporary dll when you click "run" in the IDE.

    I have downloaded the beta release of Visual Studio 2008, but my laptop is not up to running it!

    Regards
    Kev
     

    joboehl

    Retired Team Member
  • Premium Supporter
  • July 30, 2006
    431
    4
    Home Country
    Brazil Brazil
    Big_Kev,

    First of all, congratulations on this plug-in. It's really great!!!

    Could you help me with an issue? I'am running the latest version but I can't schedule a recording. I get an Internal Server error. Could you point me to some log or debug message so I can try figure out what's happening?

    thanks.
     

    risu

    MP Donator
  • Premium Supporter
  • September 22, 2006
    279
    19
    Home Country
    Finland Finland
    Thanks Kev, that solved half of my problems :)

    Now there's a new ones though, I can't put !!!recordimage!!! anywhere but inside <a>-link on custom html without breaking tooltips. And inside link it gets boxed but I can deal this with style.css (by changing links look).

    EDIT> NEVERMIND, I chose boxover-method and it works just fine :)


    Any chance of getting !!!current!!! to insert id=current when current program is on? This way we could "easily" change the way currently on programs look within the style.css and get away with problem they are not shown on custom html? Code would look like:
    Code:
    <tr><th width=5%>!!!StartTime!!!</th><td !!!current!!! nowrap>
    <a !!!ToolTip!!! href=showdetail?ID=!!!ProgID!!!>!!!Title!!![35]</a>!!!recordimage!!!</td></tr>

    and id=current would only be inserted to currently on programs, like !!!recordimage!!!
     

    Big_Kev

    Portal Pro
    June 8, 2007
    338
    186
    Home Country
    New Version 0.1.2.8

    New Features:
    • Added new custom HTML tag !!!Current!!!. This will have the value "id=current" when the program being displayed is currently on air, and will be null when it is not. This will allow the css to change the currently showing program.
    • Error message on Scheduling a recording - should now show the system-generated message if adding a new schedule record fails.
    Regards
    Kev

    Big_Kev,

    First of all, congratulations on this plug-in. It's really great!!!

    Could you help me with an issue? I'am running the latest version but I can't schedule a recording. I get an Internal Server error. Could you point me to some log or debug message so I can try figure out what's happening?

    thanks.

    Hi joboehl,

    I have added error message display if the scheduling fails - please let me know if you get an error. I thought that it might have been an issue with the new RC3, so I installed it, but did not get a problem.

    Kev

    Any chance of getting !!!current!!! to insert id=current when current program is on? This way we could "easily" change the way currently on programs look within the style.css and get away with problem they are not shown on custom html? Code would look like:
    Code:
    <tr><th width=5%>!!!StartTime!!!</th><td !!!current!!! nowrap>
    <a !!!ToolTip!!! href=showdetail?ID=!!!ProgID!!!>!!!Title!!![35]</a>!!!recordimage!!!</td></tr>

    and id=current would only be inserted to currently on programs, like !!!recordimage!!!

    Done... but case sensitive... use !!!Current!!!

    Regards
    Kev
     

    cheezey

    Community Plugin Dev
    August 26, 2004
    1,560
    312
    55
    West Yorks, UK
    Home Country
    United Kingdom United Kingdom

    Users who are viewing this thread

    Top Bottom