Tag PHP
How to debug REST/JSON services
I recently had to write a webservice in PHP that were to be used by iPhone/Android apps to post data and images to. With standard HTTP POSTS I’ve usually just created a quick dummy html to post data to the server to test, but this time I had to do some research on how to quickly test the services while developing… Just writing it down here so I don’t forget :-)
PEAR DataObjects vs. Propel vs. EzPDO vs .. Java!
Using an object perstistence layer can be greatly benefitial for any medium to large size project. Or, any project at all some would say. If you don’t know what I’m talking about, I’ll give you a quick example. Usually, in PHP we would do something ugly-bugly like this to retrieve info about a certain item in the database:
$res = mysql_query(“SELECT * FROM article WHERE ID=5”); if($row == mysql_fetch_assoc($res)) { echo $row[“title”]; // do something here } Compare it to this:
PHP is the Devil!
I’m a big fan of podcasts, and recently I stumbled upon this jewel. It’s not a podcast per se, but eight audio files containing presentations from Carson Workshops entitled ‘The Future Of Web Apps’. I’ve listened to three of them by now, and here’s what I’ve learnt so far:
Joshua Schachter, Delicious [mp3]; Don’t write for scalability, you won’t know what breaks before it breaks. People will molest your server.
The Java community retaliates – "PHP is …"
Ok, it’s time to let the people of #java on Ef-net let us know what they thought of PHP in the period from July to December 2005 (read: yes, I’ve done a grep -iH “php is” on my #java irclogs). Of course, we all know the PHP developers had strong opinions on Java, so this will be interesting.
< @Tenchi> php is terd < @aut> straight php is faster than using php to transform xml < waz> don’t forget “PHP is slow!
The IRC community speaks out – Java vs. PHP
Welcome to my new column. It’s basically a grep of all mentions of java in #php from July to December 2005.
The nicks have not been hidden to protect the guilty.
This is what the people in #php on ef-net think about Java as a programming language: < Johnboyo> java is awful, im a symbian programmer by trade and i avoid it at all costs < @feti> better than a low-level language.
1