<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<script language="javascript" src="ckeditor/ckeditor.js" type="text/javascript"></script>
<script language="javascript" src="ckfinder/ckfinder.js" type="text/javascript"></script>
<script language="javascript">
/*加载CKEditor*/
function loadCKEditor1(){
if (typeof CKEDITOR=='undefined'){
alert('Editor load failed!');
return false;
}else{
var editor1 = CKEDITOR.replace('editor1');
CKFinder.SetupCKEditor(editor1,'/ckfinder/');//与ckeditor整合载入ckfinder
}
}

window.onload = loadCKEditor1;
</script>
</head><body><div id="we"></div>
<form id="form1" name="form1" method="post" action="2.asp">
<textarea id="editor1" name="editor1" cols="80" rows="10" ></textarea>
  <table width="100%" border="0" cellspacing="0" cellpadding="0">
    <tr>
      <td>&nbsp;</td>
      <td><input type="text" name="names" /></td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td><input type="text" name="textfield2" /></td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td><input type="text" name="textfield3" /></td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td><input type="text" name="textfield4" /></td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td><input type="text" name="textfield5" /></td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td><input type="text" name="textfield6" /></td>
      <td>&nbsp;</td>
    </tr>
    <tr>
      <td>&nbsp;</td>
      <td><input type="text" name="textfield7" />
      <input type="submit" name="Submit" value="提交" /></td>
      <td>&nbsp;</td>
    </tr>
  </table>
</form>
</body>
</html>CKEditor 和 CKFinder 都是在根目录下。CKFinder.SetupCKEditor(editor1,'/ckfinder/');//与ckeditor整合载入ckfinder这一行报:对象不支持此属性或方法

解决方案 »

  1.   

    第一,看下你web.config里面的配置了没有,配置的路径对不对。
    第二,改成CKFinder.SetupCKEditor(editor1,'~/ckfinder/');//与ckeditor整合载入ckfinder
    这样看看。
    编辑器也就是这些问题了。
      

  2.   

    web.config 怎么配置啊?
    <?xml version="1.0" encoding="utf-8"?>
    <configuration>
    <appSettings>
    <!-- 
    By default the asp code will call asp.net and use the system
    temp folder to create an athentication file that can be validated,
    but in some shared hosting situations the security settings 
    in the Asp.Net side might not allow to read that file.
    In those situations, you can assign a path here (full system
    path, ex: c:\inetpub\wwwroot\userfiles\_aspNet\ )
    and put that same value in the config.asp file and it will be used
    instead of the default temp path
    -->
    <add key="CKFinderTempPath" value="/ckfinder/" />
    </appSettings>
    <system.web>
    </system.web>
    </configuration>我配置成这样了,但是还是报同样的错误。。
      

  3.   


    计算机爱好者群系列 
    计算机爱好者-C#/net 群    86594082   加群的好处 :当你有一些小问题的时候 去网上发贴 不能及时得到答案,在群里可以迅速得到答案.....能认 识一些志同道合的朋友......共同进步....... 欢迎大家进去切磋
      

  4.   

    baidu搜索FCK配置,你按照上面那个配置就可以了
      

  5.   

    路径怎么配置?源文件下载下来,
    CKFinder 和 CKEditor 都放在根目录下。
    按照我上面的路径写法,错在哪里?
    找了半天都找不到,而且还是尝试了很多其他路径,都不正确。
      

  6.   

    LZ有否遇到取纯文本的问题 。我js里在setData()方法的时候,代码不执行。
      

  7.   

    CKFinder.SetupCKEditor(editor1,'/ckfinder/');//与ckeditor整合载入ckfinder将 SetupCKEditor 改为 setupCKEditor  大小写的问题。浏览了很多网站, setup 第一个字母都大写,但是官方的手册却是 小写 ...这是一个害人的错误..