[nycphp-talk] pcntl_fork() assistance
Peter Sawczynec
ps at pswebcode.com
Wed Sep 20 16:28:28 EDT 2006
/*
Somewhat tangentially related here, I've found this snippet handy.
Kept around as a utility include, placed at the top of a page for a
bird's eye view of the vars in play as the page loads.
*/
display($ar, $name){
$varcount=count($ar);
echo "<hr /><br />$name. Quantity: $varcount<br /><br />";
while(list($key,$val)=each($ar)){
echo "<ul>";
echo "$key = $val \n\n";
if (is_array($val)){
display($val, "A nested array");
}
echo "</ul>";
}
echo "<br /><hr /><br /><br />";
}
display($_SERVER, "All Server Variables");
display($_COOKIE, "All Cookie Variables");
display($_POST, "All Post Variables");
display($_GET, "All Get Variables");
display($_SESSION, "All Session Variables");
Warmest regards,
Peter Sawczynec
Technology Director
PSWebcode
_Design & Interface
_Ecommerce
_Database Management
646.316.3678
ps at pswebcode.com
www.pswebcode.com
-----Original Message-----
From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On
Behalf Of Dan Cech
Sent: Wednesday, September 20, 2006 2:03 PM
To: NYPHP Talk
Subject: Re: [nycphp-talk] pcntl_fork() assistance
Ben Sgro (sk) wrote:
> Hey Chris,
>
> (Offtopic of fork( ), but in response to Chris)
>
> Since you have double quotes, can't you just say
> print "Here's the string: --$the_string--";
>
> Also, I find it easy to do
> print "string($string)";
What's wrong with good old var_dump($myvar), which will tell you exactly
what's in the variable regardless of whether it is a string or not.
Dan
_______________________________________________
New York PHP Community Talk Mailing List
http://lists.nyphp.org/mailman/listinfo/talk
NYPHPCon 2006 Presentations Online
http://www.nyphpcon.com
Show Your Participation in New York PHP
http://www.nyphp.org/show_participation.php
More information about the talk
mailing list