0
I am receiving data from a form, and has a field that is comes in array from $_POST
that is so:
Array
(
[image_ids] => Array
(
[0] => 831
[1] => 789
)
)
And I want to take the amount by filter_input
in this way:
$images = filter_input(INPUT_POST, 'image_ids');
and I can’t, does anyone have any idea how I take these values?
NOTE: the image variable returns False
when I give var_dump
Why can’t you? Make a mistake? What is the final value of
$images
?– Woss
It returns false
– Lukan Dos Santos Pinto
Have you tried with the filter
FILTER_REQUIRE_ARRAY
?– Woss
No, I’ll test now that you’ve spoken
– Lukan Dos Santos Pinto
@Andersoncarloswoss put so and still came as false:
– Lukan Dos Santos Pinto
filter_input(INPUT_POST, 'image_ids', FILTER_REQUIRE_ARRAY)
– Lukan Dos Santos Pinto