I coded a lot in Zend Studio 5.5.1, the gold old version thatâ€™s insanely popular because it made it so easy to code in PHP. As PHP evolves, ZS 5.5.1 gradually falls behind of the edge and it simply becomes imperative that you switch to the latest version of Zend Studio, the 8.
The IDE is built on Eclipse, which I have never used before. Itâ€™s great but one still needs some time to learn the curves before he or she can jump in and swim like a whale. Today I gave it a test drive and have some tips to share with you when you are just starting out with Zend Studio 8.
1. Change Default Character Encoding
Before you create your project or editing any existing PHP files, you may need to change the default encoding of the Zend Studio Workspace, or make sure it is what you usually work in.
By default, the encoding is that of the container (your operating system). Iâ€™m using a Chinese Windows 7 so the default encoding is GBK and it is everything but good because I primarily develop English projects.
For North America users, the default encoding should be ISO-8859-1. If you open up a file thatâ€™s encoded in UTF8 without changing the encoding accordingly, you may end up screwing up the file. And another victim.
To change the default encoding of Zend Studio: Windows â€“> Preferences â€“> General â€“> Workspace â€“> Text file encoding, switch to â€œOtherâ€ and select the encoding you normally use.
2. Display Function Parameters Hint on Demand
In 5.5.1, function parameters hint is automatically displayed when you place the cursor in the parentheses. However in 8, the hint is only automatically shown after you immediately finish typing the function name. When the focus moves away or you click anywhere else in the window, the hint disappears and if you donâ€™t know the correct shortcut keys, you wouldnâ€™t be able to get it back.
After a few searches, I found out the key combinations to get the parameters hint re-appear: Alt + Shift + /
Some pages say itâ€™s Ctrl + Shift + Space but it didnâ€™t work out for me. Maybe itâ€™s a version thing?
3. Display Potential Function Candidates / Auto-complete Function Names
Along with the previous tip, this one is pretty important in modern IDE because they are essential in boosting oneâ€™s coding productivity. Canâ€™t live without them.
When you are typing the function name, Zend Studio would guess what you mean and display a list of possible candidates for you to choose from.
If you want it to appear again, just place the cursor on the function name and use Alt + / to make Zend Studio makes a guess again.
4. Display All Shortcut Key Combinations
You can use a lot of shortcut keys in Zend Studio 8 to make things happen quickly and intuitively, just press Ctrl + Shift + L to bring up the key map toÂ see the full list. Here’s a list of the commonly used commands: