using System.Net;
using System.Text;
using System.IO;
protected void Page_Load(object sender, EventArgs e)
{
Encoding code = Encoding.GetEncoding("gb2312");
// 讀取模板文件
string temp = HttpContext.Current.Server.MapPath("/CSInterface/html/games.htm");
StreamReader sr = null;
string str = string.Empty;
try
{
sr = new StreamReader(temp, code);
str = sr.ReadToEnd(); // 讀取文件
}
catch (Exception exp)
{
str = "error";
sr.Close();
}
Response.Write(str);
}