BlogEngine.NET 1.3.1.0中的搜索的小Bug的修正方法

by cleo 13. 六月 2008 19:24

 

BlogEngine.NET 1.3.1.0版本在安装完之后,如果在搜索框中搜索内容,会出现如下错误:

“/”应用程序中的服务器错误。
编译错误
说明: 在编译向该请求提供服务所需资源的过程中出现错误。请检查下列特定错误详细信息并适当地修改源代码。

编译器错误信息: CS1010: 常量中有换行符

源错误:

行 183:      text = StripHtml(content);
行 184:            if (text.Length > 200)
行 185:                text = text.Substring(0, 200) + "?;
行 186:            text = "? + text.Trim() + "?;
行 187:    }

源文件: 。。。\search.aspx.cs    行: 185

解决办法:

在根目录找到文件search.aspx.cs ,找到185行,将代码修改成如下:

行 183:      text = StripHtml(content);
行 184:            if (text.Length > 200)
行 185:                text = text.Substring(0, 200) + "?";
行 186:            text = "?" + text.Trim() + "?";
行 187:    }

即可成功搜索。

第一个打分

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

BlogEngine.NET

评论

2008-7-8 4:14:53

寂寞的风铃

那个好像出1.4了 不知道楼主 用了没有

寂寞的风铃 cn

2008-7-8 15:12:09

cleo

呵呵,你说话的时候,我正在升级

cleo cn

添加评论


(将显示你的Gravatar图标)  

  Country flag

biuquote
  • 评论
  • 在线预览
Loading



Powered by BlogEngine.NET 1.4.0.0
Theme by Mads Kristensen

About the author

cleo
Web/BI/biztalk infopath/sharepoint,呵呵。学习没有止境。。。.

Recent comments

Comment RSS

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in  anyway.

© Copyright 2008