Forum.class.php 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. require_once 'Resource.class.php';
  4. /**
  5. * Class forum
  6. * @author Bart Mollet <bart.mollet@hogent.be>
  7. * @package chamilo.backup
  8. */
  9. class Forum extends Resource
  10. {
  11. /**
  12. * The title
  13. */
  14. var $title;
  15. /**
  16. * The description
  17. */
  18. var $description;
  19. /**
  20. * Category-id
  21. */
  22. var $category_id;
  23. /**
  24. * Last post
  25. */
  26. var $last_post;
  27. /**
  28. * Number of threads
  29. */
  30. var $topics;
  31. /**
  32. * Number of posts
  33. */
  34. var $posts;
  35. /**
  36. * Allow anonimous
  37. */
  38. var $allow_anonymous;
  39. /**
  40. * Allow edit
  41. */
  42. var $allow_edit;
  43. /**
  44. * Approval direct post
  45. */
  46. var $approval_direct_post;
  47. /**
  48. * Allow attachments
  49. */
  50. var $allow_attachements;
  51. /**
  52. * Allow new threads
  53. */
  54. var $allow_new_topics;
  55. /**
  56. * Default view
  57. */
  58. var $default_view;
  59. /**
  60. * Group forum
  61. */
  62. var $of_group;
  63. /**
  64. * Public/private group forum
  65. */
  66. var $group_public_private;
  67. /**
  68. * Order
  69. */
  70. var $order;
  71. /**
  72. * Locked or not
  73. */
  74. var $locked;
  75. /**
  76. * Session id
  77. */
  78. var $session_id;
  79. /**
  80. * Image
  81. */
  82. var $image;
  83. /**
  84. * Create a new Forum
  85. */
  86. /* function Forum($id, $title, $description, $category_id, $last_post, $topics, $posts, $allow_anonymous, $allow_edit, $approval_direct_post, $allow_attachements,
  87. $allow_new_topics, $default_view, $of_group, $group_public_private, $order, $locked, $session_id, $image)
  88. { */
  89. function Forum($obj) {
  90. parent::Resource($obj->forum_id, RESOURCE_FORUM);
  91. $this->obj = $obj;
  92. /*
  93. $this->title = $title;
  94. $this->description = $description;
  95. $this->category_id = $category_id;
  96. $this->last_post = $last_post;
  97. $this->topics = $topics;
  98. $this->posts = $posts;
  99. $this->allow_anonymous = $allow_anonymous;
  100. $this->allow_edit = $allow_edit;
  101. $this->approval_direct_post = $approval_direct_post;
  102. $this->allow_attachements = $allow_attachements;
  103. $this->allow_new_topics = $allow_new_topics;
  104. $this->default_view = $default_view;
  105. $this->of_group = $of_group;
  106. $this->group_public_private = $group_public_private;
  107. $this->order = $order;
  108. $this->locked = $locked;
  109. $this->session_id = $session_id;
  110. $this->image = $image; */
  111. }
  112. /**
  113. * Show this resource
  114. */
  115. function show() {
  116. parent::show();
  117. echo $this->obj->forum_title;
  118. }
  119. }