I read a good practice for storing php files containing a potential security risk outside the root directory.
Now I have php files containing material for registration / login. They are located outside the root directory. Now I will catch the contents of the form via jquery and submit it to this php file.
But this is not possible with js / jquery:
$.ajax({
type: "POST",
url: "../php_includes/register.inc.php",
data: data,
})
.done(function(data, status) {
});
Am I having a design error or is something wrong?
What is the "best practice" here?
source
share