Exemplo n.º 1
0
 /**
  * This method returns feed item URL link.
  *
  * @return string
  */
 public function getFeedItemLink()
 {
     $parameters = $this->item->getFeedItemRouteParameters() ?: [];
     $url = $this->router->generate($this->item->getFeedItemRouteName(), $parameters, UrlGeneratorInterface::ABSOLUTE_URL);
     $anchor = (string) $this->item->getFeedItemUrlAnchor();
     if ($anchor !== '') {
         $url .= '#' . $anchor;
     }
     return $url;
 }
Exemplo n.º 2
0
 /**
  * This method returns feed item URL link
  *
  * @return string
  */
 public function getFeedItemLink()
 {
     $parameters = $this->item->getFeedItemRouteParameters() ?: array();
     $url = $this->router->generate($this->item->getFeedItemRouteName(), $parameters, true);
     $anchor = (string) $this->item->getFeedItemUrlAnchor();
     if ($anchor !== '') {
         $url .= '#' . $anchor;
     }
     return $url;
 }