-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bypass basic auth or change error message #174
Comments
Due to the variety of systems the plugin can run on, I don't think it's possible to switch to a If the issue of CDNs stripping the I think there are two options to consider in the event the response is not a
@fumikito As you've experienced this issue, which of the two would you find most helpful while using the plugin? |
@peterwilsoncc Thanks for the reply! Reading #131 and #48, they are curious and I've found that the current structure is reasonable. People use WordPress in various situations. About your 2 solutions, I prefer latter:
The problem I've experienced is that the plugin told about the existence of a physical The message could be...
Such kind of an allusion can make up for the situation blow:
Hope my comment helps! |
At this part, the plugin is self-remote-requesting to check if
ads.txt
is accessible via the plugin filter by confirmingX-Ads-Txt-Generator
header information. In a success,file_exists
property is false.ads-txt/inc/admin.php
Lines 547 to 589 in 176d28d
On front-end part in admin screen,
js/admin.js
checks ifresponse.file_exist
property and display message.ads-txt/js/admin.js
Lines 31 to 36 in 176d28d
Toggle message(therefore static) is here:
ads-txt/inc/admin.php
Lines 303 to 308 in 176d28d
By the way, self-remote-request can fail in other case than existing ads.txt.
To bypassing Basic Auth, you can pass auth credentials for
wp_remote_request()
from Ajax request header. This saves me, but somehow selfish request, I guess.So, I request some changes on the plugins.
file_exists( 'path_to_file' )
)I wish send PR if welcomed.
Thanks!
The text was updated successfully, but these errors were encountered: