<?php
include dirname(__FILE__) . '/elements/progress.php';
$STORAGE = &$_SESSION[$controller->defaultInstaller];
?>
<div class="i-wrap">
	<?php
	if (isset($_GET['err']) && !empty($_GET['err']) && isset($_SESSION[$controller->defaultErrors][$_GET['err']]))
	{
		?>
		<div class="i-status i-status-error">
			<div class="i-status-icon"><abbr></abbr></div>
			<div class="i-status-txt">
				<h2>安装错误</h2>
				<p class="t10"><?php echo @$_SESSION[$controller->defaultErrors][$_GET['err']]; ?></p>
			</div>
		</div>
		<?php
	}
	?>
	<p>输入产品密钥。您可以<a href="http://www.rivuai.com" target="_blank">点击这里</a>购买本产品。
<br /><br />
欲试用本产品请请联系客服QQ 32557246</p>
	
	<form action="index.php?controller=pjInstaller&amp;action=pjActionStep6&amp;install=1" method="post" id="frmStep5" class="i-form">
		<input type="hidden" name="step5" value="1" />
	
		<table cellpadding="0" cellspacing="0" class="i-table t20">
			<thead>
				<tr>
					<th width="350">输入密钥</th>
					<th width="383">&nbsp;</th>
				</tr>
			</thead>
			<tbody>
				<tr>
					<td>
						<p>
							<label class="i-title">密钥<span class="i-red">*</span></label>
                            <textarea id="license_key" name="license_key" cols="100" rows="10" class="pj-form-field w300 required" tabindex="1"><?php echo isset($STORAGE['license_key']) ? htmlspecialchars($STORAGE['license_key']) : NULL; ?></textarea>
						</p>
					</td>
					<td>
                    <input style="float:left" type="button" tabindex="3" value="我要试用" class="pj-button float_right" onclick="InputLicenseKey()" />
					</td>
				</tr>
			</tbody>
		</table>
		
		<div class="t20">
		  <p class="float_left pt5">如需帮助请联系客服<a href="http://www.rivuai.com/" target="_blank">QQ 32557246</a></p>
			<input type="submit" tabindex="2" value="下一步 &raquo;" class="pj-button float_right l5" />
			<input type="button" tabindex="3" value="&laquo; 上一步" class="pj-button float_right" onclick="window.location='index.php?controller=pjInstaller&amp;action=pjActionStep4'" />
			<br class="clear_both" />
		</div>
	</form>
</div>
<script type="text/javascript">
function InputLicenseKey() {
	$('#license_key').val("NDg2MTQ0ODc2ODI5MDE4MjgxOTI3OTg0OTUxOTc0MDIyOTcyNDk4NTI3MTA2NzU1OTM4ODM3MTE4MDgwNDcyMjkyNjQyMzY4NTY2IDY4NTk5Njg4MDgxMDYyNTk5NTI5MDcyMjQ2Mjg3MDA2OTc4ODk3NDY0NjYyNTg5MDkyMTgzMzUxMDM5Njc3Nzk2MzUzMjkwMTgwIDM2MjA1MTc1NTkwNTU0Mzk3NTE2Nzg2NzUxNDA1NDIyODQ2NjgwMjY2MjEyNTQ1NjA4NTkxNzE2OTIzMzU1NDQyMzg4Njk1NzcxMg==");
	alert("该密钥只能在域名localhost上使用，安装在其他域名首页会显示乱码。\n欲在其他域名试用，请联系客服QQ 32557246");
}
</script>