Re: How can I track the value in php

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, November 5, 2005 3:44 am, shining wrote:
> I am php beginner, I have a question:
> in my index page, I firstly inlcude_once a A.php file, where i defined
> an
> array, secondly I include another .php file named B.php, where I want
> to use
> the array, I have claimed it as global type, but it seems I can't
> retrieve
> any value from the array.

global only really makes sense in the context of INSIDE a function (or
method of a class)

So *where* did you declare it global?

You probably want to take out the global unless it is inside of a
function() { }


> So I want to ask:
> 1. Is my use way right?
> 2. if I want to track a variable value how it changed between php
> functions,
> besides I print out it's value, Is there any other way to do it?

There are IDEs you can use to watch variables as a script executes.

Zend IDE
Komodo

are the ones I remember as "good" from when I last looked at IDEs

YMMV

-- 
Like Music?
http://l-i-e.com/artists.htm

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux