<%@ Page Language="C#" Inherits="SiteServer.BackgroundPages.BackgroundStlCreate" %>
<%@ Register TagPrefix="bairong" Namespace="BaiRong.Controls" Assembly="BaiRong.Controls" %>
<%@ Register TagPrefix="user" Namespace="UserCenter.Controls" Assembly="UserCenter.Pages" %>
<%@ Register TagPrefix="site" Namespace="SiteServer.Controls" Assembly="SiteServer.Controls" %>

<HTML>
<HEAD>
<!--#include file="../inc/html_head.inc"-->
<user:custom type="style" runat="server"></user:custom>

<script language="JavaScript" type="text/JavaScript">
function setUnit(obj,str)
{
var val = obj.value;
if (val != null && val.length >= 2){
	if ('%' == val.substr(val.length -1, 1)){
		val = val.substr(0, val.length -1) + str;
	}else if ('px' == val.substr(val.length -2, 2)){
		val = val.substr(0, val.length -2) + str;
	}else if ('pt' == val.substr(val.length -2, 2)){
		val = val.substr(0, val.length -2) + str;
	}else if ('mm' == val.substr(val.length -2, 2)){
		val = val.substr(0, val.length -2) + str;
	}else if ('cm' == val.substr(val.length -2, 2)){
		val = val.substr(0, val.length -2) + str;
	}else if ('in' == val.substr(val.length -2, 2)){
		val = val.substr(0, val.length -2) + str;
	}else if ('em' == val.substr(val.length -2, 2)){
		val = val.substr(0, val.length -2) + str;
	}else if ('ex' == val.substr(val.length -2, 2)){
		val = val.substr(0, val.length -2) + str;
	}else{
		val = val + str;
	}
}else if (val != null && val.length >= 1){
	if ('%' == val.substr(val.length -1, 1)){
		val = val.substr(0, val.length -1) + str;
	}else{
		val = val + str;
	}
}else{
	val = '';
}
obj.value = val;
}
</script>
<bairong:Code type="Prototype" runat="server" />
<bairong:Code type="Scriptaculous" runat="server" />

<meta http-equiv="content-type" content="text/html;charset=gb2312">
</HEAD>
<body>
    <form id="myForm" runat="server">
<bairong:Message runat="server"></bairong:Message>
      <DIV class="column">
<div class="columntitle">生成常用标签</div>
        
                    <table width="95%" align="center" cellpadding="3" cellspacing="3">
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="唯一标识此显示方式的字符串。模板标识符：<font color=red>“DisplayMode”</font>" Text="显示方式标识：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="25" MaxLength="50" id="DisplayModeENName" runat="server" />
                                <asp:RequiredFieldValidator id="RequiredFieldValidator_DisplayModeENName" ControlToValidate="DisplayModeENName" ErrorMessage="*" Display="Dynamic"
                                    runat="server" />
                                <asp:RegularExpressionValidator id="RegularExpressionValidator_DisplayModeENName" runat="server" ControlToValidate="DisplayModeENName"
                                    ValidationExpression="[^']+" ErrorMessage="*" Display="Dynamic" />								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="此显示方式的名称" Text="显示方式名称：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="25" MaxLength="50" id="DisplayModeCNName" runat="server" />
                                <asp:RequiredFieldValidator id="RequiredFieldValidator_DisplayModeCNName" ControlToValidate="DisplayModeCNName" ErrorMessage="*" Display="Dynamic"
                                    runat="server" />
                                <asp:RegularExpressionValidator id="RegularExpressionValidator_DisplayModeCNName" runat="server" ControlToValidate="DisplayModeCNName"
                                    ValidationExpression="[^']+" ErrorMessage="*" Display="Dynamic" />								</td>
                        </tr>
                        <tr >
                            <td width="160" align="left">
                          <bairong:help HelpText="设置此显示方式为栏目显示方式或内容显示方式" Text="显示方式类型：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:DropDownList id="IsChannelDisplay" runat="server">									</asp:DropDownList>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="指列表一共显示多少条信息，0代表显示所有信息。模板标识符：<font color=red>“TotalNum”</font>" Text="显示内容数目：" runat="server" ></bairong:help>							  </td>
                          <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" Text="0" id="TotalNum" runat="server" />
                                <asp:RequiredFieldValidator ControlToValidate="TotalNum" ErrorMessage="*" Display="Dynamic" runat="server" />
                                <asp:RegularExpressionValidator ControlToValidate="TotalNum" ValidationExpression="\d+" Display="Dynamic" ErrorMessage="显示内容数目必须为数字" runat="server"/>
                                （0代表不限定）							  							 </td>
                        </tr>
                        <tr >
                            <td width="160" align="left">
                          <bairong:help HelpText="指有翻页功能是每页显示多少条信息，0代表一页显示所有信息。模板标识符：<font color=red>“PageNum”</font>" Text="页显示内容数目：" runat="server" ></bairong:help>							  </td>
                          <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" Text="0" id="PageNum" runat="server" />
                                <asp:RequiredFieldValidator ControlToValidate="PageNum" ErrorMessage="*" Display="Dynamic" runat="server" />
                                <asp:RegularExpressionValidator ControlToValidate="PageNum" ValidationExpression="\d+" Display="Dynamic" ErrorMessage="显示内容数目必须为数字" runat="server"/>
                                （0代表不分页）							  </td>
                        </tr>
                        <tr id="TitleWordNumTR">
                            <td width="160" align="left">
                          <bairong:help HelpText="指内容标题显示多少字数，0代表不限制字数。模板标识符：<font color=red>“TitleWordNum”</font>" Text="内容标题文字数量：" runat="server" ></bairong:help>							  </td>
                          <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" Text="20" id="TitleWordNum" runat="server" />
                                <asp:RequiredFieldValidator ControlToValidate="TitleWordNum" ErrorMessage="*" Display="Dynamic" runat="server" />
                                <asp:RegularExpressionValidator
                                    ControlToValidate="TitleWordNum"
                                    ValidationExpression="\d+"
                                    Display="Dynamic"
                                    ErrorMessage="内容标题文字数量必须为数字"
                                    runat="server"/>
