howto get eclipse to use spaces instead of tabs for php files

you need change eclipse settings in 3 three places in order to get eclipse to use spaces for tabs in php files

  • general | editors | text editors |
    • displayed tab width = 2
    • insert spaces for tabs

and

  • php | editor | typing
    • tab key indents the current line
  • php | code style | formatter
    • tab policy = spaces
    • indentation size = 2
    • tab size = 2
    • default indentation for wrapped lines = 2
    • default indentation for array initializers = 2
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s