<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>管理後臺</title>
<meta name="keywords" content="管理後臺" />
<meta name="description" content="管理後臺" />
<script src="/jquery/jquery-1.8.2.min.js"></script>
</head>
<body>
	<div class="wrapper">
    	<?# header ?>
    	<div class="wrap">
        	<?# sidePage ?>
            <div class="contentMain">
            	<h3>網頁網址設定</h3>
                <div class="article">
                    <form id="form1" name="form1" action="htaccessSet.php" method="post">
                    	<fieldset style="width: 100%;">
                            <div class="titleTyp">
                                <div class="visible">序號</div>
                                <div class="userName" style="width: 300px;">功能名稱</div>
                                <div class="userName" style="width: 300px;">網頁網址(請勿加副檔名)</div>
                                <div class="visible">啟用</div>
                            </div>
                            <php:repeater id="list">
                                <template>
                                    <div class="listTyp">
                                        <div class="visible"><?# ID ?><input type="hidden" name="ID[]" value="<?# ID ?>" /></div>
                                        <div class="userName" style="width: 300px;"><?# ActionName ?></div>
                                        <div class="userName" style="width: 300px;"><input type="text" name="HtmlName[]" value="<?# HtmlName ?>" style="width:300px;" /></div>
                                        <div class="visible">
                                        	<select id="Visible<?# ID ?>" name="Visible[]">
                                                <option value="1">啟用</option>
                                                <option value="0">不啟用</option>
                                            </select>
                                        </div>
                                    </div>
                                </template>
                            </php:repeater>
                            <p>
                            	<input type="button" id="btnOK" name="btnOK" value="確 定" />
								<input type="button" id="btnCancel" value="返 回" />
                            </p>
                    	</fieldset>
                    </form>
                </div>
            </div>
        </div>
        <?# footer ?>
    </div>
<script>
<!--
	$(function(){
		$('#btnOK').click(function(){
			var flag = 0;
			$('input').each(function(){
				if($(this).val() == ''){
					flag = 1;
					alert('不可有欄位空白!');
					$(this).focus();
					return false;
				}
			});
			if(flag == 0){
				$('#form1').submit();
			}else{
				return false;
			}
		});
		$('#btnCancel').click(function(){
			location.href = 'htaccessSet.php';
		});
	});
//-->
</script>
</body>
</html>