diff --git a/routing/scheme.rst b/routing/scheme.rst index b7a41299c94..2f92232ee48 100644 --- a/routing/scheme.rst +++ b/routing/scheme.rst @@ -10,6 +10,25 @@ the URI scheme via schemes: .. configuration-block:: + .. code-block:: php-annotations + + // src/AppBundle/Controller/MainController.php + namespace AppBundle\Controller; + + use Symfony\Bundle\FrameworkBundle\Controller\Controller; + use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route; + + class MainController extends Controller + { + /** + * @Route("/secure", name="secure", schemes={"https"}) + */ + public function secureAction() + { + // ... + } + } + .. code-block:: yaml # app/config/routing.yml