Getting started with PHP code editors



PHP files are just like any other text file and can be made using a basic text editor like Windows Notepad. The problem with these editors is that they’re very simple and do not offer any extra featurs specifically geared towards programming. Here are the common features a good code editor will have:

1. Syntax color highlighting: By coloring different parts of your programming languages it different colors, it is easier to see what is going on and how everything is organized.

2. Line numbers: Some PHP files may have thousands of lines. If your script shows an error in line 362, it’s nice to see that number clearly instead of having to count it yourself.

3. Code completion: Some editors have the ability to accurately guess what you’re going to type ahead of time and will do it for you.

4. Multiple file tabs: Unlike Notepad, most code editors let you open multiple files at once in one window. You can easily switch between files quickly by using the navigational tabs.

Note: Do not use office software like Microsoft Word for programming. These types of software add additional information like page formatting to the file and it can really mess up your code.

Some free popular editors include:

1. Emacs
2. HTML-Kit
3. Vim
4. Notepad++

In this tutorial, we will focus on using Notepad++, my personal favorite of the bunch. Follow these steps to install:

1. Go to the download page: http://notepad-plus.sourceforge.net/uk/site.htm

2. Click the “Download Notepad++ executable files” link and download the file called npp.5.4.3.Installer.exe. The version number may be a little different than seen here.

editors-1

3. Installation is similar to installing Wamp. Just follow the on-screen directions and launch the program when it’s done.

4. In Notepad++, click the Language navigation link at the top and choose “PHP” as your language. This will enable syntax highlighting, as shown here:

Notepad++ Choose PHP Menu

Notepad++ Choose PHP Menu

Now that we have all the tools we need, let’s move onto the fun stuff: The Basics of Programming PHP.

Leave a Comment