Re: [PHP] Ajax and PHP: XMLHTTP
Micky Hulse wrote:
> <?=$_SERVER['PHP_SELF']?>
>
> Can I replace the above with some sort of XMLHTTP request?
>
As noted, that's a javascript question. However your PHP code is
vulnerable to XSS attacks; you should at least encode the output with
htmlspecialchars() so that URLs like
"foo.php/<script>alert('hi');</script>" are safe.
eg. <?php echo htmlspecialchars($_SERVER['PHP_SELF']); ?>
Arpad
|