diff options
author | Joseph Hunkeler <jhunkeler@gmail.com> | 2011-04-17 20:13:07 -0400 |
---|---|---|
committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2011-04-17 20:13:07 -0400 |
commit | 0077cb99704fe863cf731fc5cab792af2ede96c2 (patch) | |
tree | dd68f44971aa2aee821f588d33b250dcd2fe57e3 /modules/rudi/includes/information.class.php | |
parent | e8b28c5e910d92cbec3d4baa6e98f025e8418d28 (diff) | |
download | bayonetcms-0077cb99704fe863cf731fc5cab792af2ede96c2.tar.gz |
Backporting retarded amount of changes outside of version control
Diffstat (limited to 'modules/rudi/includes/information.class.php')
-rw-r--r-- | modules/rudi/includes/information.class.php | 66 |
1 files changed, 33 insertions, 33 deletions
diff --git a/modules/rudi/includes/information.class.php b/modules/rudi/includes/information.class.php index 2632675..d34c4aa 100644 --- a/modules/rudi/includes/information.class.php +++ b/modules/rudi/includes/information.class.php @@ -1,34 +1,34 @@ -<?php
-
-class RUDI_Information extends RUDI_Common
-{
- public function __construct()
- {
- global $db;
- $this->db = $db;
- }
-
- public function Unit($unit_id)
- {
- $query = sprintf("SELECT leader_id, name, logo, url, creed, bio
- FROM rudi_units
- WHERE unit_id = %d", (int)$unit_id);
- $result = $this->db->Query($query);
- $unit = $this->db->FetchObject($result, 'UnitInfo', true);
- return $unit;
- }
-
- public function Platoon($unit_id, $platoon_id)
- {
- $query = sprintf("SELECT leader_id, name, logo, creed, bio
- FROM rudi_platoons
- WHERE unit_id = %d AND platoon_id = %d", (int)$unit_id, (int)$platoon_id);
- $result = $this->db->Query($query);
- $platoon = $this->db->FetchObject($result, 'UnitInfo', true);
- decho($platoon);
-
- return $platoon;
- }
-}
-
+<?php + +class RUDI_Information extends RUDI_Common +{ + public function __construct() + { + global $db; + $this->db = $db; + } + + public function Unit($unit_id) + { + $query = sprintf("SELECT leader_id, name, logo, url, creed, bio + FROM rudi_units + WHERE unit_id = %d", (int)$unit_id); + $result = $this->db->Query($query); + $unit = $this->db->FetchObject($result, 'UnitInfo', true); + return $unit; + } + + public function Platoon($unit_id, $platoon_id) + { + $query = sprintf("SELECT leader_id, name, logo, creed, bio + FROM rudi_platoons + WHERE unit_id = %d AND platoon_id = %d", (int)$unit_id, (int)$platoon_id); + $result = $this->db->Query($query); + $platoon = $this->db->FetchObject($result, 'UnitInfo', true); + decho($platoon); + + return $platoon; + } +} + ?>
\ No newline at end of file |