neilime / zf2-assets-bundle

AssetsBundle is a module for Zend Framework 2 allowing asset managment (bundling & caching)
https://neilime.github.io/zf2-assets-bundle/
MIT License
33 stars 20 forks source link

Can php output in develop be cached? #62

Closed chielsen closed 5 years ago

chielsen commented 7 years ago

I have a php script that should output JS code. This works fine in production and is cached. However on development the actual php coded is copied and not the output. Since I use__DIR__, my script now cannot find the files it needs.

2 questions:

  1. is there a way i can use the __DIR__ of the original file?
  2. can the output of the script be cached? this would also work
neilime commented 5 years ago

You can use .php files as assets, there will be interpret, there cached if the file is not modified