Newscoop\GimmeBundle\Controller\ArticlesController::getNotConvertedLinks PHP Méthode

    private function getNotConvertedLinks($request)
    {
        $links = array();
        foreach ($request->attributes->get('links') as $idx => $link) {
            if (is_string($link)) {
                $linkParams = explode(';', trim($link));
                $resourceType = null;
                if (count($linkParams) > 1) {
                    $resourceType = trim(preg_replace('/<|>/', '', $linkParams[1]));
                    $resourceType = str_replace('"', '', str_replace('rel=', '', $resourceType));
                }
                $resource = array_shift($linkParams);
                $resource = preg_replace('/<|>/', '', $resource);
                $links[] = array('resource' => $resource, 'resourceType' => $resourceType);
            }
        }
        return $links;
    }