Aptana "PHP Version" doesn't stick in project properties
Asked Answered
C

2

17

I have a project that explicitly needs PHP 5.4.x compatibility, so I right click on my project and go to Properties. Then I click the "PHP Development" menu on the left, and select "PHP 5.4.x" from the dropdown. It works fine until I restart Aptana--then it goes back to "PHP 5.3.x" which I guess is the default. Is this a bug in Aptana? How do I get the version to stick even when I restart?

Cathryncathy answered 8/7, 2014 at 14:8 Comment(1)
I've also just noticed that the compatibility change only takes effect for files which are showing in the Project Explorer (very strange)... Honestly the problems stem from the fact that you can no longer create a new project in a directory that already has files in it--this wasn't always the case. Now when I "import folder as new project" I assume it assigns PHP 5.3.x by default b/c I never get to choose at that point.Cathryncathy
N
21

The only temporary solution I found (in Aptana build 3.6.0.201407100658) is setting the PHP 5.4.x version from Project->Properties from the opened file. You just can't close Aptana or the file but can come handy when working on few important files.

update: You can add project_path/.settings/com.aptana.editor.php.prefs file that reads:

eclipse.preferences.version=1
phpVersion=php5.4

In my case, this helped.

Nelrsa answered 11/8, 2014 at 19:26 Comment(3)
Thank you for the update. Adding the file works for me as well.Meliorate
also, you need to wait until the task Indexing new PHP modules finishes, in case you still see errors in the Problems tab. Thanks, it worked!Chile
This didn't work for me i found it was better to create a new project, define PHP 5.4 at the outset and copy the resources from the old project to the new one. If you really need the same names and references etc. Delete the old project and create a new project with the old name. copy the resources once again and delete the first new project.Hispania
F
1

It seems this is a serious bug in Aptana. Just like our friend Viktor Sulak said: edit the file .settings/com.aptana.editor.php.prefs,

But, if your workpsace does not have this file "com.aptana.editor.php.prefs", simply create it with the content:

eclipse.preferences.version = 1
phpversion = php5.4

and everything gonna be all right!

Fayefayette answered 24/8, 2015 at 20:23 Comment(1)
there should be a dot before settingsKeelby

© 2022 - 2024 — McMap. All rights reserved.