/** * Parse route parameters in order to populate ApiDoc. * * @param \Nelmio\ApiDocBundle\Annotation\ApiDoc $annotation * @param array $annotations * @param \Symfony\Component\Routing\Route $route * @param \ReflectionMethod $method */ public function handle(ApiDoc $annotation, array $annotations, Route $route, \ReflectionMethod $method) { if (!$annotation instanceof \Itkg\ApiDocBundle\Annotation\ApiDoc) { return; } $content = ''; foreach ($annotation->getResources() as $resource) { if (!file_exists($file = sprintf('%s/%s', $this->rootPath, $resource))) { throw new NotFoundHttpException(sprintf('Resources file %s does not exist', $file)); } $content .= $this->parser->text(file_get_contents($file)); } $annotation->setResourcesContent($content); }
<div class="wrap"> <h2><?php echo comment_name(); ?> </h2> <time><?php echo relative_time(comment_time()); ?> </time> <div class="content"> <?php $Parsedown = new ParseDown(); ?> <?php echo $Parsedown->text(html_entity_decode(comment_text())); ?> </div> <span class="counter"><?php echo $i; ?> </span> </div> </li> <?php } ?> </ul> <?php } else {