（0代表不限定）								</td>
                        </tr>
                        <tr id="SummaryWordNumTR">
                            <td width="160" align="left">
                          <bairong:help HelpText="指内容简介显示多少字数，0代表不限制字数。模板标识符：<font color=red>“SummaryWordNum”</font>" Text="内容描述文字数量：" runat="server" ></bairong:help>							  </td>
                          <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" Text="100" id="SummaryWordNum" runat="server" />
                                <asp:RequiredFieldValidator ControlToValidate="SummaryWordNum" ErrorMessage="*" Display="Dynamic" runat="server" />
                                <asp:RegularExpressionValidator
                                    ControlToValidate="SummaryWordNum"
                                    ValidationExpression="\d+"
                                    Display="Dynamic"
                                    ErrorMessage="内容描述文字数量必须为数字"
                                    runat="server"/>
（0代表不限定）								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="信息列表显示时的排序规则，包括自定义排序、自定义排序（反方向）、内容ID（升序）、内容ID（降序）、更新时间（升序）、更新时间（降序）、点击次数（升序）和点击次数（降序）。模板标识符：<font color=red>“Order”</font>" Text="排序规则：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:DropDownList id="TaxisType" runat="server">									</asp:DropDownList>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="设置信息列表显示的组名称，只有当栏目或内容属于此组时才能显示在列表中。模板标识符：<font color=red>“Group”</font>" Text="仅显示组：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:DropDownList id="GroupName" runat="server">									</asp:DropDownList>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="指定列表中应显示多少列，默认值为 0。如果此属性设置为 0，则列表基于“方向”属性的值按单行或单列显示它的项。如果“方向”属性设置为“水平”，则项按单行显示。如果“方向”属性设置为“垂直”，则项按单列显示。模板标识符：<font color=red>“Columns”</font>" Text="列数：" runat="server" ></bairong:help>							  </td>
                          <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" Text="0" id="DataListRepeatColumns" runat="server" />
                                <asp:RequiredFieldValidator id="RequiredFieldValidator_DataListRepeatColumns" ControlToValidate="DataListRepeatColumns" ErrorMessage="*" Display="Dynamic" runat="server" />
                          <asp:RegularExpressionValidator
                                    ControlToValidate="DataListRepeatColumns"
                                    ValidationExpression="\d+"
                                    Display="Dynamic"
                                    ErrorMessage="列数必须为数字"
                                    runat="server"/></td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="指定列表是垂直显示还是水平显示。选择“垂直”将使元素从上到下排列，然后在下一列的顶部继续排列（如同报纸分栏）。选择“水平”将使元素从左向右排列，然后在下一行继续排列（如同日历中的日期）。模板标识符：<font color=red>“Direction”</font>" Text="方向：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:DropDownList id="DataListRepeatDirection" runat="server">									</asp:DropDownList>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="设置列表是在表中显示还是在流布局中显示。在流布局中，以字处理文档的样式在行内呈现列表项。在表布局中，项被呈现到 HTML 表中，这更便于指定项的外观，因为它允许您设置表单元格的属性，如网格线。当在表中显示时，可使用“网格线”属性指定网格线样式。模板标识符：<font color=red>“Layout”</font>" Text="使用表格布局：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:DropDownList id="DataListRepeatLayout" runat="server">									</asp:DropDownList>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="整个列表的CSS格式" Text="整体CSS名称：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="25" MaxLength="50" id="DataListCssClass" runat="server" />
                                <asp:RegularExpressionValidator id="RegularExpressionValidator_DataListCssClass" runat="server" ControlToValidate="DataListCssClass"
                                    ValidationExpression="[^']+" ErrorMessage="*" Display="Dynamic" />								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="信息列表在页面内的水平对齐方式" Text="整体排列方式：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:DropDownList id="DataListHorizontalAlign" runat="server">									</asp:DropDownList>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="单元格边缘与单元格内容之间的空间量（以像素为单位）。设置此属性可以在单元格内容周围创建边距。如果 “布局”处于流布局模式，则该属性无效。" Text="单元格填充大小：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" Text="0" id="DataListCellPadding" runat="server" />
                                <asp:RequiredFieldValidator ControlToValidate="DataListCellPadding" ErrorMessage="*" Display="Dynamic" runat="server" />
                                <asp:RegularExpressionValidator
                                    ControlToValidate="DataListCellPadding"
                                    ValidationExpression="\d+"
                                    Display="Dynamic"
                                    ErrorMessage="单元格填充大小必须为数字"
                                    runat="server"/>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="单元格之间的空间量（以像素为单位）。将此值设置为大于零的值将分隔单元格。如果“布局”处于流布局模式，则该属性无效。" Text="单元格间距大小：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" Text="0" id="DataListCellSpacing" runat="server" />
                                <asp:RequiredFieldValidator ControlToValidate="DataListCellSpacing" ErrorMessage="*" Display="Dynamic" runat="server" />
                                <asp:RegularExpressionValidator
                                    ControlToValidate="DataListCellSpacing"
                                    ValidationExpression="\d+"
                                    Display="Dynamic"
                                    ErrorMessage="单元格间距大小必须为数字"
                                    runat="server"/>								</td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="信息列表的高度。模板标识符：<font color=red>“Height”</font>" Text="整体高度：" runat="server" ></bairong:help>							  </td>
                          <td align="left">								
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" id="DataListHeight" runat="server" />
                                <select onChange="if(this.value!==''){setUnit(document.getElementById('<%=DataListHeight.ClientID%>'), this.value);}">
                                    <option value="">&larr;</option>
                                    <option value="px">px</option>
                                    <option value="%">%</option>
                                    <option value="pt">pt</option>
                                    <option value="mm">mm</option>
                                    <option value="cm">cm</option>
                                    <option value="in">in</option>
                                    <option value="em">em</option>
                                    <option value="ex">ex</option>
                                </select>
                                <asp:RegularExpressionValidator runat="server" ControlToValidate="DataListHeight"
                                    ValidationExpression="\d+((px)|(%)|(pt)|(mm)|(cm)|(in)|(em)|(ex))?" ErrorMessage="*" Display="Dynamic" />							  </td>
                        </tr>
                        <tr>
                            <td width="160" align="left">
                          <bairong:help HelpText="信息列表的宽度。模板标识符：<font color=red>“Width”</font>" Text="整体宽度：" runat="server" ></bairong:help>							  </td>
                          <td align="left">
                                <asp:TextBox class="colorblur" onfocus="this.className='colorfocus';" onblur="this.className='colorblur';" Columns="10" MaxLength="50" id="DataListWidth" runat="server" />
                                <select onChange="if(this.value!==''){setUnit(document.getElementById('<%=DataListWidth.ClientID%>'), this.value);}">
                                    <option value="">&larr;</option>
                                    <option value="px">px</option>
                                    <option value="%">%</option>
                                    <option value="pt">pt</option>
                                    <option value="mm">mm</option>
                                    <option value="cm">cm</option>
                                    <option value="in">in</option>
                                    <option value="em">em</option>
                                    <option value="ex">ex</option>
                                </select>
                                <asp:RegularExpressionValidator runat="server" ControlToValidate="DataListWidth"
                                    ValidationExpression="\d+((px)|(%)|(pt)|(mm)|(cm)|(in)|(em)|(ex))?" ErrorMessage="*" Display="Dynamic" />							  </td>
                        </tr>
                        <tr >
                            <td width="160" align="left">
                          <bairong:help HelpText="当系统需要显示内容或栏目时没有找到指定的显示方式，则系统选择默认显示方式。" Text="是否默认显示方式：" runat="server" ></bairong:help>							  </td>
                            <td align="left">
                                <asp:RadioButtonList id="IsDefault" RepeatDirection="Horizontal" runat="server">
                                    <asp:ListItem Text="是" />
                                    <asp:ListItem Text="否" Selected="True" />									</asp:RadioButtonList>								</td>
                        </tr>
                        <tr>
                            <td colspan="2" align="center">
                                <asp:Button class="button" id="Submit" text="添 加" runat="server" />&nbsp;&nbsp;
                                <%if (Request.QueryString["Type"] != null){%>
                                    <input type=button class="button" onClick="location.href='background_dataList.aspx?PublishmentSystemID=<%=Request.QueryString["PublishmentSystemID"]%>&Type=<%=Request.QueryString["Type"]%>';" value="返 回" />
                                <%}else{%>
                                    <input type=button class="button" onClick="location.href='background_DisplayMode.aspx?PublishmentSystemID=<%=Request.QueryString["PublishmentSystemID"]%>';" value="返 回" />
                                <%}%>								</td>
                        </tr>
        </table>
      </div>
    </form>
</body>
</HTML>
