Web app running in a HTML page?

Is it possible to launch a small web app to run in part of a standard HTML page? To elaborate more; If I have a HTML page that needs to do something that is not possible (or very difficult to do) in HTML, is it possible to run a web app in a small section of the screen without launching a gigantic web app instance in the client browser? I tried embedding the HTML code in one of my pages to launch a small app that I have, but it just launches a new tab in the browser.

You can use an iframe :slight_smile:
It’s used to embed another document within the current HTML document.

For that to work you also need to check out WebApplication.Security to allow embedding.
http://documentation.xojo.com/index.php/WebApplication.Security

I thought I read a post some time ago saying that it wasn’t possible to do this, but the docs you pointed to say otherwise.

[quote=218986:@Albin Kiland]You can use an iframe :slight_smile:
It’s used to embed another document within the current HTML document.

For that to work you also need to check out WebApplication.Security to allow embedding.
http://documentation.xojo.com/index.php/WebApplication.Security [/quote]

Isn’t the example shown just a HTML.Get and not actually an app

Not sure I follow. Just enter the URL to your app :slight_smile:
Don’t forget to specify the size of the frame and that stuff.

<iframe src="URL_TO_APP" width="200" height="200"></iframe>

Another usefull link: HTML Iframes

web apps, by default, will not want to appear in an iFrame for security purposes.

Look into WebApplication.Security for information about how to allow your app to appear in an iFrame.

Sorry to poke an old thread but, I have an related problem I’m trying to overcome and don’t see anything closer in my searches.

I’ve created a WE app that has dynamic height achieved by using Taylor Design’s web custom controls. App is cgi running on port 80 and stored within the structure of the Apache Document Root. The App does run properly inside the iFrame. With previous apps I’ve used the iFrame method to embed the WE app in webpages (HTML/PHP) successfully however, those apps had a fixed height.

I’ve attempted to use Javascript to determine the height of the content (delivered App) and resize the iFrame (also, tried same with HTML’s object and embed tags). Javascript doesn’t seem capable of determining the proper height (always returns 150px).

I’ve tried using PHP to execute the .cgi file (system, exec, and passthru). At best I get gibberish (clearly not HTML) returned.

Also, I’ve been attempting to run as an SSI, also with no luck as nothing displays in a web page.

Grasping for ideas and hopefully solutions. If additional information is require please feel free to let me know.

Best

Are you double sure that you’re checking the height of the correct DOM? It should change as you resize your browser.

Open the page in Chrome, hit F12, open Elements on the left side and Computed on the right side (see picture below)

As you move around in the DOM (1) the relevant piece should highlight (2) that is 150px (3).

http://i.imgur.com/Th6uHeR.png

Good luck :slight_smile:

If you can’t find it, PM me a link to the site if you want and I can take a quick look.

Julian,

Thanks for the quick reply. I’ve been beating my head against this for a week. I’ll have to re-instate the Javascript height test and give it another go. Will reply further with results next week.

Julian,

Test page is here: http://dev.kingfeatures.com/test.php. As previously mentioned, always comes back as 150px height.

It looks like you are reading the height out before the page has had chance to render so you’re getting a return value of 150 which is the default size of the iframe.

Try:

[code]

[/code]

This is working with a little test here.

Thanks Julian. That did the trick.