Search code examples
netbeansphp-5.3

Netbeans PHP Code completion failing me, or am I failing it?


First off here is some information, I am using Netbeans 7.0 with the project's php interpreter set to 5.3. The reason for this is I am working with namespaces.

So the setup is thus, I have 3 folders

-app                    Namespace App
--controller
--model
--view
---*login.php
-system                 Namespace Sleek
-vendor                 Namespace Vendor
--*Reform.php

I am using Autoloading, however the entire project is, and this is the first instance I've run into where code completion didn't work, I find it curious...

Reform.php

namespace Vendor;
abstract class Reform {
    static function HtmlEncode($str);
}

is being called in...

login.php

(snip)
    <input id="url" name="url" type="hidden" value="<?php if (isset($_GET['r'])) { echo \Vendor\Reform::HtmlEncode($_GET['r']); } else { echo "/"; }; ?>">
(snip)

Ignore the horrible view setup with logic inside it please and help me understand why when I type \Vendor\Reform:: netbeans has no suggestions for me, yet it compiles and runs under E_STRICT


Solution

  • It was a bug in netbeans PHP code completion

    http://netbeans.org/bugzilla/show_bug.cgi?id=206521