<div class=”UFrame” id=”UFrame1″ src=”SomePage.aspx?ID=UFrame1″ >
<p>This should get replaced with content from Somepage.aspx</p>
Response from SomePage.aspx is rendered directly inside the UFrame. Here you see two UFrame’s are used to load the same SomePage.aspx as if they are loaded inside IFRAME. Another UFrame is used to load AnotherPage.aspx that shows photos from Flickr.
See it in action!
You can test UFrame from:
http://labs.dropthings.com/UFrame2005 – Visual Studio 2005 version, .NET 2.0 implementation showing regular ASP.NET 2.0 controls work as usual
http://labs.dropthings.com/UFrameMvc – Visual Studio 2008 version shows ASP.NET MVC works fine making UFrame an ultimate replacement for UpdatePanel
What is UFrame?
The features of UFrame are:
- You can build regular ASP.NET/PHP/JSP/HTML page and make them behave as if they are fully AJAX enabled! Simple regular postback will work as if it’s an UpdatePanel, or simple hyperlinks will behave as if content is being loaded using AJAX.
- Load any URL inside a DIV. It can be a PHP, ASP.NET, JSP or regular HTML page.
- Just like IFRAME, you can set src property of DIVs and they are converted to UFrames when UFrame library loads.
- It allows you to build parts of a page as multiple fully independent pages.
- Each page is built as standalone page. You can build, test and debug each small page independently and put them together on the main page using UFrames.
- It loads and executes both inline and external scripts from loaded page. You can also render different scripts during UFrame postback.
- All external scripts are loaded before the body content is set. And all inline scripts are executed when both external scripts and body has been loaded. This way the inline scripts execute when the body content is already available.
- It loads both inline and external CSS.
Download the code
You can download latest version of UFrame along with the VS 2005 and VS 2008 (MVC) example projects from CodePlex: www.codeplex.com/uframe
Please go to the “Source Code” tab for the latest version. You are invited to join the project and improve it or fix bugs.