Boolean given help

Sab

I love milfs.
Jun 25, 2011
1,212
136
I get this error in my housekeeping:

Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\app\tpl\skins\Custom-Habbo\hk\jobs.html on line 43

This is the link 43 in HK:


Code:
 $getMySQL = mysql_query("SELECT * FROM `jobs` ");                    $alternate = 1;                    while ($data = mysql_fetch_array($getMySQL)) {                        if($alternate == 0) {                        $alternate = 1;                        echo "<tr style=\"background-color: #4FD9EF;\">";                        echo "<td style=\"width: 12.5%;background-color: #4FD9EF;\">" . $data['username'] . "</td>";                        echo "<td style=\"width: 12.5%;background-color: #4FD9EF;\">" . $data['job'] . "</td>";                        echo "<td style=\"width: 37.5%;background-color: #4FD9EF;\">" . $data['why'] . "</td>";                        echo "<td style=\"width: 20%;background-color: #4FD9EF;\">" . $data['experience'] . "</td>";                        echo "<td style=\"width: 30%;background-color: #4FD9EF;\">" . $data['age'] .  "</td>";                        echo "<td style=\"width: 30%;background-color: #4FD9EF;\">" . $data['other'] .  "</td>";                                                                                                echo "</tr>";                        }                        else if($alternate == 1) {                        $alternate = 0;                                                echo "<tr style=\"background-color: #2DB8CD;\">";                        echo "<td style=\"width: 12.5%;background-color: #4FD9EF;\">" . $data['username'] . "</td>";                        echo "<td style=\"width: 12.5%;background-color: #4FD9EF;\">" . $data['job'] . "</td>";                        echo "<td style=\"width: 37.5%;background-color: #4FD9EF;\">" . $data['why'] . "</td>";                        echo "<td style=\"width: 20%;background-color: #4FD9EF;\">" . $data['experience'] . "</td>";                        echo "<td style=\"width: 30%;background-color: #4FD9EF;\">" . $data['age'] .  "</td>";                        echo "<td style=\"width: 30%;background-color: #4FD9EF;\">" . $data['other'] .  "</td>";                        echo "</tr>";                        }                    }                ?> </table> </p></div> </div>


It's all 1 line, just looks like that on here. (I'm not so good at coding)
 

TyleRJc

Member
Jun 19, 2011
67
12
Hmm, I suck at coding brother.

Think you can make me one?

PHP:
CREATE TABLE IF NOT EXISTS `jobs` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `username` varchar(100) NOT NULL,
  `job` varchar(100) NOT NULL,
  `why` text NOT NULL,
  `experience` text NOT NULL,
  `age` varchar(100) NOT NULL,
  `other` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
 

Sab

I love milfs.
Jun 25, 2011
1,212
136
PHP:
CREATE TABLE IF NOT EXISTS `jobs` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `username` varchar(100) NOT NULL,
  `job` varchar(100) NOT NULL,
  `why` text NOT NULL,
  `experience` text NOT NULL,
  `age` varchar(100) NOT NULL,
  `other` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

Thanks, brother! You did it. -gives cookie!-
 

Users who are viewing this thread

Top