×Ö·û´®½ØÈ¡£¨°üÀ¨html£¬BasicPage.csÀàʹÓã©
/// <summary>
/// ½Ø¶Ï×Ö·û´®(ÖÐÎļÆÒ»¸ö×Ö·û¿í¶È£¬ÆäËü¼Æ°ë¸ö×Ö·û¿í¶È)
/// </summary>
/// <param name="input">Ðè½Ø¶ÏµÄ×Ö·û´®</param>
/// <param name="length">×Ö·û¿í¶È</param>
/// <returns>½Ø¶Ï×Ö·û´®(´ø"...")</returns>
protected string truncatedChars(string input, int length)
{
input = Server.HtmlEncode(input);
if (input.Length > length)
{
int pos = 0;
string result = "";
foreach (char chr in input)
{
if (Regex.IsMatch(chr.ToString(), "[^\x00-\xff]"))
{
pos += 2;
}
else
{
pos += 1;
}
result += chr.To
Ïà¹ØÎĵµ£º
µ±ÊäÈë ¡·Ê±×Ô¶¯²¹È« µ±ÊäÈë¡¶/ʱ×Ô¶¯²¹È«
“£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½£½
" File: closetag.vim
" Summary: Functions and mappings to close open HTML/XML tags
" Uses: <C-_> -- close matching open tag
" Author: Steven Mueller <di ......
Ö±½Ó·â×°³ÉÒ»¸öÀàµÄ£¬ÓÃÆðÀ´»¹Í¦·½±ãµÄ
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Text ......
string tent = this.TextBox_info.Text.Replace("<", "<").Replace(">", ">").Replace(" ", " ").Trim().Replace("\n", "<br/>");
& ......
Èç¹ûAJAX¼ÓÔØµÄÊý¾ÝÊÇÒ»¸öHTMLƬ¶Î£¬¶øÇÒÕâ¸öHTMLƬ¶Î»¹°üº¬½Å±¾<script>¿é£¬ÄÇôÔÚÄã°ÑÕâÊý¾ÝxmlHttp.responseTextÓÃinnerHTML·½·¨²åÈëµ½µ±Ç°ÎĵµÒ»¸öÔªËØÖУ¬Äã»á·¢ÏÖAJAX¼ÓÔØ»ØÀ´µÄ½Å±¾¸ù±¾Ã»ÓÐÖ´ÐС£ÕâÊÇAJAX¿ª·¢Öкܳ£¼ûµÄÎÊÌ⣬Èç¹ûÄã²»ÊÇÒ»Ö±ÔÚÓÃJavaScript¿ò¼Ü×ö¿ª·¢£¬ÏàÐÅÄãÔç¾Í·¢ÏÖÕâ¸öÎÊÌâÁË¡£±¾ÎÄ·ÖÎöÁËÁ ......