<%@ page language="C#" masterpagefile="~/SiteServer/MasterPage/PageTemplate.Master" autoeventwireup="true" inherits="SiteServer_Collect_Collect_StepTwo, v5star.Web" title="Untitled Page" validaterequest="false" enableviewstate="false" theme="Default" %>
<%@ Register Src="CollectEditor.ascx" TagName="CollectEditor" TagPrefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="PageBody" runat="Server">

    <script language="javascript" type="text/javascript">
function ChangeCutPara(obj,flag)
{ 
    var flag;
    if(document.getElementById('ctl00_PageBody_RadPageNone').checked)
        flag = 0;
    else if(document.getElementById('ctl00_PageBody_RadPageFlag').checked)
        flag = 1;
    else if(document.getElementById('ctl00_PageBody_RadPageSingle').checked)
        flag = 2;
    else if(document.getElementById('ctl00_PageBody_RadPageIndex').checked)
        flag = 3;
    var tb = document.getElementById('tabList');
    var n = 1;
    var sp = document.getElementById('SpanPage');
    switch(flag)
    { 
   
        case 0:
            tb.rows[n+1].style.display = 'none';
            tb.rows[n+2].style.display = 'none';
            break;
        case 1:          
            tb.rows[n+1].style.display = '';
            tb.rows[n+2].style.display = 'none';
            sp.innerText = '从当前页获取下一页的地址，再从下一页中获取下一页的地址，以此类推。例如:<a href=[其他页面]>下一页,当前页面的下一页必须咋一';
            break;
        case 2:
            tb.rows[n+1].style.display = '';
            tb.rows[n+2].style.display = 'none';
            sp.innerText = '从当前页获取所有分页的地址。';
            break;
        case 3:
            tb.rows[n+1].style.display = 'none';
            tb.rows[n+2].style.display = '';
            break;
    }
}
function StepBack()
{
    location.href = "Collect_Add.aspx?Type=edit&ID="+<%=cjid%>;
}
window.onload=LoadMe;

function LoadMe()
{
    ChangeCutPara(this,0);
}
    </script>

    <aspx:HeadMenuWebControls ID="HeadMenuWebControls1" runat="server" HeadOPTxt="第二步"
        HeadTitleTxt="采集管理">
        <aspx:HeadMenuButtonItem ButtonIcon="back.gif" ButtonName="返回" ButtonPopedom="List"
            ButtonUrl="history.back()" ButtonUrlType="JavaScript" ButtonVisible="True" />
    </aspx:HeadMenuWebControls>
    <aspx:TabOptionWebControls ID="TabOptionWebControls1" runat="server" TabImagesPath="../../images/Menu/">
        <aspx:TabOptionItem ID="TabOptionItem1" runat="server" Tab_Name="列表设置">
            <table id="tabList" width="98%" border="0" align="center" cellpadding="5" cellspacing="1"
                class="border">
                <tr id="tt">
                    <td class="table_body" width="30%" align="center">
                        列表内容:
                    </td>
                    <td class="table_none" width="70%">
                        <uc1:CollectEditor ID="EdtList" runat="server" />
                    </td>
                </tr>
                <tr>
                    <td class="table_body" width="30%" align="center">
                        分页设置</td>
                    <td class="table_none">
                        <asp:RadioButton onclick="ChangeCutPara(this,0);" runat="server" ID="RadPageNone"
                            GroupName="RadPageSet" Text="不分页" />
                        <asp:RadioButton onclick="ChangeCutPara();" runat="server" ID="RadPageFlag" GroupName="RadPageSet"
                            Text="递归分页设置" />
                        <asp:RadioButton onclick="ChangeCutPara();" runat="server" ID="RadPageSingle" GroupName="RadPageSet"
                            Text="单页分页设置" />
                        <asp:RadioButton onclick="ChangeCutPara();" runat="server" ID="RadPageIndex" GroupName="RadPageSet"
                            Text="索引分页设置" />
                    </td>
                </tr>
                <tr>
                    <td class="table_body" align="center">
                        其他页面</td>
                    <td class="table_none">
                        <uc1:CollectEditor ID="EdtPageFlag" runat="server" />
                        <br />
                        <span style="color: Red" id="SpanPage"></span>
                    </td>
                </tr>
                <tr>
                    <td class="table_body" align="center">
                        索引规则</td>
                    <td class="table_none">
                        <uc1:CollectEditor ID="EdtPageIndex" runat="server" />
                        页码开始：
                        <asp:TextBox runat="server" size="5" ID="TxtPageStart" />
                        <asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="TxtPageStart"
                            Display="Dynamic" ErrorMessage="开始页码必须是1-1000以内的整数!" MaximumValue="1000" MinimumValue="1"
                            SetFocusOnError="True" Type="Integer"></asp:RangeValidator>
                        &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; 页码结束：
                        <asp:TextBox runat="server" size="5" ID="TxtPageEnd" />
                        <asp:RangeValidator ID="RangeValidator2" runat="server" ControlToValidate="TxtPageEnd"
                            Display="Dynamic" ErrorMessage="结束页码必须是1-1000以内的整数!" MaximumValue="1000" MinimumValue="1"
                            SetFocusOnError="True" Type="Integer"></asp:RangeValidator><br />
                        <font color="#ff4500">例如:&lta href=?page=^$^&class_ID=32> 注: ^$^为发生变化的页码值</font>
                    </td>
                </tr>
                <tr>
                    <td align="center" colspan="2">
                        <input type="button" value="上一步" onclick="StepBack()" id="Button1" class="button_bak" />
                        <asp:Button runat="server" ID="BtnNext" Text="下一步" OnClick="BtnNext_Click" CssClass="button_bak" />
                    </td>
                </tr>
            </table>
        </aspx:TabOptionItem>
        <aspx:TabOptionItem ID="TabOptionItem2" runat="server" Tab_Name="HTML代码">
            <asp:TextBox ID="txtHighLighter" TextMode="MultiLine" runat="server" Width="770px"
                Height="500px"></asp:TextBox>
        </aspx:TabOptionItem>
    </aspx:TabOptionWebControls>  
</asp:Content>


