SHARE
TWEET

Untitled

a guest Feb 22nd, 2019 100 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function get_projects_from_db_for_user($connect, $user){
  2.     $sql_query = 'SELECT title FROM projects WHERE user_id = ?';
  3.     $stmt = db_get_prepare_stmt($connect, $sql_query, $user);
  4.     myscli_stmt_execute($stmt);
  5.     $result = mysqli_stmt_get_result($stmt);
  6.     if($result === false) {
  7.         $error = mysqli_error($connect);
  8.         print('Ошибка MySQL:' . $error);
  9.     }
  10.     {
  11.         $result = mysqli_fetch_all($result, MYSQLI_ASSOC);
  12.     }
  13.  
  14.     return $result;
  15. };
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top