この (http://postclient.codeplex.com/) dll ライブラリを Windows Phone プロジェクトに使用するにはどうすればよいですか (ログインするだけでなく)、URL 経由で Web サイトにログインする必要があります。
例: ログイン用アドレス: http://xchat.centrum.cz/~guest~/login/index.php?name=nickname&pass=password
その後、URL からのハッシュがあれば、HTML を解析したいのですが、それは長い話です。:)
手伝ってくれてありがとう。:)
編集:
私は次のようなものを見つけました:
private void Button1Clk(object sender, RoutedEventArgs e)
{
string strName = "nickname";
string strPass = "password";
UTF8Encoding encoding=new UTF8Encoding();
string postData="name="+strName;
postData += ("&pass="+strPass);
byte[] data = encoding.GetBytes(postData);
// Prepare web request...
HttpWebRequest myRequest =
(HttpWebRequest)WebRequest.Create("http://xchat.centrum.cz");
myRequest.Method = "POST";
myRequest.ContentType = "application/x-www-form-urlencoded";
Stream newStream = myRequest.GetResponse();
// Send the data.
newStream.Write(data,0,data.Length);
newStream.Close();
}
しかし、スクリプトには GetResponse(); でエラーがあります。