Category Archives: PHP

Setup Curl

apt-get install curl libcurl3 libcurl3-dev php5-curl

Setup Send Mail

apt-get install sendmail

Get Calling Function

While trying to step through code, it was always hard to find out what was happening without a debugger. Today I needed one more than ever, but instead, I found the next best thing, debug_trace. This function allows you to get the calling function. This is great for following code!

1
2
$backtrace = debug_backtrace();
echo $backtrace[1]['function'];