-2

Im receiving the following error:

Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given 
Jacob
  • 35
  • 8

2 Answers2

0
  1. $getholidays isnt the result of getholidayrequest()

or

  1. from the documentation: mysql_query() will also fail and return FALSE if the user does not have permission to access the table(s) referenced by the query
Bartłomiej Wach
  • 1,968
  • 1
  • 11
  • 17
0

you should check the mysql_query return value

$result = mysql_query('SELECT * WHERE 1=1');
if (!$result) {
    die('Requête invalide : ' . mysql_error());
}
Oussama Elgoumri
  • 609
  • 1
  • 5
  • 15