mirror of
https://github.com/SophiaAtkinson/yourls-cf-turnstile.git
synced 2025-06-26 23:17:40 -07:00
fix cf_turnstile_verify.php location call
This commit is contained in:
@ -3,7 +3,7 @@
|
|||||||
Plugin Name: Cloudflare Turnstile for YOURLS Admin
|
Plugin Name: Cloudflare Turnstile for YOURLS Admin
|
||||||
Plugin URI: https://github.com/sophiaatkinson/yourls-cloudflare-turnstile
|
Plugin URI: https://github.com/sophiaatkinson/yourls-cloudflare-turnstile
|
||||||
Description: Adds Cloudflare Turnstile to the YOURLS Admin login.
|
Description: Adds Cloudflare Turnstile to the YOURLS Admin login.
|
||||||
Version: 1.0
|
Version: 1.0a
|
||||||
Author: Sophia Atkinson
|
Author: Sophia Atkinson
|
||||||
Author URI: https://sophia.wtf
|
Author URI: https://sophia.wtf
|
||||||
*/
|
*/
|
||||||
@ -42,7 +42,7 @@ function cf_turnstile_inject_script() {
|
|||||||
document.getElementById(\'cfTokenInput\').value = token;
|
document.getElementById(\'cfTokenInput\').value = token;
|
||||||
// Send the token to the verification script
|
// Send the token to the verification script
|
||||||
var xhr = new XMLHttpRequest();
|
var xhr = new XMLHttpRequest();
|
||||||
xhr.open("POST", "' . yourls_plugin_url('cf_turnstile_verify.php') . '", true);
|
xhr.open("POST", "' . yourls_plugin_url(__DIR__ . '/cf_turnstile_verify.php') . '", true);
|
||||||
xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
|
xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
|
||||||
xhr.onreadystatechange = function() {
|
xhr.onreadystatechange = function() {
|
||||||
if (xhr.readyState === XMLHttpRequest.DONE) {
|
if (xhr.readyState === XMLHttpRequest.DONE) {
|
||||||
|
Reference in New Issue
Block a user