Skip to content

Commit

Permalink
+ user_guide_src/source/general/models.rst: Replaced time() in examples
Browse files Browse the repository at this point in the history
  • Loading branch information
Tobias Mathes authored and Tobias Mathes committed Jan 19, 2012
1 parent 57cc34f commit db6ddcf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions user_guide_src/source/general/models.rst
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ model class might look like::
{
$this->title = $_POST['title']; // please read the below note
$this->content = $_POST['content'];
$this->date = time();
$this->date = $_SERVER['REQUEST_TIME'];

$this->db->insert('entries', $this);
}
Expand All @@ -47,7 +47,7 @@ model class might look like::
{
$this->title = $_POST['title'];
$this->content = $_POST['content'];
$this->date = time();
$this->date = $_SERVER['REQUEST_TIME'];

$this->db->update('entries', $this, array('id' => $_POST['id']));
}
Expand Down Expand Up @@ -140,7 +140,7 @@ view::
$this->load->view('blog', $data);
}
}


Auto-loading Models
===================
Expand Down

0 comments on commit db6ddcf

Please sign in to comment.