WebForm1.aspx
上传用户:avia982301
上传日期:2008-10-30
资源大小:557k
文件大小:2k
- <%@ Page language="c#" Codebehind="WebForm1.aspx.cs" AutoEventWireup="false" Inherits="eWebEditorNet.WebForm1" validateRequest=false %>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
- <HTML>
- <HEAD>
- <title>WebForm1</title>
- <meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1">
- <meta name="CODE_LANGUAGE" Content="C#">
- <meta name="vs_defaultClientScript" content="JavaScript">
- <meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
- </HEAD>
- <body MS_POSITIONING="GridLayout">
- <script language=JavaScript>
- var doneUpload = "";
- // 表单提交检测
- function doCheck(){
- if (doneUpload){
- return true;
- }
- // 检测表单的有效性
- // 如:标题不能为空,内容不能为空,等等....
- if (eWebEditor1.getHTML()=="") {
- alert("内容不能为空!");
- return false;
- }
- // 表单有效性检测完后,自动上传远程文件
- // 函数:remoteUpload(strEventUploadAfter)
- // 参数:strEventUploadAfter ; 上传完后,触发的函数名,如果上传完后不需动作可不填参数
- eWebEditor1.remoteUpload("doSubmit()");
- return false;
- }
- // 表单提交(当远程上传完成后,触发此函数)
- function doSubmit(){
- doneUpload = "yes";
- document.all("Button1").click();
- }
- </script>
- <form id="Form1" method="post" runat="server" onsubmit="return doCheck();">
- <table border=1 cellpadding=5 cellspacing=0>
- <tr>
- <td>
- <INPUT type="hidden" name="content" Value="<%=Server.HtmlEncode(Request["content"])%>">
- <IFRAME ID="eWebEditor1" src="eWebEditor/ewebeditor.htm?id=content&style=coolblue" frameborder="0" scrolling="no" width="550" height="350"></IFRAME>
- </td>
- </tr>
- <tr>
- <td align=right>
- <asp:Button id="Button1" runat="server" Text=" 提交 "></asp:Button>
- </td>
- </tr>
- <tr>
- <td>
- <asp:Label id="Label1" runat="server">此处为提交后的内容(Label)</asp:Label>
- </td>
- </tr>
- </table>
- </form>
- </body>
- </HTML>
-