I just downloaded xampp(7.0.8) from xampp download page and installed with no error but when I create a new project in Netbeans it shows only 5.4 as the highest php version whereas what I have is php7. I tried with xampp 5.6.23 and still Netbeans did not show php5.6.
What's happening? How can I make Netbeans show php7 or php5.6 . I have xampp for both versions.
Netbeans 8.2 Will support PHP7 (http://wiki.netbeans.org/NetBeans_82)
You can download nightly builds version 8.2
http://bits.netbeans.org/dev/nightly/latest/
When creating a project in Netbeans, make sure to select the right PHP version on step 2 in the wizard. I know this question is a old one, but I came here since my older project was created on 5.6. To change a current project, open your project properties and on the Sources categorie change the PHP Version to the version you want to use.
To make clear. It does not matter at all what XAMPP you install. This setting is used for the hints in the editor. The final location of your project where it runs in the webserver has nothing to do with Netbeans at all.
Unfortunately the Netbeans still doesn't support some PHP7 syntax features like the typed properties.
E.g.
Class Foo { public int $bar }
shows a syntax error hint because of the "INT" attribute of $bar property despite that is allowed by PHP7
Other e.g.
public function foo(?int $bar){}
also shows syntax error due to the question mark.
I wish they will publish an update or even a pack.
Use Sublime Text instead of Netbeans, I mean if you just want to use netbeans to work with PHP, Sublime Text is better, just a suggestion.
Related
I would like to update the versions of php available in Netbeans 7.1 (I know it is only for hints),
I have php 5.4 working in my pc, but in netbeans I have available only php5.3 and 5.2, I would like to have 5.4 too
https://prnt.sc/fqxyoo
*I can not update netbeans because from 7.2 to 8.x it crashes inmediatelly after starting, but that is another history, so I would like only how to add php5.4 in netbeans 7.1
Thanks
Check your php version with the help of phpinfo(). But netbeans does not bundle the php. Check in php download url and download what you want.
I'm having a problem with Netbeans 8.1 working on Symfony2 project - I don't have any code hints and autocomplete suggestions. It applies to both userland code written by me and autoloaded from vendors.
For example when I want to implement an interface, there's no hint for missing methods. I don't even get autocomplete for $this.
I already tried to clear cache directory with no success.
My Netbeans info:
Product Version: NetBeans IDE 8.1 (Build 20151231-debian-8.1)
Java: 1.8.0_111; OpenJDK 64-Bit Server VM 25.111-b14
Runtime: OpenJDK Runtime Environment 1.8.0_111-8u111-b14-2ubuntu0.16.04.2-b14
Running on Ubuntu 16.04.1 LTS
Perhaps someone had that problem?
I had this problem when I excluded vendors directory in Netbeans project properties. I did it when I wanted Netbeans to use code sniffer.
Maybe you'll find it helpful information.
Upgrading to Netbeans 8.2 solved the issue (I'm not sure if it would not work with reinstallation of Netbeans 8.1).
I had to download new version from https://netbeans.org/downloads/index.html because it was not available through apt.
I have the latest version of MAMP installed but i want it to run PHP version 5.4.
That version is included in the MAMP file dir. It is located…
-> bin/php/php5.4.42
but in the preferences pane there are only 2 PHP version options: 5.6.10 and 7
I want to do this a part of troubleshooting. i have a Drupal install and am getting the dreaded ‘White Screen of Death’. I’m trying anything and everything to get it working!
MAMP lets you choose from the last two versions of PHP installed in bin/php. If you want to use 5.4.42, just leave this folder and another one of your choice inside this directory (move the others somewhere else so you have a copy, just in case). When you restart MAMP you'll be able to choose your preferred PHP version in the Preferences.
You can download more versions at https://www.mamp.info/en/downloads/
The easier way is to use other localwebserver called Ampps, and after installing it you can choose the version you want by the simple interface it provide.
You click on PHP ==> Change PHP version, and it will show you versions from 5.3 to 7.0.
Here is the link: http://www.ampps.com/
Thanks a lot.
I'm editing a PHP file in Netbeans that is not part of a project. Although I have PHP 5.3 installed, Netbeans complains about my use of a lambda function: "Language feature not compatible with PHP version indicated in project settings".
Is there a way to tell Netbeans to think in 5.3 when I don't have project settings to edit?
I'm using Netbeans 7.0 with PHP 5.3.3 on Ubuntu.
UPDATE: The code is working, it's just the inspection that is borken.
Right click your project in the Projects tab, click Properties, then on the Sources tab, set the PHP Version. I'm using Netbeans 7.1.2
Go to File Menu of net beans and select project properties of the project and change the version of php from # PHP Version : PHP 5.6 or another.
This Error Showing for PHP version(language feature not compatible with php version indicated in project settings)
I recently did an update to my NetBeans (v7.0.1). I just tried creating a lambda fn and the IDE didn't show any warnings/errors. Try updating your NB.
I'm on a new box at work setting up my environment. I configured netbeans like the instructions said here. I've done this before. It was rather straight forward last time and worked the first time (a rare treat in programing). However, when I run xdebug in netbeans I can't view variable values or object structures. Here is a screen shot.
Netbeans Screen Shot
There should be more information. I can print the $model variable to the screen. It has array values and other information.
NetBeans IDE 6.9.1
xdebug 2.1.1
xampp 1.74
I had the same problems with xDebug and the current Eclipse PDT under Windows 7 and was unfortunately unable to resolve them.
I finally switched to the WAMP distribution where the same configuration seems to work.
I just did a reinstall of my wamp environment. I grabbed the newest xampp and used the xdebug dll it came with. It now works. I'm guessing this was a PHP/xdebug version mismatch.