phpMv  -UI toolkit 2.4.12
jQuery, jQuery UI, Twitter Bootstrap and Semantic-UI library for php & php MVC Frameworks
NavElementTrait.php
Go to the documentation of this file.
1 <?php
3 use Ajax\JsUtils;
5 
13 
14  abstract public function contentAsString();
19  public function jsSetContent(JsUtils $jsUtils){
20  $jsUtils->html("#".$this->identifier,str_replace("\"","'", $this->contentAsString()),true);
21  }
22 
23  public function getRoot() {
24  return $this->root;
25  }
26  public function setRoot($root) {
27  $this->root = $root;
28  return $this;
29  }
30  public function getAttr() {
31  return $this->attr;
32  }
33 
39  public function setAttr($attr) {
40  $this->attr = $attr;
41  return $this;
42  }
43 
44  public function __call($method, $args) {
45  if(isset($this->$method) && is_callable($this->$method)) {
46  return call_user_func_array(
47  $this->$method,
48  $args
49  );
50  }
51  }
52 
53  abstract public function fromDispatcher(JsUtils $js,$dispatcher,$startIndex=0);
54 }
fromDispatcher(JsUtils $js, $dispatcher, $startIndex=0)
JQuery PHP library.
Definition: JsUtils.php:23
setAttr($attr)
Define the html attribute for each element url in ajax.
attr($element='this', $attributeName='id', $value="", $immediatly=false)
Get or set the value of an attribute for the first element in the set of matched elements or set one ...
jsSetContent(JsUtils $jsUtils)
Generate the jquery script to set the elements to the HtmlNavElement.