原创 ASP.net(c#) 生成html的幾種解決方案

 方案1: [複製此代碼]CODE:/// <summary > /// 傳入URL返回網頁的html代碼 /// </summary > /// <param name="Url" >URL </param > /// <returns

原创 中國省份簡稱

 北京市 京(jīng) 北京 浙江省 浙(zhè)杭州 天津市 津(jīn) 天津 安徽省 皖(wǎn) 合肥 上海市 滬(hù) 上海 福建省 閩(mǐn) 福州 重慶市 渝(yú) 重慶 江西省 贛(gàn) 南昌 香港特別行政區

原创 SQL取出第 m 條到第 n 條記錄的方法

從Table 表中取出第 m 條到第 n 條的記錄:(Not In 版本)SELECT TOP n-m+1 *   FROM Table   WHERE (id NOT IN (SELECT TOP m-1 id FROM Table )

原创 正則表達式過濾HTML危險腳本

在做一些網站(特別是bbs之類)時,經常會有充許用戶輸入html樣式代碼,卻禁止腳本的運行的需求, 以達到豐富網頁樣式,禁止惡意代碼的運行。 當然不能用 htmlencode 和 htmldecode 方法,因爲這樣連基本的html代碼會

原创 圖片載入時自動縮小效果

《!-- //有鏈接img{max-width:600px;CURSOR: hand;width:expression(onreadystatechange=function(){if(this.width>600)this.width=

原创 C# 添加文字水印類代碼

 using System; using System.Collections.Generic; using System.Text; using System.Drawing; using System.IO; using System