title: Prestashop Module: hooks and orders
body: <p>I am having multiple questions about this topic</p>
  
  <p>As the title states, I am in need to find the correct hook to bind when an order has been placed and the payment was accepted. </p>
  
  <p>1.) Which hook should I bind in my module when an order has been placed (and payed)? </p>
  
  <p>2.) I am under the impression that there is no generalized hook for this, since some payment methods set the order status to 'payed' automatically (like a successful PayPal transaction) while other methodes require the shopowner to manually set the status to 'payed'. Are there any more than just those two that must be called to cover most cases?</p>
  
  <p>3.) Eventhough I am still hoping that there is a generalized hook, if there's none, how would I approach this issue? Bind "actionPaymentConfirmation" aswell as "displayPaymentReturn" to cover both cases?</p>
  
  <p>4.) Why is the hook "actionPaymentConfirmation" never called when I set the order status to "payed" in the backoffice. My code looks like this</p>
  
  <pre><code>public function install() {
  
     if (!parent::install() || !$this-&gt;registerHook("actionPaymentConfirmation")) {
          return false;
      }
      return true;
  }
  
  public function actionPaymentConfirmation($params) {
      print_r($params);   // stepping through with XDebug but the function is never being invoked
  }
  </code></pre>
  
  <p>5.) Does anyone know a free module doing something simmilar I can dig into to get a better idea?</p>
  
  <p>6.) Or might it be easier to override Prestashops core classes to tackle my problems? To break it down, I want to execute stuff after an order has been placed and the status is set to payment was accepted or remotely accepted.</p>
  
  <p>Well, I hope I am not asking to much stuff at the same time, but as you can see, I am interested in mastering these things but have some troubles along the way. Have now been trying and especially search for answers for days now without any luck. </p>
  
  <p>Regards!</p>