sayed ahmed bsc. eng. in computer engineering, buet, bangladesh msc., computer science, u of...

16
DEVELOPING PHP APPLICATIONS WITH NETBEANS IDE Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada http://www.justetc.net http://sayed.justetc.net [email protected]

Upload: alberta-shaw

Post on 20-Jan-2016

218 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

DEVELOPING PHP APPLICATIONS WITH NETBEANS IDE

Sayed AhmedBSc. Eng. in Computer Engineering, BUET, BangladeshMSc., Computer Science, U of Manitoba, CanadaSoftware/Computer Engineer, Canada

http://www.justetc.nethttp://[email protected]

Page 2: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

TOOLS

WAMP: The platform in windows http://www.wampserver.com/en/

Netbeans IDE: use the PHP column https://netbeans.org/downloads/ Xdebug included

Install the Wamp, run it Configure and Start Apache Install Netbeans, and run it

Page 3: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

WAMP ADMINISTRATION

Page 4: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

A SCREENSHOT ON DEBUGGING

Page 5: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

PROJECT PROPERTIES WINDOW

Project Name->right click->select properties

Page 6: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

SET THE PROJECT URI

Page 7: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

PHP.INI CONFIGURATION REQUIRED

Page 8: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

DEBUG RELATED OPTIONS IN THE MAIN MENU

Page 9: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

DEBUG SETTINGS IN NETBEANS

Tools->options, then PHP, then debugging

Page 10: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

VARIABLES AND VALUES

Page 11: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

IN DESCRIPTION

To enable xdebug debugging in Netbeans IDE php.ini needs some configuration[You will be able to debug PHP applications the way you do in Visual Studio, Turbo C/C++ IDE]

php.ini configuration Required ;XDEBUG Extension

zend_extension = “c:/wamp/bin/php/php5.4.12/zend_ext/php_xdebug-2.2.3-5.4-vc9-x86_64.dll”

[xdebug]xdebug.remote_enable=truexdebug.remote_host=127.0.0.1xdebug.remote_port=9000xdebug.remote_handler=dbgpxdebug.profiler_enable=1xdebug.profiler_output_dir = “c:/wamp/tmp”

Page 12: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

CONFIGURATION REQUIRED IN NETBEANS IDE

Configuration Required in Netbeans IDE: 1. Set the Project URI to the path under your web-

server; as you can see the site in a browser; the path shown in the browser address bar. Right click the project, click properties, click run configuration, set the Project URI. Example: http://127.0.0.1:800/example_projects/TodoList/web/

2. Go to Tools->Options->PHP->debugging. see if the parameters are ok, if not fix them. Also, set the properties you want. You may check ‘Watches and Balloon evaluation’

Page 13: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

MISC STUFF

You can set the breakpoints in your project You can select debug or debug file from menu or from

right clicking on the project Then you can use the Step Over, Step Into, Step Out

from debug menu or shortcut keys [better]—

You can also check the values of the variables You can also check the status of the stack

and see all breakpoints listed; there is a window for that

I will add pictures or pdf slides with screen shots to make you understand it better.

Page 14: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

FREE TRAINING BY JUSTETC

Training and Education in Bangla: http://Bangla.SaLearningSchool.com http://Blog. SaLearningSchool.com

Training and Education in English: http://www.SaLearningSchool.com http://English.SaLearningSchool.com http://www.SitesTree.com

--------------------------------------------------------------------------------- Ask questions and get answers

http://Ask.JustEtc.net

--------------------------------------------------------------------------------- Offline IT Training: 

http://University.JustEtc.net

Page 15: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

OUR ADDRESSES

Trudelle Street, Toronto, Canada [email protected]

Shimultuly, Gazipur, Bangladesh Justetc Computers Habib Complex, 2nd Floor [email protected] (01942747702)

Page 16: Sayed Ahmed BSc. Eng. in Computer Engineering, BUET, Bangladesh MSc., Computer Science, U of Manitoba, Canada Software/Computer Engineer, Canada

CONCERNS?

http://ask.justetc.net