title: How to check that an object is empty in PHP?
body: <p>How to find if an object is empty or not in PHP.</p>
  
  <p>Following is the code in which <code>$obj</code> is holding XML data. How can I check if it's empty or not?</p>
  
  <p>My code:</p>
  
  <pre><code>$obj = simplexml_load_file($url);
  </code></pre>