parent
be1e996a69
commit
2fef24f7ab
@ -1,50 +0,0 @@ |
||||
<?php |
||||
/* For licensing terms, see /license.txt */ |
||||
|
||||
/** |
||||
* @todo move the tool constants to the appropriate place |
||||
* @todo make config settings out of $forum_setting |
||||
* |
||||
* @author Patrick Cool <patrick.cool@UGent.be>, Ghent University |
||||
* |
||||
* @version february 2006, dokeos 1.8 |
||||
*/ |
||||
|
||||
/* |
||||
Database Variables |
||||
*/ |
||||
$table_categories = Database::get_course_table(TABLE_FORUM_CATEGORY); |
||||
$table_forums = Database::get_course_table(TABLE_FORUM); |
||||
$table_threads = Database::get_course_table(TABLE_FORUM_THREAD); |
||||
$table_posts = Database::get_course_table(TABLE_FORUM_POST); |
||||
$table_mailcue = Database::get_course_table(TABLE_FORUM_MAIL_QUEUE); |
||||
$table_threads_qualify = Database::get_course_table( |
||||
TABLE_FORUM_THREAD_QUALIFY |
||||
); |
||||
$table_threads_qualify_historical = Database::get_course_table( |
||||
TABLE_FORUM_THREAD_QUALIFY_LOG |
||||
); |
||||
|
||||
$forum_table_attachment = Database::get_course_table(TABLE_FORUM_ATTACHMENT); |
||||
$table_item_property = Database::get_course_table(TABLE_ITEM_PROPERTY); |
||||
$table_users = Database::get_main_table(TABLE_MAIN_USER); |
||||
|
||||
/* |
||||
Some configuration settings |
||||
(these can go to the dokeos config settings afterwards) |
||||
*/ |
||||
// if this setting is true then an I-frame will be displayed when replying |
||||
$forum_setting['show_thread_iframe_on_reply'] = true; |
||||
// if this setting is true then students and teachers can check a checkbox so |
||||
// that they receive a mail when somebody replies to the thread |
||||
$forum_setting['allow_post_notification'] = true; |
||||
// when this setting is true then the course admin can post threads that |
||||
// are important. These posts remain on top all the time (until made unsticky) |
||||
// these special posts are indicated with a special icon also |
||||
$forum_setting['allow_sticky'] = true; |
||||
// when this setting is true there will be a column that displays the |
||||
// latest post (date and poster) of the given forum. |
||||
// This requires quite some sql statements that might slow down the page with the fora. |
||||
// note: I'm currently investigating how it would be possible to increase |
||||
// the performance of this part. |
||||
$forum_setting['show_last_post'] = false; |
||||
@ -1,89 +1,86 @@ |
||||
<?php |
||||
|
||||
/** |
||||
* Contains information for a SOAP fault. |
||||
* Mainly used for returning faults from deployed functions |
||||
* in a server instance. |
||||
* @author Dietrich Ayala <dietrich@ganx4.com> |
||||
* @version $Id: class.soap_fault.php,v 1.14 2007/04/11 15:49:47 snichol Exp $ |
||||
* @access public |
||||
*/ |
||||
class nusoap_fault extends nusoap_base |
||||
{ |
||||
/** |
||||
* The fault code (client|server) |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $faultcode; |
||||
/** |
||||
* The fault actor |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $faultactor; |
||||
/** |
||||
* The fault string, a description of the fault |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $faultstring; |
||||
/** |
||||
* The fault detail, typically a string or array of string |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $faultdetail; |
||||
|
||||
/** |
||||
* constructor |
||||
* |
||||
* @param string $faultcode (SOAP-ENV:Client | SOAP-ENV:Server) |
||||
* @param string $faultactor only used when msg routed between multiple actors |
||||
* @param string $faultstring human readable error message |
||||
* @param mixed $faultdetail detail, typically a string or array of string |
||||
*/ |
||||
public function __construct($faultcode,$faultactor='',$faultstring='',$faultdetail=''){ |
||||
parent::__construct(); |
||||
$this->faultcode = $faultcode; |
||||
$this->faultactor = $faultactor; |
||||
$this->faultstring = $faultstring; |
||||
$this->faultdetail = $faultdetail; |
||||
} |
||||
|
||||
/** |
||||
* serialize a fault |
||||
* |
||||
* @return string The serialization of the fault instance. |
||||
* @access public |
||||
*/ |
||||
function serialize(){ |
||||
$ns_string = ''; |
||||
foreach($this->namespaces as $k => $v){ |
||||
$ns_string .= "\n xmlns:$k=\"$v\""; |
||||
} |
||||
$return_msg = |
||||
'<?xml version="1.0" encoding="'.$this->soap_defencoding.'"?>'.
|
||||
'<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"'.$ns_string.">\n". |
||||
'<SOAP-ENV:Body>'. |
||||
'<SOAP-ENV:Fault>'. |
||||
$this->serialize_val($this->faultcode, 'faultcode'). |
||||
$this->serialize_val($this->faultactor, 'faultactor'). |
||||
$this->serialize_val($this->faultstring, 'faultstring'). |
||||
$this->serialize_val($this->faultdetail, 'detail'). |
||||
'</SOAP-ENV:Fault>'. |
||||
'</SOAP-ENV:Body>'. |
||||
'</SOAP-ENV:Envelope>'; |
||||
return $return_msg; |
||||
} |
||||
} |
||||
|
||||
/** |
||||
* Backward compatibility |
||||
*/ |
||||
class soap_fault extends nusoap_fault |
||||
{ |
||||
} |
||||
|
||||
|
||||
?> |
||||
<?php |
||||
|
||||
/** |
||||
* Contains information for a SOAP fault. |
||||
* Mainly used for returning faults from deployed functions |
||||
* in a server instance. |
||||
* @author Dietrich Ayala <dietrich@ganx4.com> |
||||
* @version $Id: class.soap_fault.php,v 1.14 2007/04/11 15:49:47 snichol Exp $ |
||||
* @access public |
||||
*/ |
||||
class nusoap_fault extends nusoap_base |
||||
{ |
||||
/** |
||||
* The fault code (client|server) |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $faultcode; |
||||
/** |
||||
* The fault actor |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $faultactor; |
||||
/** |
||||
* The fault string, a description of the fault |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $faultstring; |
||||
/** |
||||
* The fault detail, typically a string or array of string |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $faultdetail; |
||||
|
||||
/** |
||||
* constructor |
||||
* |
||||
* @param string $faultcode (SOAP-ENV:Client | SOAP-ENV:Server) |
||||
* @param string $faultactor only used when msg routed between multiple actors |
||||
* @param string $faultstring human readable error message |
||||
* @param mixed $faultdetail detail, typically a string or array of string |
||||
*/ |
||||
public function __construct($faultcode,$faultactor='',$faultstring='',$faultdetail=''){ |
||||
parent::__construct(); |
||||
$this->faultcode = $faultcode; |
||||
$this->faultactor = $faultactor; |
||||
$this->faultstring = $faultstring; |
||||
$this->faultdetail = $faultdetail; |
||||
} |
||||
|
||||
/** |
||||
* serialize a fault |
||||
* |
||||
* @return string The serialization of the fault instance. |
||||
* @access public |
||||
*/ |
||||
function serialize(){ |
||||
$ns_string = ''; |
||||
foreach($this->namespaces as $k => $v){ |
||||
$ns_string .= "\n xmlns:$k=\"$v\""; |
||||
} |
||||
$return_msg = |
||||
'<?xml version="1.0" encoding="'.$this->soap_defencoding.'"?>'.
|
||||
'<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"'.$ns_string.">\n". |
||||
'<SOAP-ENV:Body>'. |
||||
'<SOAP-ENV:Fault>'. |
||||
$this->serialize_val($this->faultcode, 'faultcode'). |
||||
$this->serialize_val($this->faultactor, 'faultactor'). |
||||
$this->serialize_val($this->faultstring, 'faultstring'). |
||||
$this->serialize_val($this->faultdetail, 'detail'). |
||||
'</SOAP-ENV:Fault>'. |
||||
'</SOAP-ENV:Body>'. |
||||
'</SOAP-ENV:Envelope>'; |
||||
return $return_msg; |
||||
} |
||||
} |
||||
|
||||
/** |
||||
* Backward compatibility |
||||
*/ |
||||
class soap_fault extends nusoap_fault |
||||
{ |
||||
} |
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -1,107 +1,105 @@ |
||||
<?php |
||||
|
||||
|
||||
|
||||
|
||||
/** |
||||
* For creating serializable abstractions of native PHP types. This class |
||||
* allows element name/namespace, XSD type, and XML attributes to be |
||||
* associated with a value. This is extremely useful when WSDL is not |
||||
* used, but is also useful when WSDL is used with polymorphic types, including |
||||
* xsd:anyType and user-defined types. |
||||
* |
||||
* @author Dietrich Ayala <dietrich@ganx4.com> |
||||
* @version $Id: class.soap_val.php,v 1.11 2007/04/06 13:56:32 snichol Exp $ |
||||
* @access public |
||||
*/ |
||||
class soapval extends nusoap_base { |
||||
/** |
||||
* The XML element name |
||||
* |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $name; |
||||
/** |
||||
* The XML type name (string or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $type; |
||||
/** |
||||
* The PHP value |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $value; |
||||
/** |
||||
* The XML element namespace (string or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $element_ns; |
||||
/** |
||||
* The XML type namespace (string or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $type_ns; |
||||
/** |
||||
* The XML element attributes (array or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $attributes; |
||||
|
||||
/** |
||||
* constructor |
||||
* |
||||
* @param string $name optional name |
||||
* @param mixed $type optional type name |
||||
* @param mixed $value optional value |
||||
* @param mixed $element_ns optional namespace of value |
||||
* @param mixed $type_ns optional namespace of type |
||||
* @param mixed $attributes associative array of attributes to add to element serialization |
||||
* @access public |
||||
*/ |
||||
function __construct($name='soapval',$type=false,$value=-1,$element_ns=false,$type_ns=false,$attributes=false) { |
||||
parent::__construct(); |
||||
$this->name = $name; |
||||
$this->type = $type; |
||||
$this->value = $value; |
||||
$this->element_ns = $element_ns; |
||||
$this->type_ns = $type_ns; |
||||
$this->attributes = $attributes; |
||||
} |
||||
|
||||
/** |
||||
* return serialized value |
||||
* |
||||
* @param string $use The WSDL use value (encoded|literal) |
||||
* @return string XML data |
||||
* @access public |
||||
*/ |
||||
function serialize($use='encoded') { |
||||
return $this->serialize_val($this->value, $this->name, $this->type, $this->element_ns, $this->type_ns, $this->attributes, $use, true); |
||||
} |
||||
|
||||
/** |
||||
* decodes a soapval object into a PHP native type |
||||
* |
||||
* @return mixed |
||||
* @access public |
||||
*/ |
||||
function decode(){ |
||||
return $this->value; |
||||
} |
||||
} |
||||
|
||||
|
||||
|
||||
|
||||
?> |
||||
<?php |
||||
|
||||
/** |
||||
* For creating serializable abstractions of native PHP types. This class |
||||
* allows element name/namespace, XSD type, and XML attributes to be |
||||
* associated with a value. This is extremely useful when WSDL is not |
||||
* used, but is also useful when WSDL is used with polymorphic types, including |
||||
* xsd:anyType and user-defined types. |
||||
* |
||||
* @author Dietrich Ayala <dietrich@ganx4.com> |
||||
* @version $Id: class.soap_val.php,v 1.11 2007/04/06 13:56:32 snichol Exp $ |
||||
* @access public |
||||
*/ |
||||
class soapval extends nusoap_base |
||||
{ |
||||
/** |
||||
* The XML element name |
||||
* |
||||
* @var string |
||||
* @access private |
||||
*/ |
||||
var $name; |
||||
/** |
||||
* The XML type name (string or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $type; |
||||
/** |
||||
* The PHP value |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $value; |
||||
/** |
||||
* The XML element namespace (string or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $element_ns; |
||||
/** |
||||
* The XML type namespace (string or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $type_ns; |
||||
/** |
||||
* The XML element attributes (array or false) |
||||
* |
||||
* @var mixed |
||||
* @access private |
||||
*/ |
||||
var $attributes; |
||||
|
||||
/** |
||||
* constructor |
||||
* |
||||
* @param string $name optional name |
||||
* @param mixed $type optional type name |
||||
* @param mixed $value optional value |
||||
* @param mixed $element_ns optional namespace of value |
||||
* @param mixed $type_ns optional namespace of type |
||||
* @param mixed $attributes associative array of attributes to add to element serialization |
||||
* @access public |
||||
*/ |
||||
function __construct($name='soapval',$type=false,$value=-1,$element_ns=false,$type_ns=false,$attributes=false) { |
||||
parent::__construct(); |
||||
$this->name = $name; |
||||
$this->type = $type; |
||||
$this->value = $value; |
||||
$this->element_ns = $element_ns; |
||||
$this->type_ns = $type_ns; |
||||
$this->attributes = $attributes; |
||||
} |
||||
|
||||
/** |
||||
* return serialized value |
||||
* |
||||
* @param string $use The WSDL use value (encoded|literal) |
||||
* @return string XML data |
||||
* @access public |
||||
*/ |
||||
function serialize($use='encoded') { |
||||
return $this->serialize_val($this->value, $this->name, $this->type, $this->element_ns, $this->type_ns, $this->attributes, $use, true); |
||||
} |
||||
|
||||
/** |
||||
* decodes a soapval object into a PHP native type |
||||
* |
||||
* @return mixed |
||||
* @access public |
||||
*/ |
||||
function decode(){ |
||||
return $this->value; |
||||
} |
||||
} |
||||
|
||||
|
||||
|
||||
|
||||
?> |
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in new issue