实现编辑模式 ubb / FCKeditor 切换

2006年6月13日 | 分类: ASP | 标签:

         很长一段时间没有更新blog 了,总是处在一种忙的状态,终于把blog 从 div_blog 一路转成了pblog, pblog 实在一个相当不错的blog 程序,虽然还在一些不完善的地方,但小小的瑕疵不能否定它的出。所以恢复日专的更新先从pblog 的修改开始了。
  
       
   实现编辑模式 ubb / FCKeditor 切换的代码很简单就不给说明了。

 1,修改blogedit.asp
     1.1 在18行 logid=Trim(CheckStr(Request("id"))) 下加入
log_edittype = request.QueryString("log_edittype")
action = request.QueryString("action")
if action = "edittype" then
   log_edittype = right((log_edittype-1),1)
   sql = "update blog_content set log_edittype="&log_edittype&" where log_id = "&logid&""
  ‘response.write sql
   ‘response.end
   set rs = conn.execute(sql)
   set rs = nothing
   rs.close
   response.wrtie "<script> location.reload;</script>"
end if 
  

   1.2 在246 行
else
      UBB_TextArea_Height="200px;"
      UBB_Msg_Value=UBBFilter(UnCheckStr(lArticle.logMessage))
      UBBeditor("Message")
    end if
    %></td>
             </tr>
下加入
     <tr>
              <td  align="right" valign="top"><span style="font-weight: bold">编辑模式:</span></td>
              <td colspan="2" align="center"><a href="?id=<%=logid%>&action=edittypechange&log_edittype=<%=log_editType%>">编辑模式切换</a></td>
            </tr>

目前还没有任何评论.