0
votes

I installed Datatables on my Symfony2 website. Datatables installation is located in app/Resources/public/js/vendor/datatables/

In my config.yml, I declared the datatables assets:

assetic:
  debug:          "%kernel.debug%"
  use_controller: true
  #bundles:        [ ]
  java: /usr/bin/java
  filters:
    cssrewrite: ~
    cssembed:
      jar: %kernel.root_dir%/Resources/java/cssembed-0.4.5.jar
    yui_js:
      jar: %kernel.root_dir%/Resources/java/yuicompressor.jar
    less:
      node: /usr/local/bin/node
      node_paths: [/usr/local/lib/node_modules]
      apply_to: "\.less$"
  assets:
    jquery_js:
        inputs:
            - '%kernel.root_dir%/Resources/public/js/vendor/jquery.js'
        filters: [?yui_js]
    bootstrap_js:
        inputs:
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/transition.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/alert.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/modal.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/dropdown.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/scrollspy.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/tab.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/tooltip.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/popover.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/button.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/collapse.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/carousel.js'
#            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/bootstrap-typeahead.js'
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/js/affix.js'
        filters: [?yui_js]
    bootstrap_less:
        inputs:
            - '%kernel.root_dir%/../vendor/twitter/bootstrap/less/bootstrap.less'
            - '%kernel.root_dir%/Resources/public/less/snrbootstrap.less'
        filters: [less,cssembed]
    datatables_js:
        inputs:
            - '%kernel.root_dir%/Resources/public/js/vendor/datatables/js/jquery.dataTables.js' #datatables
            - '%kernel.root_dir%/Resources/public/js/vendor/datatables-bootstrap/js/datatables.bootstrap.js' #datatables
            - '%kernel.root_dir%/Resources/public/js/datatablesinit.js'
        filters: [?yui_js]
    datatables_css:
        inputs:
            - '%kernel.root_dir%/Resources/public/js/vendor/datatables/css/jquery.dataTables.css' #datatables
            - '%kernel.root_dir%/Resources/public/js/vendor/datatables-bootstrap/css/datatables.css' #datatables
        filters: [cssembed, cssrewrite]

But when I include the @datatables_css, the images still missing. I tried some assetic line commands like dump, but it doesn't change anything. My js and css assets are correctly generated in web/assets, but my images still in app/Resources/public/js/vendor/datatables/js

1

1 Answers

0
votes

Correction: Sorry, it seems to work for images ! But not for the fonts...