Announcement

Collapse
No announcement yet.

RegisterPages not Forwarded to Plugin

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    RegisterPages not Forwarded to Plugin

    I initially implemented mcsSprinklers for HS3 using RegisterPage and built my pages in the same way I did with HS2 but now using GetPagePlugin and PostBackProc. As part of the implementation buttons existed on the constructed pages that, when clicked, use javascript to open a new browser window and set the url. The url was one of the registered pages (e.g. /weather or weather). That worked fine.

    I then migrated the implementation to use RegisterLink for those that I wanted user access and continued to use RegisterPage for those that needed to be serviced outside of the menu system. In this scenario the registered page no longer resulted in a call to GetPluginPage. There was also no call to PutPage, as expected, because there was never a submit from the originally constructed page.

    The same lack of GetPagePlugin call results if I simply open a browser and put the URL of one of the registered pages. I get a connecting hourglass where the browser is waiting for a response, but since HS3 never makes a plugin web page call the page never gets built and returned to the browser.

    If I enter in the URL a random page (e.g. http://192.168.0.5/fldjadslf) then HS3 returns immediately with only a PowerByHomeseer icon for the page that is linked to www.homeseer.com. The HS3 log also shows file \html\fldjadslf does not exist.

    My expectation is that I should be able to use a mixed system of RegisterLink and RegisterPage and have calls to PutPage and GetPluginPage respectively when the URL is set to a page that has been registered(RegisterPage) or included as a menu link (RegisterLink). Since I get different behavior with registered vs. random URL requests it is clear that HS3 recognizes the URL, but does not invoke the plugin to service it.

    #2
    If a page isn't registered, it defaults to the old calls to the plugin, but you can only get there if you have a link in the menu.

    RegisterPage results in a call to GetPagePlugin and PostBackProc.

    RegisterLink results in a link added to the menu and a call to GenPage and PagePut.

    RegisterPage and RegisterLink results in a link added to the menu and a call to GetPagePlugin and PostBackProc.

    I believe your looking for the third solution?
    Wade

    "I know nothing... nothing!"

    Comment


      #3
      The solution I was expecting is your second one "RegisterPage results in a call to GetPagePlugin and PostBackProc"

      Looking further I determined that when I registered the page it was not registered to the correct plugin name. In this case I would expect HS3 to ignore the request so when the browser made the request for the page it would return something like "not found" or the HS Logo. Hanging up the browser is not a good HS3 server response.

      Comment

      Working...
      X