Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Ref https://wordpress.stackexchange.com/questions/342767/allowed-http-origins-only-works-in-theme-functions-php
- add_action( 'send_headers', 'add_cors_http_header' );
- function add_cors_http_header()
- {
- header("Access-Control-Allow-Origin: *");
- }
Add Comment
Please, Sign In to add comment