- while (list($id, $type, $rate, $mpoi) = SQL_FETCHROW($result)) {
- $type = COMPILE_CODE($type);
- if ($points >= $mpoi) {
+ while ($content = SQL_FETCHARRAY($result)) {
+ // Compile the type
+ $content['type'] = COMPILE_CODE($content['type']);
+
+ // Are these points enougth?
+ if ($points >= $content['min_points']) {