Sublime Forum

[Feature] Complex file extensions. (*.css.php,*.js.php)

#1

In my web application user can select his own default font name and size. And I have user_settings**.css.php** file that have PHP code insertion inside it, loading these values, but the rest of file is not PHP by its essence, but CSS. The problem is that sublimetext does not recognize such complex file exensions and detect *.css.php as PHP. When I go to View-Syntax-Open all with… it detects all *.php files as CSS then. It’s a problem I request to solve - add complex extension support.

How to parse it? I think, when we have file named something.custom.extension.php, sublime must check “.custom.extension.php” first, then “.extension.php”, and then, if it will find no matches, “.php”. Such behaviour will be correct in 99,99% of cases.

P.S. I do not using cookies in my case because I need to keep user settings across the different browsers and OS. Using cookies will make code just more confusing, without any advantages of using it.

0 Likes

#2

Doubleposted it to userecho (voting for this extremely required): http://sublimetext.userecho.com/topic/79164-support-file-extensions-other-than/

0 Likes