Page 1 of 1

Embedded webpage in a control page

PostPosted: Sun Dec 15, 2019 11:33 am
by Gangotti
Is there a way to create a window on a control page and display a web page? I know that this is not possible with indigo touch, however, I'm under the impression it may be possible with domopad which is fine since all my tablets are running domopad. If so, can you give me some simple instructions on how to do it?

Re: Embedded webpage in a control page

PostPosted: Mon Dec 16, 2019 10:59 am
by mundmc
Not sure how I did it, but yes there is but only for display i think. You place a refreshing image in the CP, but write something in the title or notes that lets DomoPad sub in a specified web page. Sorry i don’t remember off the top of my head

Re: Embedded webpage in a control page

PostPosted: Mon Dec 16, 2019 9:45 pm
by RogueProeliator
Is there a way to create a window on a control page and display a web page? I know that this is not possible with indigo touch, however, I'm under the impression it may be possible with domopad which is fine since all my tablets are running domopad. If so, can you give me some simple instructions on how to do it?

Yup, the longer discussion is in this thread, but the gist of it is:

To display the web content on the page, here is what you will do (it is pretty simple):
Create an image in the size of the web content you want to show on screen; in Domotics Pad, this image will be replaced with your web content while the image itself will show for non-DP clients such as the web and Indigo Touch.
Create a variable that will control which webpage is loading in the view... this will control the initial load AND may be updated which will cause a navigation on the view in DP.
Create an element on your control page to display the variable as an image and select the image from Step 1
Set the Caption of this element to "DP:WebView" (no quotes). This is what triggers the app to show the content. I suggest setting the caption in the middle of the image (Centered on Control) for non-DP clients; in DP this caption will of course not be rendered.
This is the least invasive and easiest method I could come up with to configure the content, allow changes from the server, and not too negatively effect other clients if they happened to load the page.


Let me know if you have any questions/issues doing it!

Adam

Re: Embedded webpage in a control page

PostPosted: Sun Dec 22, 2019 5:26 pm
by Gangotti
Adam, that worked great, I am trying to display the control page sized for my iPhone in a window in domopad. Currently, when it displays the web image it is very small despite making the variable image size the same size as the control page I'm calling. any thoughts? Is there a way to specify the size of the web page in the variable?

Re: Embedded webpage in a control page

PostPosted: Sun Dec 22, 2019 5:27 pm
by Gangotti
Here is a photo for reference.
IMG_1853.jpg
IMG_1853.jpg (468.33 KiB) Viewed 5421 times



Sent from my iPhone using Tapatalk

Re: Embedded webpage in a control page

PostPosted: Mon Dec 23, 2019 1:31 pm
by mundmc
Gangotti wrote:
Here is a photo for reference.
IMG_1853.jpg



Sent from my iPhone using Tapatalk


A very clever idea! I look forward to seeing how this works out

Re: Embedded webpage in a control page

PostPosted: Tue Dec 24, 2019 3:15 pm
by RogueProeliator
Adam, that worked great, I am trying to display the control page sized for my iPhone in a window in domopad. Currently, when it displays the web image it is very small despite making the variable image size the same size as the control page I'm calling. any thoughts? Is there a way to specify the size of the web page in the variable?

Domotics Pad simply loads the page into the view -- nothing explicit is being set as to sizing which likely means the server is not setting the viewport or else the Chrome WebView is not obeying it. Let me try to duplicate it here and see if I have any suggestions.

I can guess, but what are the specific sizes you are using?

Adam

Embedded webpage in a control page

PostPosted: Tue Dec 24, 2019 4:56 pm
by Gangotti
Adam, the size I’m trying to display is 414 x 672. I have tried changing the number of pixels per inch in photoshop of the image and it yielded no change. The background image is 1920 x 1200


Sent from my iPhone using Tapatalk

Re: Embedded webpage in a control page

PostPosted: Wed Dec 25, 2019 6:22 pm
by Gangotti
Also in addition to this, Ever since I lost the weather underground stuff, I have been trying to find a way to show the radar view again. this has provided me a way to view the pack, however, I have noticed that the webpage never updates itself the only way I can update is to either tap the image a couple of times, or reopen the control panel. Any suggestions? Currently, I am trying to display the looping radar data from https://radar.weather.gov/ridge/radar_l ... R&loop=yes

Re: Embedded webpage in a control page

PostPosted: Wed Dec 25, 2019 10:13 pm
by RogueProeliator
Adam, the size I’m trying to display is 414 x 672. I have tried changing the number of pixels per inch in photoshop of the image and it yielded no change. The background image is 1920 x 1200

So the image is 414x672 as well as the background size of the control page being shown in the small window? I'll see if I can duplicate.

Ever since I lost the weather underground stuff, I have been trying to find a way to show the radar view again. this has provided me a way to view the pack, however, I have noticed that the webpage never updates itself the only way I can update is to either tap the image a couple of times, or reopen the control panel. Any suggestions?

The page on the control page should exist just as any other browser window (that is literally what is being shown, the application is not attempting to handle the web stuff itself). SO, if the source page doesn't auto-refresh then you will have to handle it yourself.

Try setting a timer to change the URL being shown -- usually you can add your own parameter to the end of the url (like &myCnt=1) and simply increment that counter. Most websites should be okay with extra parameters that they don't use and DP will see that as a changed URL and (hopefully) reload successfully.

Adam

Re: Embedded webpage in a control page

PostPosted: Thu Dec 26, 2019 6:13 am
by DaveL17
Gangotti wrote:
Also in addition to this, Ever since I lost the weather underground stuff, I have been trying to find a way to show the radar view again. this has provided me a way to view the pack, however, I have noticed that the webpage never updates itself the only way I can update is to either tap the image a couple of times, or reopen the control panel. Any suggestions? Currently, I am trying to display the looping radar data from https://radar.weather.gov/ridge/radar_l ... R&loop=yes


Try entering this url as a refreshing image url with a refresh rate of choice: https://radar.weather.gov/ridge/lite/N0R/ESX_loop.gif

If that doesn't solve the issue, then you could use the Fantastic Weather Image Downloader (with the same url) and then link to the downloaded image. However, if the control page isn't refreshing any images, neither will likely be different than what you're currently seeing.