Archive for the ‘php’ Category
Thursday, April 23rd, 2009
PHP Quick Profiler
This looks like a pretty cool tool to get a good idea of what's going on in your PHP script without having to install tools like XDebug and Webgrind / KCacheGrind.
Apple files patent for browser specific volume
I'm not sure how this is anything new, tons of applications have ...
Posted in apple, links, php | No Comments »
Tuesday, December 16th, 2008
Here's a quickie - make sure every PHP file in your project parses correctly.
find . -name '*.php' -exec php -l {} \; | grep "Errors parsing"
Posted in php | 1 Comment »
Thursday, May 8th, 2008
I'll keep it short. In the last few days, login on our dev server broke. We hadn't changed anything related to it, and everything looked good code wise. What we finally figured out was that our session cookie was set to expire 2 days into the future, ...
Posted in php, vmware | No Comments »
Wednesday, April 16th, 2008
I got this today. Solved by restarting the Memcached server. Move along.
Edit: this is actually a reoccurring bug we're seeing with the memcache 2.2.3 stable build on 2 different boxes
2nd Edit: Actually it was a bug in my code. I wasn't setting the server and ip correctly, ...
Posted in memcached, php | 3 Comments »
Wednesday, April 16th, 2008
If you do any work with single sign on, you'll be familiar with the concept of exchanging tokens and validating against the authentication server using that token. One of the issues I've just run into which resulted in a huge headache is with urlencoding the result of a curl_exec ...
Posted in curl, php | 1 Comment »
Wednesday, February 20th, 2008
Let's get one thing out in the open. Curl is sweet. It does it's job very well, and I'm absoutely thrilled it exists.
If you're using curl in your PHP app to make web requests, you've probably realized that by doing them one after the other, the total time of ...
Posted in curl, php | 61 Comments »
Tuesday, December 18th, 2007
I had an issue getting phpsh to work on my mac - I kept getting the following error:
Traceback (most recent call last):
File "./phpsh", line 20, in
import readline
OK, seems easy enough. So I compiled python with readline support.
./configure --prefix=/usr/local/python --enable-readline
I change the ...
Posted in php, python | No Comments »
Saturday, December 15th, 2007
If you manually call ob_start() at the beginning of your script, you might notice that you are unable to use phpsh. By commenting it out, I was able to fix the issue.
I don't think it technically hangs, it just sits there with the data in a buffer waiting to ...
Posted in php | 1 Comment »
Friday, November 16th, 2007
I'll be honest, this isn't very useful. The goal was to have an array of months in the least amount of code.
for($i = 1; $i
Posted in php | No Comments »
Wednesday, November 14th, 2007
Perhaps you'd like to just sent XML over post, and not have xml=your_nodes_and_stuff_here. No sweat.
$xml = urldecode(file_get_contents('php://input'));
Enjoy.
This can now be called with:
curl -d "some_xml_here" http://yoursite.com/pagename
Posted in php | No Comments »