Created
November 27, 2014 09:59
-
-
Save nikcub/84f01e51e852e89f26e0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ids = array_map('trim', $_POST['ids']); | |
$ids = array_map('intval', $ids); | |
$ids = implode(',', array_values($ids)); | |
$db->query("SELECT * from table where id IN(" . $ids . ")"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment