Manually highlight syntax as CSS in PHP file?

I have a dynamically generated style-sheet, which uses a .php extension. However, I want to use CSS syntax highlighting and formatting on this file. How can I achieve this? I don't want all php files to be highlighted as CSS, just this one, named style.php located in the web root of my project. Thanks!

- Dan

2 comments
Comment actions Permalink

Hi Dan,

  1. Settings | Template Data Languages
  2. Find your file in a tree there and assign "CSS" in 2nd column for it
0
Comment actions Permalink

Thank you! That was really bugging me. I figured it would be pretty easy, I just didn't know where to look. PHPStorm is awesome!

0

Please sign in to leave a comment.