6
votes

Basically my issue is when I set the text mode to PHP my HTML is losing it's syntax highlighting whilst using the Material colour theme. It highlights all HTML as white and if i switch to HTML it highlight all PHP as white. This issue started yesterday after upgrading to Sublime build 3103. Anyone know how to fix it?

PHP syntax highlighted

HTML syntax highlighted

Cheers

2
I think this kind of questions should not be asked on stackoverflow. unrelated. - Stichoza
@Stichoza From What topics can I ask about here? in the help center, software questions are allowed if they cover "[...] software tools commonly used by programmers". Sublime Text, like vim, emacs, Notepad++, etc., is a programming editor, and there are tens of thousands of questions about them on this site that are perfectly on-topic. - MattDMo
For users here in 2017+, this issue was fixed in build 3120. If your php syntax highlighting in sublime is non-existent or wonky, it is a separate issue from the one here. - Ben Schenerman

2 Answers

3
votes

There is a thread on Sublime forum about this, it should be fixed in next development version. You could maybe downgrade to a working version until its fixed properly.

https://forum.sublimetext.com/t/php-detection-broken-in-3103/17355

-1
votes

Follow these Steps-

  1. Uninstall sublime text
  2. Go to "C:\User\Appdata\local" and delete Sublime text folder
  3. Go to "C:\User\Appdata\Roaming" and delete Sublime text folder
  4. Go to "C:\User" you will find Sublime text folder go inside if there are your project files then save them to other location and delete that Sublime text folder also
  5. Now install Sublime text (which is <10MB)

Run your sublime text is all set you can config it again with fresh start