diff options
Diffstat (limited to 'ratatoeskr')
-rw-r--r-- | ratatoeskr/sys/models.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/ratatoeskr/sys/models.php b/ratatoeskr/sys/models.php index 78ef270..892fd2e 100644 --- a/ratatoeskr/sys/models.php +++ b/ratatoeskr/sys/models.php @@ -1097,6 +1097,22 @@ class Style } /* + * Constructor: all + * Get all styles + * + * Returns: + * Array of Style objects + */ + public static function all() + { + $rv = array(); + $result = qdb("SELECT `id` FROM `PREFIX_styles` WHERE 1"); + while($sqlrow = mysql_fetch_assoc($result)) + $rv[] = self::by_id($sqlrow["id"]); + return $rv; + } + + /* * Function: save * Save changes to database. */ |