autocomplete for standard php functions (ZST 9)

General discussion on Zend Studio
automatix
Posts: 13
Joined: Sun Aug 08, 2010 12:37 pm

autocomplete for standard php functions (ZST 9)

Post by automatix » Thu Dec 29, 2011 12:59 pm

Hello!

Since then I have installed Zend Studio 9 the code-completion for the standard PHP functions (strpos(...), print_r(...), etc.) hasn't worked anymore.

Can somebody help?

Thanks

Ilya

automatix
Posts: 13
Joined: Sun Aug 08, 2010 12:37 pm

Re: autocomplete for standard php functions (ZST 9)

Post by automatix » Thu Dec 29, 2011 1:23 pm

OK, I found the solution for one project: Project Properties -> [menu] PHP Include Path -> [tab] Libraries -> [button] Add Library... ->
  • Zend Framework 1.x -> next -> finish -> OK.

    Now I the autocomplete for the standard functions and SPL works. But -- only in this project. Is there a similar option for the whole workspace?

User avatar
kalinyanev
Posts: 90
Joined: Thu Jul 02, 2009 7:20 am

Re: autocomplete for standard php functions (ZST 9)

Post by kalinyanev » Tue Jan 03, 2012 12:53 pm

Hi,
I have not reproduced your problem yet...
Let me know more details about your working environment and preconditions:
Did you create your current workspace and project using ZendStudio version earlier than 9?
Did you reproduce this problem in another workspace and php project, both created by ZendStudio 9?
Did you get standard.php and SPL.php extracted in the following location just after you have created the php project?:
<path_to_your_workspace>\<workspace_name>\.metadata\.plugins\org.eclipse.php.core\__language__\<folder_name>


Regards,
Kalin Yanev
Zend QA team.

jbeall
Posts: 72
Joined: Thu Jan 15, 2009 5:18 pm

Re: autocomplete for standard php functions (ZST 9)

Post by jbeall » Thu Apr 12, 2012 2:55 pm

I am having the same problem. I apologize that I started my own thread already.

To answer Kalin Yanev's questions, in my circumstance, I am running Zend Studio 9.0.2 on Windows 7 Professional, 64 bit.

I believe these projects were created with Zend Studio 9.0.0. I am 90% confident of that.

I have this problem only in one particular project, so it must be related to the project.

When I look in <path_to_your_workspace>\<workspace_name>\.metadata\.plugins\org.eclipse.php.core\__language__ I see three folders with the seemingly random names 1370dc8, d8ebb58b, and f87db3f. All of them contain both a standard.php and SPL.php

I tried what automatix described in his post on Thu Dec 29, 2011 1:23 pm (Add Zend Framework 1.x to project libraries), but this didn't change anything.

Thanks for any ideas on how to fix this...!

-Josh

diemuzi
Posts: 132
Joined: Mon Oct 04, 2010 3:12 pm
Location: Pensacola, Florida
Contact:

Re: autocomplete for standard php functions (ZST 9)

Post by diemuzi » Thu Apr 12, 2012 3:08 pm

I faced this problem a while back and I could never find a reason as to why it happened because the PHP Include Path and PHP Language Library existed in my project. So I simply renamed my project, created a new one and made certain to add the libraries from the menu, and then it started working. So I just copy / pasted from my renamed project to the new one and all was good.
MSF RiderCoach at http://bikertraining.net

jbeall
Posts: 72
Joined: Thu Jan 15, 2009 5:18 pm

Re: autocomplete for standard php functions (ZST 9)

Post by jbeall » Thu Apr 12, 2012 3:24 pm

I finally tried deleting my project (right clicked on project and chose "Delete"). I left the box "Delete project contents on disk" unchecked, and clicked "OK"

I then created a new "PHP Project from Existing Directory" and chose the directory of the project I had just deleted. I did not add any libraries to the project.

Once I did this, autocomplete started working again.

-Josh

yoyoncahyono
Posts: 1
Joined: Tue Apr 17, 2012 6:55 am

Re: autocomplete for standard php functions (ZST 9)

Post by yoyoncahyono » Tue Apr 17, 2012 7:00 am

I got same issue here.
using ZS9.0.2
All standard.php function is not show up on the code completion proposal (code assist).
This happened on all workspaces newly created or old one, only on the default workspaces (C:\Users\username\Zend\workspaces\DefaultWorkspace) this issue not happening.
Can anybody here now what is going wrong? and have solution for this.
Thank yoy

ayco
Posts: 1
Joined: Thu May 31, 2012 2:44 pm

Re: autocomplete for standard php functions (ZST 9)

Post by ayco » Thu May 31, 2012 3:01 pm

I have the same problem. I use 9.0.2. It happens for all projects. Deleting the project from the workspace & creating a new project from the same file system directory does not work for me.

q3c273
Posts: 1
Joined: Wed Jun 13, 2012 4:39 pm

Re: autocomplete for standard php functions (ZST 9)

Post by q3c273 » Wed Jun 13, 2012 4:39 pm

I have the same issue. :(

hekkoe
Posts: 2
Joined: Wed Jul 04, 2012 1:02 pm

Re: autocomplete for standard php functions (ZST 9)

Post by hekkoe » Wed Jul 04, 2012 1:08 pm

What worked for me was this:

Deleting all folders from:
{workspace}\.metadata\.plugins\org.eclipse.php.core\__language__

Then removing the PHP Language Library from the build path (right click in the PHP explorer and then buildpath -> remove from build-path)

cleaning the project

then adding this line to .buildpath file in the project root:

Code: Select all

<buildpathentry kind="con" path="org.eclipse.php.core.LANGUAGE"/>
then cleaning the project again and restarting Zend Studio.

Hope this helps!
Hekko

Post Reply