Gambling to win cash can be explained as wagering your money on an event whose outcome is not known. It is an age old practice and has been in the blood of humans from ancient times. [http://www.casino-spielen.biz/ casino deutschland]

+

Gambling to win cash can be explained as wagering your money on an event whose outcome is not known. It is an age old practice and has been in the blood of humans from ancient times. [http://www.blackjackdeal.com/ online blackjack]

Overview

This document describes the installation of xdebug. There are separate sections for Linux and Windows users. However, the information in How to on Linux may be interesting for Windows users as well. Please send your comments to users@php.netbeans.org if you have any comments or questions.

Important note for WAMP: xdebug configuration (below) must be added in WAMP's apache-directory php.ini (e.g. C:\wamp\bin\apache\Apache.x.y.z\bin\php.ini), otherwise it won't be loaded by Apache. Thus configured, it will work in NetBeans, but if you experience "call to unidentified function" in the debug window, add the xdebug configuration to C:\wamp\bin\php\php.a.b.c\php.ini as well.

Xdebug configuration is either inside php.ini or in another ini file often called xdebug.ini - this ini file is then shared between both configurations (Script and Local Web Server)

Xdebug is incompatible with the Zend Optimizer and Zend Studio Debugger extensions. These extensions should be commented out. See user's comment:

This app is provided by the xdebug guys. You can copy and paste in your PHPinfo, and it gives you the correct version with step-by-step compilation instructions. Many xDebug problems seem to come from tiny mismatches between the exact PHP release you use, and the exact version of xDebug you use. If you simply downloaded the latest version xdebug, or if you got xdebug off a repository, this is probably part of your problem.

3: Get xdebug's debugclient working on localhost first, then add Netbeans.

If Netbeans is failing to connect, chances are it's a problem with xDebug and nothing to do with Netbeans. First, try to achieve the simplest possible xDebug set up: use the bundled command line client "debugclient" instead of netbeans, on localhost, debugging simple php code (e.g. a phpinfo file), with any firewalls and other competing factors or config disabled or removed. When you've got this running, then your fight with Netbeans will be on solid ground, and will probably be surprisingly easy.

As for actually using it, there's almost nothing I could find on xdebug's own site, but there's good tips on the really helpful page Installing the XDebug Debugger - look under "Can I debug locally?" near the bottom. The important thing is, if debugclient hangs on "Waiting to connect", it hasn't necessarily failed, it could be working and listening for a session from your browser.

I personally went as far as setting up an Ubuntu Virtualbox on my Windows machine. This took all Windows-related complications out of the equation, and meant I could casually wipe the whole drive and start all over again when things got complicated. I'd recommend this as it gives you complete control and guarantees no conflicting config files. People have spent days, even more than a week or two fighting to get xdebug to work - spend time now to save time later!

Here's a collection of tips I picked up from 100s of forum posts and from experience:-

Always check there aren't any other php.ini files you haven't configured (on *nix, "find / -name php.ini"). E.g. there are often different php.inis for command line and for web server PHP.

(on *nix) Use the command "netstat -a | grep tcp" when you need to see what's going on with port 9000

Only use those socket-based php test files like http://blogs.sun.com/netbeansphp/entry/howto_check_xdebug_installation sparingly. When they hang, they can tie up the port and complicate the question. Reboot and restart Apache often. Also, don't forget to try them through a browser as well as the command line. If this gives you a fancy error screen with backtraces and some orange colouring, that's a good sign - that's xdebug at work!

Don't obsess over every php.ini option. Most of the defaults are fine. The really important ones are the host, and making sure that whatever port you set in php.ini is matched by your client.

Look at your other debugging-related php.ini settings. Turn them on. This isn't essential, but it helps a lot. I also uncommented the report_zend_debug = 0 line to make sure that this is off and not competing. I don't know if this helped, but xdebug now works, so it didn't hurt.

In your phpinfo, check that "Debug build" IS "No". If it's "yes", this could be a big problem. Research it. I believe you might need to reinstall PHP, to make sure that it is "no".

Make sure there's nothing Zend other than xDebug in either phpinfo, php -m on the command line (if you've got command line php) or php.ini. If there's any other Zend modules in php.ini, comment them out.

If you are mapping server paths to project paths, you must map the full project folders to each other, not the parent folders. For example, the mapping

On Linux systems, if your SELinux policies are enforced, NetBeans will not be able to connect. The reason is that SELinux stops apache from any other port other than the known 80. You can tackle the problem by passing the xdebug port (9000) for apache in the SELinux, using the following command:

alternative Ubuntu files layout (xdebug configuration is in xdebug.ini shared between both configurations. If this is your case then you better add related directives to xdebug.ini. See article Xdebug On Ubuntu):

How to on MAC OSx Snow Leopard

A google search shows many blogs that state that installing xdebug on MAC is tedious and problematic. Their usual recommendation is to download some precompiled version to be safe. Well, this is probably the easiest way to install XDebug but if it doesn't work then you are in trouble. Compiling your own version of xdebug is actually easier than you would think and you don't even need to use the command line so much.

Built in php and apache

I started with a fresh Snow Leopard installation that comes with prebuilt apache and php.

Get Xdebug Sources and Install

Download your xdebug sources from the xdebug download page. Use the Tailored Installation Instructions to download the correct version. After you press analyze my phpinfo() output you should get a recommended version to download with all necessary instructions for installation.

If there is a php.ini file in your /etc/ folder, add the following to the end. If there is not a php.ini file then simply create the php.ini file. There may be a php.ini.default file. Don't update this file but rather create a new php.ini and add only xdebug directives into it. Change path to xdebug.so to your path, of course.

Above is my entire php.ini file. All other directives are saved in php.ini.default.

Note: xdebug.remote_log is optional.

Note: If you are using PHP from the MAMP package, your php.ini file is in /Applications/MAMP/conf/php5/php.ini by default and the default directory in which to install xdebug.so is /Applications/MAMP/bin/php5/lib/php/extensions/no-debug-non-zts-20060613/.

Verify installation

Check the installation either in a browser or in the command line, depending on whether you want to debug a web page or a cli script. The output is the same as on linux or on WIN.

For web page run phpinfo() again.

For command line run the following. You will get longer output but this is the most important part of the output.

folder ext is used for extension and we used it to copy xdebug's dll there. However, you can use whatever folder you want.

download xdebug from http://www.xdebug.org/download.php. Carefully choose version you download! There is a description you should read on download page! I downloaded php_xdebug-2.0.4-5.2.8.dll for WAMP2 with prerequisities above. Consult our FAQ at the end of this page if you need more help on choosing a version.

NOTICE: From PHP 5.3 onwards, you need to use zend_extension and not zend_extension_ts.

note that you always use zend_extension_ts unless you intentionally installed non thread safe apache version

restart WAMP services (restart Apache is enough)

open localhost (or WAMP server default page) and check if xdebug is between Loaded Extensions

click on phpinfo() on default WAMP page or create file containing <? phpinfo() ?>. You should see the same as for Linux tutorial above:

You can check your configuration using simple script written by Radek Matous and posted on blog.sun.com. If you are using WAMP then you don't have php on path, most probably. All you have to do is to copy this code to php file and then call it from browser with $_GET variable in url ?XDEBUG_SESSION_START=mysession. Let's say your file i called dbgtest.php and it's in web directory. All you have to do is type http://localhost/dbgtest.php?XDEBUG_SESSION_START=mysession.

If xdebug is properly installed then script started in step 1. should print message like "connection established: Resource id #5". If no message is printed and the script is still running, then xdebug isn't installed properly or uses different port or whatever else. So, kill the running process and investigate where the problem is, but this is the other story.

Troubleshooting

if something goes wrong then check your PHP Error Log that you can find after invoking WAMP context menu from system tray

e,g,: WAMP icon -> PHP -> Error Log

Probably typo or file was not found if you see this:

PHP Warning: PHP Startup: Unable to load dynamic library 'c:/wamp/bin/php/php5.2.9-1/ext/php_xdebug-2.0.4-5.2.8.dl'
- The specified module could not be found.
in Unknown on line 0

You downloaded wrong version of php.ini if you see following:

PHP Warning: PHP Startup: Unable to load dynamic library 'c:/wamp/bin/php/php5.2.9-1/ext/php_xdebug-2.0.4-5.3.0-vc9.dll' -
The application has failed to start because its side-by-side configuration is incorrect.
Please see the application event log for more detail.
in Unknown on line 0

Do NOT use XAMPP 1.7.0. If you set up XDebug as described here, the Apache server crashes when you run or debug a file or project. The workaround prevents the IDE from stopping at breakpoints. XAMPP 1.7.1 is fine, with XDebug 2.0.4 VC 5.2 thread-safe.

If you are trying to debug a Zend Framework project, make sure you set the Run Configuration - you can do this by selecting the "properties" of the project.

If you are having problems with "Register Provider" then try updating to the latest Zend Framework. Latest known issues are regarded to version 1.10. You can either just download and unzip over the top of the old framework, or if it is in XAMP you can use pear to update. To update in PEAR use the commands: pear channel-discover pear.zfcampus.org, pear install zfcampus/zf. For windows users: make sure you start the command line instance with administrator priviledges and you starting directory should be //XAMPinstall/php/

try to check Apache Error Log as well.

Enable Xdebug logging

by adding into php.ini: xdebug.remote_log=/log_path/xdebug.log (see http://www.xdebug.org/docs/all_settings)
the content of log is in /log_path/xdebug.log (this path is just an example, for Windows something like: C:\... &&
xdebug must be writable )

Enable NetBeans PHP debugger logging

helpful is to turn on the debugger-related logging and attach the log into Issuezilla as well.
See following simple steps:

Running NetBeans with logging turned on. You can do this by:

either adding the text:-J-Dorg.netbeans.modules.php.dbgp.level=400 to your $NB_BIN/etc/netbeans.conf, property netbeans_default_options
or running NetBeans directly with those parameters, like: $NB_BIN/bin/netbeans -J-Dorg.netbeans.modules.php.dbgp.level=400

When NetBeans starts up, reproduce the bug, so it is logged into the log files.

Then file a new issue (click this link) and attach (or just send me directly):

Remote Debuging

For Remote Web Server configuration Xdebug must be properly configured on remote server (not on local one)

you need to have correctly configured property xdebug_remote.host on remote machine. The IP address of local machine has to be defined in this property. For example, you want to debug your source code on remote machine 192.168.0.1 using Netbeans installed on 192.168.0.2. You need to change xdebug.remote_host on 192.168.0.1 to xdebug.remote_host=192.168.0.2. If doesn't work verify you have port configured in xdebug.remote_port open on both machines.

FAQ

what version of Xdebug should I download?

First, you can try the app that XDebug developers provide for determining the version of XDebug to download! It's located at http://www.xdebug.org/find-binary.php. Paste the full output of
phpinfo() (either a copy & paste of the HTML version
or php -i output) into the form and submit it. The app returns tailored
download and installation instructions. Do not paste the raw HTML (from
view-source) into the form.

If this form does not work for you and you need to find the XDebug version manually, Xdebug has a simple rule for choosing a version of xdebug extension youneed to download: "The Windows binaries generally work for every mini release for the mentioned PHP version, althoughthe extension is built against the most current PHP version at that time. The VCx marker tells with which compiler the extension was built, and Non-thread-safe whether ZTS was disabled. Those qualifiers need to match the PHP version you're using."

You need to get answers on few simple questions, firstly
1. whats your version of php?
there are more ways to find this out
either

2. Do I need Non Thread Safe or Thread Safe version?
non-threaded use of PHP" for example the CLI, CGI or Apache 1.3 module
threaded usage of PHP, for example the Apache 2 work MPM or the the ISAPI module

My Thread Safety is apparently disabled so I don't need thread safe version. If you use Windows you most probably need thread safe version .

And that's it! Go to Xdebug download page and download appropriate file. I need veersion marked as 5.2. and NonThreadSafe.

How to build Xdebug (useful for php5.3)

Ubuntu

If you build your php5.3 from sources then the best way how to get stable xdebug to your Ubuntu is to build it. Well, building from sources can be tedious but building xdebug is pretty easy process. So, let's get started. I am using Karmic Koala release of Ubuntu.