3

I am currently trying to create a participant on a Drupal form submit, when i do this I get an error saying Authorization failed. I've tried managing the ACLs in Civi with no success, I've also changed the drupal roles to allow anyone to add a participant. I've also tried to set the permissions manually using the code below

hook_civicrm_alterAPIPermissions($entity, $action, &$params, &$permissions) {
  $permissions['Participant'] = array(
    'get' => array(
      'access CiviCRM',
      'access CiviEvent',
      'edit all events',
    ),
  );
}

but this didn't work either

If anyone has any suggestions it would be a great help, I can supply more information if needed

thanks in advanced!

EDIT: I found that I needed to allow users access to the backend of civi to get this to work, this is not ideal so I am still looking for workarounds

  • I am currently trying to create a participant on a Drupal form submit - can you share the code of this part so we can see where the error is being generated? – jitendra - fuzion Nov 8 at 12:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.