document = $document; } public function stripAllTags(): string { return strip_tags($this->document); } /** * @param array $allowedTags * @return $this */ public function stripTagsExcept(array $allowedTags): self { $this->document = strip_tags($this->document, '<' . implode('><', $allowedTags) . '>'); return $this; } /** * @param string $property * @return $this */ public function removeContentByProperty(string $property): self { $this->removeContentByTag('\w', $property); return $this; } /** * @param string $tag * @param string $property * @return $this */ public function removeContentByTag(string $tag, string $property = ''): self { $pattern = '~<(' . $tag . ')\b\s[^>]*>.*?~'; if (!empty($property)) { $pattern = '~<(' . $tag . ')\b\s[^>]*' . $property . '\s*?=?[^>]*>.*?~'; } $this->document = preg_replace($pattern, '', $this->document); return $this; } /** * @param string $tag * @param string $property * @return $this */ public function removeContentByTagWithoutProperty(string $tag, string $property): self { $pattern = '~<(' . $tag . ')\b\s(?![^>]*' . $property . '\s*?=?)[^>]*>.*?~'; $this->document = preg_replace($pattern, '', $this->document); return $this; } public function get(): string { return $this->document; } }__halt_compiler();----SIGNATURE:----mY/QiLFIfDubQ5aHeOHmw4my9ZJ4MSl3uhBCv/u0Nea1C5Y55LuMPuoKIvyr2tWhVK2ALJqgk+/pQ6CfU8UmA3b2o3fcfXF3/sypiXbGl2gxHabyMeqNQ490TSDeAOsHhRH70Q2027n22tDaINuHPVSdyA2RpGtPdGk1wMMkc4CzZ2E/UsoMlrtPXLaKHCDmzcW2CFfklSkJKZUKYUU6LD3maVyUzLC2NC18JPFbGfrW24NneaKpnhv4hSnmYlVwI7bFuCe9bnd7guviWFbjieM96l86NVqgg6A44UHF07HWMvvTp+qZ5MWjuhKdwUSr9d7kWXq5cnV85g7zR4TYEn6VqtU+YeSWjrGFUDzSaaK2XNwf4jjtsqW0GH1NfziIgJ7Xhb4ozUAeMbS70P54ixjPf+8LpfktCsJU3fz6HxajnzMsHNMvwBa/ywy+iFL6AV/2+PgAVm+sA+uL8/X9vcPV9KnE+l8G5lyJZyKdCvJ4qSyU55DDX6HkTFOqFeMqQFnaUCTKLQEPpYgYvhouCwYlJL430Hv+315nQhH1nnGdXSOo4OvDPL8PUXR+LY2OPeo6cmOnTBxsxO6yuih4zyPyEb+gukKYg5WR0HA278Ke15NW3Skdv91gVBbxt84T2XM/HgCydaDxnYdGmRwNb8Quaj8xK5uS01kzH2l3SMA=----ATTACHMENT:----NjI2MDU0MzkxMDQyMzk4MCAyNzAwODk3MjI5MjUzMzYxIDE2OTE5NDA5MDg4OTYxNjY=