Hello,
I would like to know if it is possible to run mysql queires through hooks please:
function tablename_before_insert(&$data, $memberInfo, &$args){
return TRUE;
}
If yes, do we have to create a mysql connection in each hook file or does your file connect automatically?
Thank you,
Ben
Can we run mysql queries in hooks?
Re: Can we run mysql queries in hooks?
Yes. This is possible. You do not need to create a new connection each time. See a discussion I had which ended with sql queries as a solution. Some good sql examples there :
http://forums.appgini.com/phpbb/viewtopic.php?t=637
http://forums.appgini.com/phpbb/viewtopic.php?t=637