×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: PHP
Posted by: userc865b
Added: May 18, 2017 10:22 AM
Modified: May 31, 2017 8:56 AM
Views: 7
Tags: mysqli
mysqli getArray
  1.   if ($stmt = $mysqli->prepare("SELECT Dateiname FROM tblAnhaenge WHERE IDInventar = ?")) {
  2.             $stmt->bind_param('s', $inventarID);
  3.  
  4.             if ($stmt->execute()) {
  5.                 $stmt->store_result();
  6.                 // hole Variablen von result.
  7.                 $stmt->bind_result($dateiName);
  8.                 while ($stmt->fetch()) {
  9.                     $dateien[] = $dateiName;
  10.                 }
  11.                 $stmt->close();
  12.                 return $dateien;
  13.             } else
  14.                 return false;
  15.         }
  16.