protected void Page_Load(object sender, EventArgs e) { //Place your site key and secret key here Recaptcha recaptcha = new Recaptcha("google_site_key", "google_secret_key"); googleRecaptcha.InnerHtml = recaptcha.GetSecureTokenHTML(); }
private void button1_Click(object sender, EventArgs e) { if (textBox1.Text == "") { MessageBox.Show(@"Please provide google site key!"); return; } if (textBox2.Text == "") { MessageBox.Show(@"Please provide google secret key!"); return; } Recaptcha recaptcha = new Recaptcha(textBox1.Text, textBox2.Text); textBox3.Text = recaptcha.GetSecureTokenHTML(); }
protected void Page_Load(object sender, EventArgs e) { //Place your site key and secret key here Recaptcha recaptcha = new Recaptcha("google_site_key", "google_secret_key"); googleRecaptcha.InnerHtml = recaptcha.GetSecureTokenHTML(); }