Appcelerator Titanium has a rich set of Window management methods which are accessible with the UserWindow object and the Titanium.UI namespace.
The basics of opening up a new window in Titanium is as follows:
var currentWindow = Titanium.UI.getCurrentWindow(); var newWindow = currentWindow.createWindow('http://www.google.com'); newWindow.setWidth(400); newWindow.setHeight(300); new();
First, we need to get the current window we want to work with, from which we are going to open the new window. This window will become the new window’s parent.
The new window is created with the .createWindow() method. The parameter is an optional parameter, but can be either a url, or an object containing the parameters for the new window. The url can be either an external url, which is signified by using http:// in the url, or else it can be a url pointing to an internal location in the application, which is prefixed by app:// and then the path to the html page to display.
continue reading…