summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'shared/classes/0sql_row_obj.php')
-rw-r--r--shared/classes/0sql_row_obj.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/shared/classes/0sql_row_obj.php b/shared/classes/0sql_row_obj.php
index 4efacbd..30fe479 100644
--- a/shared/classes/0sql_row_obj.php
+++ b/shared/classes/0sql_row_obj.php
@@ -277,7 +277,7 @@ abstract class sql_row_obj { // If the name of this class changes, it must be up
return $cols_filled;
}
// Writes the object's data to the database, either by UPDATE or INSERT
- function write() {
+ public function write() {
$q=($this->is_in_db()?'UPDATE':'INSERT INTO').' `'.$this->table.'` SET ';
$i=0; // Number of columns we've set so far
$to_change=array();
@@ -310,14 +310,14 @@ abstract class sql_row_obj { // If the name of this class changes, it must be up
return $r;
}
// (Re-)Loads data from the database
- function load() {
+ public function load() {
if ($this->is_in_db()) {
$r=self::sql_query('SELECT * FROM `'.$this->table.'` WHERE '.$this->sql_id());
$this->from_array($r->fetch(PDO::FETCH_ASSOC), true);
}
}
// Deletes this row from the database and clears db_values array
- function delete() {
+ public function delete() {
if ($this->is_in_db()) {
self::sql_query('DELETE FROM `'.$this->table.'` WHERE '.$this->sql_id());
$this->db_values=array();