Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

In Sublime text 2 php autocomplete is not working

In my Sublime Text 2 Autocomplete is not working in a php file where there is no closing tag(?>) but it works when I give the closing tag.

As it is a good practice to avoid closing tag for getting rid of accidental spaces or other newline characters at the end of file, it is better if I don't use the closing tag.

Does anyone have solutions?

like image 329
smm Avatar asked Jun 30 '13 08:06

smm


1 Answers

In your sublime User/Preferences.sublime-settings file add:

{
    "auto_complete_selector": "source, text",
}

This will enable auto-complete even when there is no closing PHP tag.

like image 140
user555 Avatar answered Oct 25 '22 16:10

user555