"Php100 exclusive feature" If you look at the market share of NetBeans and Eclipse alone, you might think that using any of these Ides to develop PHP applications is no problem, for example:
2. Eclipse: It is an open source project built on Equinox OSGi, and Eclipse is evolving from the Java IDE to support a growing number of languages, including static and dynamic languages, thick clients, thin clients and server-side frameworks, modeling and business reporting, embedded and mobile development. It is currently the best Java IDE.
The tools that need to be used
NetBeans 6.5 for PHP
Eclipse PDT or Eclipse PDT 2.0
Java Development Kit (JDK) version 5 or 6
Apache HTTP Server 2.0
NetBeans IDE 6.5 for PHP Introduction
Starting with NetBeans, I'll start by downloading netbeans,1 from http://www.netbeans.org/downloads/index.html. Installation is only guided by the installation wizard.
Figure-1 Download NetBeans IDE 6.5 for PHP: Click on the PHP line in the NetBeans download page
As long as the Java Runtime Environment (JRE) is installed, you can run NetBeans for PHP without installing the full Jdk,netbeans IDE for PHP, the latest version is 6.5, which contains the following new features:
1. PHP Source Code Editor
2. Remote and local project development
3. Simplified Code navigation operation
4, PHP Debugging (you can check local variables, set monitoring points, breakpoints, evaluate the flexibility of the code), NetBeans IDE for PHP also allows you to use XDebug, you can choose a debugger version, but recommended to use XDebug 2.0, it and PHP 5.0 has better compatibility.
5. mysql Integration
Create a PHP project
In order to implement a PHP script/web application, you need to create a PHP project root (an empty project that includes only common files and directories). Regardless of the application, the IDE generally uses the concept of "project," and NetBeans provides a dedicated wizard for configuring a new project, creating a booksphp sample application by following these steps:
1, start NetBeans;
2. Select file à create a new project (Opens a New Project dialog box);
3. Select PHP from the Categories panel, select the PHP application from the project panel (you can also choose to load a PHP application), and click Next.
4, enter the project name and location in this dialog box, enter booksphp here, select a convenient location in the Source Folder field, click Next.
5. NetBeans supports running a PHP application on a local server (usually Apache HTTP server), on a remote server (via FTP) or as a PHP script (using PHP interpreter), in order to compare, you should be in Apache HTTP Server runs the booksphp application, so selecting the local Web site from the list, and then entering the application's Url,url in the Project URL field area is usually similar to http://localhost/... String, this example should be http://localhost/php/booksPHP/(of course you need to tweak the URL for your configuration) because you plan to run the project on the local server, You need to provide a running location for NetBeans to copy the application code to there, select "Copy from source folder to another location" and specify the target location in the "Copy to" area (e.g. C:Program Filesapache groupapache2htdocsphpbooksphp), it is clear that this is only necessary if the root folder of the project is different from the root folder of the local server;
6. Click the Finish button to close the New Project dialog box.
If you choose to run the PHP application as a script, you must specify the location of the PHP interpreter (PHP.exe), and similarly, if you choose to run the PHP application on a remote server, you must specify a valid FTP connection, upload the directory, and upload the method.
At this point, NetBeans builds the project, as shown in 2.
Figure 2 Build Project: After completing the New Project Wizard, you will see the resulting project root in the NetBeans IDE.
Implementing the Project
Creating an HTML interface
Most of the HTML code for this project resides on the index.php page, index.php created automatically when NetBeans created the project root, and you can use NetBeans's Palette tool to add HTML elements to it, and if you don't see this tool, By clicking on the Window Àpalette menu, Palette provides shortcuts to all the main HTML elements by dragging and completing the selection of elements.
Before adding some tags, NetBeans asks you to specify special configurations for them, such as: when you drag a
Listing 1 HTML code (index.php)
http://www.bkjia.com/PHPjc/446625.html www.bkjia.com true http://www.bkjia.com/PHPjc/446625.html techarticle "php100 exclusive feature" If you look at the market share of NetBeans and Eclipse alone, you might think that using any of these Ides to develop PHP applications is no problem, such as: ...
tag, you have to specify the number of rows and columns, and so on, I'm not going to go into the details here, creating HTML code in NetBeans is as easy as walking in a park. Therefore, using the palette and drag elements to modify the index.php, the final result is shown in Listing 1.