function removeAllElement($str, $startflag, $endflag) { while (strpos($str, $startflag, 0) > -1) { $str = removeElement($str, $startflag, $endflag); } return $str; }
/** * Remove group * * @param Slumlords\Bundle\Entity\UserGroup $group */ public function removeGroups(\Slumlords\Bundle\Entity\UserGroup $group) { $this->group - removeElement($group); }
if (!$acl->acl_check('administration', 'install', 'users', $my->usertype, $element . 's', 'all')) { mosRedirect('index2.php', _NOT_AUTH); } // map the element to the required derived class $classMap = array('component' => 'mosInstallerComponent', 'language' => 'mosInstallerLanguage', 'mambot' => 'mosInstallerMambot', 'module' => 'mosInstallerModule', 'template' => 'mosInstallerTemplate'); if (array_key_exists($element, $classMap)) { require_once $mainframe->getPath('installer_class', $element); switch ($task) { case 'uploadfile': uploadPackage($classMap[$element], $option, $element, $client); break; case 'installfromdir': installFromDirectory($classMap[$element], $option, $element, $client); break; case 'remove': removeElement($classMap[$element], $option, $element, $client); break; default: $path = $mosConfig_absolute_path . "/administrator/components/com_installer/{$element}/{$element}.php"; if (file_exists($path)) { require $path; } else { echo "Instalador não encontrado para elemento [{$element}]"; } break; } } else { echo "Instalador não disponível para elemento [{$element}]"; } /** * @param string The class name for the installer
/** * Remove Cartelera * * @param \SIEBundle\Entity\Cartelera $cartelera */ public function removeCarteleras(\SIEBundle\Entity\Cartelera $carteleras) { $this->carteleras > removeElement($carteleras); }