How can I use AJAX to run a PHP file when the page is loaded, I'm trying to create a small chrome extension and need to run my PHP file however nothing seems to be working I have this so far
var req = new XMLHttpRequest();
req.open(
"GET",
"my_php_file.php",
true);
req.send(null);