/**
  * @param DOMNode $contribNode
  */
 public function parseSpecificContributions(&$contribNode)
 {
     parent::parseSpecificContributions($contribNode);
     if ($this->getFilteredOption("HIDE_MYSHARES_SECTION") !== true) {
         return;
     }
     if ($contribNode->nodeName != "client_configs") {
         return;
     }
     $actionXpath = new DOMXPath($contribNode->ownerDocument);
     $nodeList = $actionXpath->query('component_config[@className="AjxpPane::navigation_scroller"]', $contribNode);
     if (!$nodeList->length) {
         return;
     }
     $contribNode->removeChild($nodeList->item(0));
 }
Example #2
0
 public function parseSpecificContributions(&$contribNode)
 {
     parent::parseSpecificContributions($contribNode);
     if (!self::rsyncEnabled() && $contribNode->nodeName == "actions") {
         // REMOVE rsync actions, this will advertise the fact that
         // rsync is not enabled.
         $xp = new DOMXPath($contribNode->ownerDocument);
         $children = $xp->query("action[contains(@name, 'filehasher')]", $contribNode);
         foreach ($children as $child) {
             $contribNode->removeChild($child);
         }
     }
     if ($this->getFilteredOption("CACHE_XML_TREE") !== true && $contribNode->nodeName == "actions") {
         // REMOVE pre and post process on LS action
         $xp = new DOMXPath($contribNode->ownerDocument);
         $children = $xp->query("action[@name='ls']", $contribNode);
         foreach ($children as $child) {
             $contribNode->removeChild($child);
         }
     }
 }