Title: WordPress hooks with parameters function don&#039;t work
Last modified: August 22, 2016

---

# WordPress hooks with parameters function don't work

 *  [miguelangelss4](https://wordpress.org/support/users/miguelangelss4/)
 * (@miguelangelss4)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/wordpress-hooks-with-parameters-function-dont-work/)
 * I need add an action that retrieves a parameter. I have this:
 *     ```
       add_action('dopbsp_reservation_approve_hilo', array(&$this->classes->backend_reservation, 'approve_hilo'), 1, 1);
       //add_action('wp_ajax_dopbsp_reservation_approve_hilo', array(&$this->classes->backend_reservation, 'approve_hilo'), 1, 1); tested to, same result
       do_action('dopbsp_reservation_approve_hilo',  $reservation_id); //I had confirmed that $reservation_id has the correct value
       ```
   
 * And my function is declared this way:
 *     ```
       function approve_hilo($reservation_id){
       //my stuff goes here...
       }
       ```
   
 * But approve_hilo function is never called. Do you know what is wrong?
 * thanks you all in advance!

The topic ‘WordPress hooks with parameters function don't work’ is closed to new
replies.

## Tags

 * [hook](https://wordpress.org/support/topic-tag/hook/)
 * [parameters](https://wordpress.org/support/topic-tag/parameters/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [miguelangelss4](https://wordpress.org/support/users/miguelangelss4/)
 * Last activity: [11 years, 8 months ago](https://wordpress.org/support/topic/wordpress-hooks-with-parameters-function-dont-work/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
