Joomla 1.5 comes with a popup window manager. The library pops a sized ''iframe'' in the center of the screen while darkening the surroundings. It is useful for wizards, performing minor actions, reporting information and for many other uses.
To invoke a popup you must include the javascript library and stylesheet:
global $mainframe;
$document = &$mainframe->getDocument();
$document->addScript('../includes/js/joomla/popup.js');
$document->addStyleSheet('../includes/js/joomla/popup.css');
or
$document = &$this->getDocument();
$document->addScript('../includes/js/joomla/popup.js');
$document->addStyleSheet('../includes/js/joomla/popup.css');
To display the popup, called ''window.open'':
var url='index3.php?option=com_content&task=wizard';
document.popup.show(url, 700, 500, null);
A typical case might be to link the popup to an Administrator toolbar task. In this case, use something similar to the following:
... to be continued