<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<meta name="viewport" content="width=290; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;"/>
		<title><?php print $this->global['brandname'] . ' ' . generateVersionString($this->version) . ' - ' . $this->translate('Login Page') ?></title>
		<link rel="stylesheet" type="text/css" href="<?php echo $this->siteBaseUrl; ?>css/jquery.ui.dialog.css" />
		<link rel="stylesheet" href="<?php echo $this->siteBaseUrl ?>css/lang.css?<?php echo Zend_registry::get('config')->global['version'] ?>" type="text/css" media="screen"/>
		
		<link rel="stylesheet" type="text/css" href="<?php echo $this->siteBaseUrl ?>css/mobile/jquery.mobile-1.1.0.min.css" media="screen, print"/>
		<link rel="stylesheet" type="text/css" href="<?php echo $this->siteBaseUrl ?>css/mobile/mobile.css" media="screen, print"/>
		<link rel="stylesheet" type="text/css" href="<?php echo $this->siteBaseUrl ?>css/mobile/themes/<?php echo $this->global['mobilecssStyle'] ?>/mobile.css" media="screen, print"/>
		<?php if (file_exists(APP_ROOT . "css/mobile/themes/". $this->global['mobilecssStyle'] . "/highdensity.css")): ?>
		<link rel="stylesheet" type="text/css" href="<?php echo $this->siteBaseUrl ?>css/mobile/themes/<?php echo $this->global['mobilecssStyle'] ?>/highdensity.css" media="screen, print"/>
		<?php endif; ?>
		<!-- jQuery -->
		<script type="text/javascript" src="<?php echo $this->siteBaseUrl ?>js/jQuery/jquery-1.3.2.min.js"></script>
		<script type="text/javascript" src="<?php echo $this->siteBaseUrl ?>js/jQuery/ui/jquery-ui-1.7.2.custom.min.js"></script>
		
		<!-- Fav icon -->
		<link rel="shortcut icon" href="<?php echo $this->siteBaseUrl ?>images/themes/<?php echo $this->global['mobilecssStyle'] ?>/favicon.ico?<?php echo Zend_registry::get('config')->global['version'] ?>" type="image/x-icon" />

		<script type="text/javascript">
		var Expand;

		// Reload to the master frame if we are inside a frameset
		if (parent.frames[1]) top.window.location=self.location;

		$("#dialog").dialog({ 
			autoOpen: false, 
			height: 70,
			modal: true, 
			overlay: { 
			opacity: 0.5, 
			background: "white" 
			},
			resizable: false,
			closeOnEscape: false,  
			width: 270
		});

		$(function() {
			document.location = "<?php echo $this->moduleBaseUrl ?>/settings/iosprofile";
			
			// Sleep for 5 secs and redirect to success page
			setTimeout(function() {
			
			$("DIV#prepare").hide();
			
			$("DIV#success").show();
				
			}, 2000);
			
		});

		</script>
	</head>
	<body id="bg" style="background:#eee;" class="<?php echo $this->defaultUserSettings['Language'] ?>">
		
		<div id="dialog" style="display:none;">

		<br>
		<center>
		<div id='loading'>
		<h1 class='loading-text'><img class='loadingimg' src='<?php echo $this->siteBaseUrl ?>images/25.gif' width='28' height='28'/><span class='loading'><strong><?php echo $this->translate('Loading...') ?></strong></span></h1>
		</div>
		</center>

		</div>
				
		<div id="container" class="provision">
			<div id="header">
				<div id="logo"></div>
			</div>
			<div id="prepare">
			
				<h2><?php print $this->translate('Provision your account...')?></h2>
				
			<div class="ui-btn ui-btn-inline ui-shadow ui-btn-corner-all ui-fullsize ui-btn-up-b"><span class="ui-btn-inner ui-btn-corner-all"><span class="ui-btn-text"><?php print $this->translate('Download mobileconfig')?></span><button class="ui-btn ui-btn-inline ui-shadow ui-btn-corner-all ui-btn-hidden ui-btn-up-b" onclick="document.location = '<?php echo $this->moduleBaseUrl; ?>/settings/iosprofile';"></button></div>
			
			</div>
			
			<div id="success" style='display: none;'>
				
				<h2 style="color:#0093d0;"><?php print $this->translate('Account provisioned!')?></h2>
				
				<p><?php print $this->translate('You can now use the native applications on your iOS device to access Email, Contacts and Calendaring data.')?></p>
				
				<h3><span class="icon-email"></span><?php print $this->translate('Email')?></h3>
				
				<p><?php print $this->translate('Access email via IMAP, anytime.')?></p>
				
				<h3><span class="icon-cal"></span><?php print $this->translate('Calendar')?></h3>
				
				<p><?php print $this->translate('Use the native calendar application to schedule events, automatically sync/push to the server and more.')?></p>
				
				<h3><span class="icon-contacts"></span><?php print $this->translate('Contacts')?></h3>
				
				<p><?php print $this->translate('View all your contacts created in ' . $this->global['brandname'] . ' on your phone, and sync new contacts to ' . $this->global['brandname'] . '.')?></p>
			
			</div>
		</div>

		<div id="foot">
		</div>
	</body>
</html>
