string sa = "";
{
WebRequest wr = WebRequest.Create("http://www.lssdjt.com");
Stream s = wr.GetResponse().GetResponseStream();
StreamReader sr = new StreamReader(s, Encoding.Default);
string all = sr.ReadToEnd(); //读取网站的数据
int start = 0;
int end = 0;
while (all.Contains("<i>"))
{
start = all.IndexOf("<i>");
end = all.IndexOf("</i>");
string content = all.Substring(start + 3, end - start - 3);
all = all.Substring(end + 1, all.Length - (end + 1));
sa += content + "。 ";
}
labelHistory.text += sa;
sr.Close();
s.Close();
//Debug.LogError(content);
}
{
WebRequest wr = WebRequest.Create("http://www.lssdjt.com");
Stream s = wr.GetResponse().GetResponseStream();
StreamReader sr = new StreamReader(s, Encoding.Default);
string all = sr.ReadToEnd(); //读取网站的数据
int start = 0;
int end = 0;
while (all.Contains("<i>"))
{
start = all.IndexOf("<i>");
end = all.IndexOf("</i>");
string content = all.Substring(start + 3, end - start - 3);
all = all.Substring(end + 1, all.Length - (end + 1));
sa += content + "。 ";
}
labelHistory.text += sa;
sr.Close();
s.Close();
//Debug.LogError(content);
}