NetBeans PHP Code Completion for Standard Functions

谁都会走 提交于 2019-12-02 00:51:55

Try this...

  • Tools->Options
  • Selct "Editor"
  • Select "Code completion"
  • In language drop down select "PHP"

You will see a list of code completion options for PHP project ONLY

  • If you have global variables/objects set "Code Completion for Variables" is set to "All Variables"
  • If you are using methods without static in front of them as static make sure under "Code Completing for Class Methods" you have "Also Non-Static Methods after ::"

If you are not using namespaces PHP 5.3, make sure you project is type is test to PHP 5.2/5.1. To check it, right click your project->Properties->Sources->PHP Version.

bigal

I checked the above thread and my project settings are correct, as are the PHP settings and plugins are enabled. Each PHP editor window shows and editable form, but there is no hints,completion or anything else that is helpful whilst writing code. I figured it out in the end: each PHP section started and ended as below:

<?   ?>

should have been:

<?php    ?>

tags are deprecated (since php 7.0+), but you can enable it in NetBeans if You're working with legacy code at:

Project Properties -> Sources mark Option: Allow short tags, it is also possible to allows ASP tags <% %> there.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!