Module documentation
Page: 1
Is there any actual on modules, such as events, properties, functions, etc? How about display modifiers, such as adding a new field to the ticket add/edit form (making use of integer_field_2)? One thing I would like to do is require a certain project's tickets to always have a category. I could do this via editing of _ticket_form.tpl and Ticket.class.php, but could not work out any module magics.
Could theoretically bastardize the object overloading __call, __callstatic, __set, and __get methods to create modifiable classes, but that may come at a performance cost. For function calls, you'd not really be able to handle private/public, as the functions wouldn't be enclosed in the class. The class reference to the function, however, could be treated as either/or. The downside is that you'd need to re-extend each time you new(). As an example:
class Test {
private $functions = array();
private $objects = array();
private $variables = array();
public function extend($funcname,$function) {
$this->functions[$funcname] = $function;
}
public function __call($func,$args) {
if (isset($this->functions[$func])) {
return $this->functions[$func]($args);
}
}
}
function joe() {
echo "hi";
}
$n = new Test();
$n->extend("bob","joe");
$n->bob();
Indeed, Javascript is way more 'powerful' as a base language. You can modify a class once and have it effective for all future uses of it. It loses out on the lack of a good server side implementation.
As an aside, are the supported tags (quote/code/etc) documented anywhere?
As an aside, are the supported tags (quote/code/etc) documented anywhere?



