Skip to content
Advertisement

Tag: post

How to use AJAX to POST to PHP?

As I asked here I would like to know how I could pass the data from a simple JS function to php, and log it there. I found this answer and tried to follow it. This is my code right now (both in the …

PHP How to filter ‘in a correct way’ All $_POST variables

Using Netbeans, whenever i try to access a variable in $_POST or $_GET, i’m adviced to use something like: filter_input(INPUT_POST,’id’), for ‘safety’ (i don’t think it’s any safer than using filter_input with the default NON filter, but anyways..). This got me thinking about the answer to this post: How to grab all variables in a post (PHP) There you have:

Advertisement