You are not logged in.
Hello im developing a plugin i followed all the steps from the documentation the problem is when i try to activate the plugin glpi show me an error "¡Complement Whatsapp with CSRF incompatible!" idk why in my setup.php file i have this:
<?php
define('Whatsapp_Version','1.0.0');
function plugin_init_whatsappapi(){
global $PLUGIN_HOOKS;
$PLUGIN_HOOKS['csrf_compliant']['whatsappapi'] = true;
$PLUGIN_HOOKS['item_add']['whatsappapi'] = ['Ticket' => 'Whatsapp_ticket__updateitem_called'];
$PLUGIN_HOOKS['item_update']['whatsappapi'] = ['Ticket' => 'Whatsapp_ticket__updateitem_called'];
}
function plugin_version_whatsappapi(){
return[
'name' => 'Whatsapp',
'version' => '1.0.0',
'author' => 'Julian ',
'license' => 'GPLv2+',
'requirements' => [
'glpi' => [
'min' => '9.1'
]
]
];
}
?>
Error(this happend when i try to activate the plugin):
Offline
Which version of GLPI are you testing the plugin with?
GLPI Collaborator and Plugin Developer.
My non-English comments are automated translations. Sorry for any confusion that causes.
Mes commentaires non anglais sont des traductions automatiques. Désolé pour toute confusion qui cause.
Mis comentarios que no están en inglés son traducciones automáticas. Perdón por cualquier confusión que cause.
Offline
Which version of GLPI are you testing the plugin with?
im currently using GLPI 10.0.12
Offline
Is the plugin located in "plugins/whatsappapi" or "marketplace/whatsappapi" with the setup.php and hook.php files directly inside the plugin folder?
GLPI Collaborator and Plugin Developer.
My non-English comments are automated translations. Sorry for any confusion that causes.
Mes commentaires non anglais sont des traductions automatiques. Désolé pour toute confusion qui cause.
Mis comentarios que no están en inglés son traducciones automáticas. Perdón por cualquier confusión que cause.
Offline
Is the plugin located in "plugins/whatsappapi" or "marketplace/whatsappapi" with the setup.php and hook.php files directly inside the plugin folder?
its located in plugins/whatsappapi
Last edited by jetriixsm (2024-05-27 22:11:02)
Offline
The plugin folder name is case sensitive I believe. It has to match the internal name you choose for your plugin exactly. You would need to use "whatsappapi" for both the plugin folder name and the code.
GLPI Collaborator and Plugin Developer.
My non-English comments are automated translations. Sorry for any confusion that causes.
Mes commentaires non anglais sont des traductions automatiques. Désolé pour toute confusion qui cause.
Mis comentarios que no están en inglés son traducciones automáticas. Perdón por cualquier confusión que cause.
Offline
The plugin folder name is case sensitive I believe. It has to match the internal name you choose for your plugin exactly. You would need to use "whatsappapi" for both the plugin folder name and the code.
Thanks u so much bro, that was the error. After change the name folder i could activate the plugin
Offline
hello can you share the link of plugin.
Offline