WebClient client = new WebClient();% B6 B% Q U( f9 n
Hashtable hashtable = new Hashtable(); $ G$ V0 m" l1 j/ c* c
Encoding encoding = Encoding.UTF8; 6 U3 `! v8 S e
Stream stream = client.OpenRead("http://thebestspinner.com/?action=app_syns_date&uniq=" + GlobalCode.g_uniq); <font color="#ff0000">//这句代码很可疑呀</font> n5 `& i7 s) Q k, V D
string left = new StreamReader(stream).ReadToEnd();) s' Z) ^8 h$ b! Z; s2 d2 ]
stream.Close();* q* G4 z4 b" i: W4 N: P2 K; e
if (Conversions.ToBoolean(Operators.OrObject(Operators.CompareObjectGreater(left, GlobalCode.g_settings["syns_db_date"], false), !File.Exists(Application.LocalUserAppDataPath + @"\tbssf.dat")))) ) v+ s& T3 y: i$ ?
{ ' ]9 r5 [8 l5 p# N, J O, R
DialogResult oK;/ M8 m9 e$ }7 U
this.Show(); , V/ H% Z& Y5 C4 r. x- i! A
Application.DoEvents(); 8 @$ p) g$ w+ t* q" a8 \
if (File.Exists(Application.LocalUserAppDataPath + @"\tbssf.dat")) , H6 f) M( o3 E, [4 v/ ]# q7 {! Y
{ " _+ n5 n6 B! l: B4 e% O
oK = MessageBox.Show("A new version of the English synonyms database is available. Would you like to download it now? You will still be able to work while the new database downloads.", "Synonyms Db Update", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question); * e6 G6 c1 U9 ]' u
} # r( M) h9 V1 h
else ( P- }* b& e8 Z; b, j" S
{! A- J m6 u5 T4 ?4 W8 @) Z
oK = DialogResult.OK;) G0 c7 e8 i" S# o! d
} # a, H" N5 A u% j9 R! s) q1 [
if ((oK == DialogResult.Yes) | (oK == DialogResult.OK))1 M# h5 n% V Z
{ # k5 E: t1 N8 m) P
if (oK == DialogResult.OK)# m. m: f" u# c7 A4 w- e
{' x ?, g5 r \7 h M) Y
MessageBox.Show("The English synonyms database has not yet been installed, or has undergone a format change. Click OK to download and install the database. This usually takes less than one minute for a broadband connection, but may take longer for slower connections.\r\n\r\nYou may begin working in the software while the database downloads, but it's recommended that you wait until it's finished in order to get the most out of The Best Spinner.", "Synonyms Db", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);5 b$ s6 c" A4 h9 p4 k
}/ p+ G$ x( y/ ~7 Z' L% D# f
new Thread(new ThreadStart(this.DownloadSynsDbLaunch)).Start();* E4 a7 G2 u: `# s8 H {
}7 I& `& \# | [! B j |
} P2 f$ w9 t/ D+ P; V' q9 X
else " q& ]2 i' q* T5 j# r" @ ~/ ?
{ 9 y) {& g/ }, V2 e0 v7 a
this.status.Text = "Latest synonyms db loaded.";1 q; h) r0 u; E p$ ]$ \$ Y
5 B9 r% I W+ \, ` |1 l' C E: t . {. n0 Z! N" f 3 U: P1 Y8 J: p' O# `4 h # @* X5 ~4 ^# R; v" t9 L0 _ ) \* F8 I. a7 j3 f1 c, w下次学学怎么能渗透到服务器就好了。。。。。0 K' \% o$ Q+ [& i
8 M @) Q, J4 f4 H/ l1 }! V0 ?8 ~3 `5 V
8 ?% l' k& r6 L# q
% n6 y5 u7 D2 e- B4 o& M
* T9 h* Y. }/ o& Y3 `( }