PHP 工欲善其事, its prerequisite

Source: Internet
Author: User
Tags definition modify php file word wrap zend

The author Rocky is good at the application system development, Web development, software design, database technology and application in the. NET platform. This article describes some of his insights into PHP learning. CSDN Research and Development channel on this has been organized for everyone to learn, reference.

The contents are as follows:

Because of personal reasons to go to PHP for more than a week, familiar with the simple syntax, you can also use PHP to achieve crud, is taken as the first step, the feeling of PHP is also estimated with many people, simple, good to start.

You may be able to complete your system with something like Dreamweaver, notepad++ or EditPlus, but the so-called "工欲善其事, its prerequisite," I think a force-giving IDE is necessary for beginners, and Zend as the first-known IDE of Phper, Naturally became my choice, I installed the version is 7.2.1, this article on his own for this "new" tool of the transformation, and finally leave a few problems to let the experts to solve.

1. Change Zend Working directory

  

2. Change the Zend Font

In turn, enter window--preferences--general--appearance--colors and Fonts--basic--text font to modify, I still like the Consolas of the number 16th:

  

3. Change the default settings for a new document template

By default, the new PHP file is automatically generated with the following code:

Only this line, I want to be able to create a new PHP file can generate closed PHP tags, so in turn into the window-> Preferences-> PHP-> Editor-> Templates-> new simple PHP F Ile Modification:

  

4. Modify the automatic prompt code speed

Zend is a chronic child, the default code hint delay is 500 milliseconds, obviously not in line with Coder's nasty temper, so enter window-> Preferences-> PHP-> Editor Content-> Assist Auto activation, set the speed 500 of the code auto prompt to 50:

  

5. New Template

Zend inside already brought a lot of templates, you can go into the above to modify the default new PHP file template where to visit, but inevitably there will be insufficient use of the situation, so we need to create a new template:

  

Note Select newphp in the context and you cannot find the template name when you are new.

6. Change shortcut keys

This and VS is similar, I believe that we will inevitably have some shortcut keys, such as the key to the Ctrl+k,c as a note shortcut, this is obviously two hands can be completed work, how fast up Kazakhstan, so we will make changes, such as modified into Ctrl+e,c, And Zend in the default block annotation is ctrl+shift+/, uncomment the block is ctrl+shift+\, and add or cancel Single-line comments, the default is to switch ctrl+/, I still do not want to two hands to operate, so decisive change, I changed the single-line annotation switch is ctrl+e, The block annotation is ctrl+r, and the cancellation block annotation is ctrl+g.

The other is to change the debugging and vs the habit of consistency, debugging from F11 to F5, run from Ctrl+f11 to ctrl+f5,step into from F5 to f11,step over from F6 to F10.

The above two-part changes can be seen by entering "comment" and "Debug" in the Search box.

  

7. Install Jseclipse

JS hint to be strong, and Zend itself with a little weak, here better choice is to install Jseclipse Plug-ins, we turn into help-> Install Newsoftware

Here are two ways to install, one is to add the online installation address Http://download.macromedia.com/pub/labs/jseclipse/autoinstall, and of course, download and install the package to the local, to install, If you unpack the selected local folder to find a certain, or you do not bother decompression can also directly select archive.

  

All the way next, you can install it.

Install to select Jseclipse as the default JavaScript editor to use Jseclipse, in turn, enter window-> Preferences-> general-> Editors File Assocaitions:

  

Set "Default".

Similarly, code hints are modified faster:

  

The default value for the original "outline reparsing delay (ms)" is 200, and the Code completion popup delay (MS) defaults to the default value.

8. Window Layout

Use Alt+shift+q,v to pull out the variable window to facilitate the debugging of the value of related variables

Debug and debug output windows are also available for easy tracking and debugging

Also in the Window--show view of the PHP function window, lazy to open the manual when you can take a look.

  

The final layout in order to look pleasing to the eye, or to make a look like VS, where the following one can be minimized to increase the workspace.

  

9. Notes

You can add a comment to a function in VS for a three consecutive entries. This can add the function of the summary, I thought this function in Zend Rimi have, but still in the occasional note found that is typed/**, and then enter the function can add a comment, the effect as shown:

  

Well, the above is probably my transformation of the Zend, and finally left a few in vs I often used, but in the Zend has not yet found the realization of the problem, look Daniel to give guidance:

1. In VS I will set all the files are automatically wrapped, that is, the code line will not finish when the line is displayed, rather than continue to display, resulting in a horizontal scroll bar, so see the code dragged to drag, it is the impact of the readability of the code. All I'm seeing right now is that there's a "Toggle Word Wrap" option in the workspace that allows the current page to wrap, but does not find a feature setting that wraps all the files in one line.

2. In addition, also often used a "go To Definition" function, that is, in a function or variable right click, you can go to the definition, and then go to the function or variable initial definition of the line, which is more useful in the file, but not found in the Zend.

3. There is also a more common function is that I enter a function or variable, Zend will definitely hint ha, OK, let's say that now I am not careful what other things, such as touching the touchpad, so because of the mouse click Reason, the smart prompt box must have disappeared right, At this point there is no way to press a key and so on the cue box out, instead of knocking the half of the function to delete and then input from the beginning, let the prompt box appear. This is ctrl+j in VS, but it is not found in Zend.




Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.