title: Symfony 2 : CSS and JS not loaded using FosUserBundle routing (Bad links)
body: <p>*Hello there, I come here cause i found 0 solutions from now ...
  I started using FosUserBundle and was enjoying the functionalities ! But cause there is a but ... :p</p>
  
  <p>When i try to go in the login page it's ok : <em>app_dev.php/login</em></p>
  
  <p>Now i try all the other links : <em>/profile - /register - /resetting</em> no one can load css and js ...</p>
  
  <p>So i search why and i find this : </p>
  
  <p>From /login i need to do <strong>../css/images</strong> or <strong>../js/vendor</strong> for exemple</p>
  
  <p>From /register or the two other links i need to do <strong>../../css/images</strong> or <strong>../../js/vendor</strong> </p>
  
  <p>Why this change ? why Symfony cannot load css and js from the same path ? It's annoying cause working like this i can't see and modify the templates easily on fosuserbundle.</p>
  
  <p>I only modified routing.yml and security.yml :</p>
  
  <pre><code># routing.yml
  fos_user_security:
      resource: "@FOSUserBundle/Resources/config/routing/security.xml"
  
  fos_user_profile:
      resource: "@FOSUserBundle/Resources/config/routing/profile.xml"
      prefix: /profile
  
  fos_user_register:
      resource: "@FOSUserBundle/Resources/config/routing/registration.xml"
      prefix: /register
  
  fos_user_resetting:
      resource: "@FOSUserBundle/Resources/config/routing/resetting.xml"
      prefix: /resetting
  
  fos_user_change_password:
      resource: "@FOSUserBundle/Resources/config/routing/change_password.xml"
      prefix: /profile
  </code></pre>
  
  <p>And then security </p>
  
  <pre><code># app/config/security.yml
  security:
  encoders:
      FOS\UserBundle\Model\UserInterface: sha512
  
  role_hierarchy:
      ROLE_ADMIN:       ROLE_USER
      ROLE_SUPER_ADMIN: ROLE_ADMIN
  
  providers:
      fos_userbundle:
          id: fos_user.user_provider.username
  
  firewalls:
      dev:
          pattern:  ^/(_(profiler|wdt)|css|images|js)/
          security: false
      main:
          pattern:          ^/
          form_login:
              check_path:   /login_check
              login_path:   /login
              provider:     fos_userbundle
          logout:
              path:         /logout
              target:       /
            # provider: fos_userbundle
            # csrf_provider: form.csrf_provider
          remember_me:
              key:         %secret%
              lifetime:    300000000
              path: /
              domain :     ~
          anonymous:        true
  
  access_control:
      - { path: ^/login$, role: IS_AUTHENTICATED_ANONYMOUSLY }
      - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY }
      - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY }
      - { path: ^/admin/, role: ROLE_ADMIN }
  </code></pre>
  
  <p>If someone have an idea or the same resolved issue ;) Thanks in advance and have a nice day !!</p>