Wednesday, 21 August 2013

WHMCS InvoicePaid hook

WHMCS InvoicePaid hook

I found it odd that in my hook I have a simple query.
mysql_query("SELECT description FROM tblinvoiceitems
where invoiceid = ". $vars[invoiceid] )or die("GET INVICE NOT WOKING ".
mysql_error());
It returns
Array
(
[0] => One Hour Block of Expert Technical Support Services
[description] => One Hour Block of Expert Technical Support Services
)
This is only one item of 3. Running the same query from the command line
returns
One Hour Block of Expert Technical Support Services
One Hour Block of Expert Technical Support Services
One Hundred Hour Block of Expert Technical Support Services
Can anyone explain why my hook isn't returning the complete results and
why it is repeating the first record twice, once as [0] and once as
[description]?

No comments:

Post a Comment