Setting breakpoints in PHP - is this possible?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Ronald Raygun

    Setting breakpoints in PHP - is this possible?

    I have some server side code I want to debug (coming from C++
    background). I am using echo statements but for some reason, no output
    is being generated. It would be much simpler if I could set breakpoints
    to see the variable 'states' when a script is being run - is there any
    developement IDE/Tool out there that helps me do this?

    if the answer is no (which i suspect it is), does anyone know of any
    likely reasons as to why my echo statements are not outputting text on
    the browser?
  • Captain Paralytic

    #2
    Re: Setting breakpoints in PHP - is this possible?

    On 2 May, 15:32, Ronald Raygun <inva...@domain .comwrote:
    I have some server side code I want to debug (coming from C++
    background). I am using echo statements but for some reason, no output
    is being generated. It would be much simpler if I could set breakpoints
    to see the variable 'states' when a script is being run - is there any
    developement IDE/Tool out there that helps me do this?
    >
    if the answer is no (which i suspect it is),
    You suspect wrong.

    What I am very surprised about is why, when you searched google for:

    php breakpoints
    or
    php ide
    or
    php ide debugger

    as you obviously did before posting here, you totally failed too see
    all the hits it came back with!

    xdebug is a good starting point. I use it in conjunction with notepad+
    +

    Eclipse is another good IDE for this purpose.

    If you find out why your google connection isn't working, you'll find
    all the rest.

    Comment

    • Michael Fesser

      #3
      Re: Setting breakpoints in PHP - is this possible?

      ..oO(Ronald Raygun)
      >I have some server side code I want to debug (coming from C++
      >background). I am using echo statements but for some reason, no output
      >is being generated. It would be much simpler if I could set breakpoints
      >to see the variable 'states' when a script is being run - is there any
      >developement IDE/Tool out there that helps me do this?
      Xdebug
      Zend Debugger

      Both can be used with the Eclipse IDE for example.
      >if the answer is no (which i suspect it is), does anyone know of any
      >likely reasons as to why my echo statements are not outputting text on
      >the browser?
      Do you get a result from an echo statement at the very beginning of the
      script? What's the setting of error_reporting and display_errors in your
      php.ini? The first should be E_ALL|E_STRICT, the second "1" or "on".

      Micha

      Comment

      • John Murtari

        #4
        Re: Setting breakpoints in PHP - is this possible?

        Ronald Raygun <invalid@domain .comwrites:
        I have some server side code I want to debug (coming from C++
        background). I am using echo statements but for some reason, no output
        is being generated. It would be much simpler if I could set
        breakpoints to see the variable 'states' when a script is being run -
        is there any developement IDE/Tool out there that helps me do this?
        >
        if the answer is no (which i suspect it is), does anyone know of any
        likely reasons as to why my echo statements are not outputting text on
        the browser?
        There are some pretty good debuggers out there as the
        other folks said; however, as far as not seeing anything on your
        screen --- it probably means a serious error is occuring even before
        the script gets to your echo. You want to make sure screen display
        of errors is on. Check the documentation, but try adding these two
        lines to a .htaccess file in the same directory with the application:

        php_flag display_errors on
        php_value error_reporting 2047

        That should get you something!

        --
        John
        _______________ _______________ _______________ _______________ _______
        John Murtari Software Workshop Inc.
        jmurtari@follow ing domain 315.635-1968(x-211) "TheBook.Co m" (TM)

        Comment

        Working...