summaryrefslogtreecommitdiff
path: root/includes/story.inc
blob: 5d99505d690476fcb036230a16d08f317e3212a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<?

class Story {
  function Story($userid, $subject, $abstract, $article, $section, $timestamp) {
    $this->userid = $userid;
    $this->subject = $subject;
    $this->abstract = $abstract;
    $this->article = $article;
    $this->section = $section;
    $this->timestamp = $timestamp;
  }
}

function story_visible($story) {
  global $user;
  return ($story->status == 2) || ($story->status == 1 && $user->id) || user_access($user, "story");
}

?>