2 /************************************************************************/
4 /************************************************************************/
5 /* Copyright (c) 2010 */
6 /* Inclusive Design Institute */
8 /* This program is free software. You can redistribute it and/or */
9 /* modify it under the terms of the GNU General Public License */
10 /* as published by the Free Software Foundation. */
11 /************************************************************************/
14 * A class for DiscussionTools
16 * http://www.imsglobal.org/profile/cc/ccv1p0/derived_schema/domainProfile_5/imsdt_v1p0_localised.xsd
18 class DiscussionTools {
20 var $title = ''; //The Forum title
21 var $text = ''; //The description of the discussion tools.
24 function DiscussionTools($title, $text){
25 $this->title = $title;
30 return htmlspecialchars(trim($this->title));
34 //change the $IMS-CC-FILEBASE$ to the base of this directory
35 //TODO: The returned value may contains HTML, ATutor doesn't check
36 // if it contains malicious javascript at this point.
37 $this->text = preg_replace('/\$IMS\-CC\-FILEBASE\$/', '', $this->text);
38 return trim(html_entity_decode($this->text));