Fix call to is_a to be compatible with php <= 5.3.9

Fixes #142
Need to replace is_a completely.

fixes #142 (for reals)
Merge pull request #143 from mlively/issue/142

Fix call to is_a to be compatible with php <= 5.3.9