title: PHP finally clause
body: <p>What is the best practice to simulate a finally clause? I realize this could be considered related (though I don't think it's a duplicate) of <a href="https://stackoverflow.com/questions/6043768/finally-clause-alternative-for-script-timeout">this question</a>.</p>
  
  <p>However, in my case I want to handle exceptions, I want to use finally (or whatever PHP equivalent or practice) as defined by python:</p>
  
  <blockquote>
    <p>A finally clause is always executed before leaving the try statement, whether an exception has occurred or not.</p>
  </blockquote>
  
  <p>Just loosely writing the code after the try-catch block seems like an ugly practice to me.</p>