Jump to content

SQL Question


CurtyCat

Recommended Posts

I'm attempting to create a hook in /Includes/Hooks that will perform an action after an order has been accepted. Part of this means pulling information that was created in a table under a provisioning module that had fields populated.

 

I'm not quite sure about the query system in Capsule (even with the guide to prevent SQL injections). Will calling the query on the table mean that Capsule doesn't require a specific directory to reach that table? How does it know where the table is? Can I just reference any table in any Database on my WHMCS account?

 

Also, for example if you had something like:

 

$all = Capsule::table('tblcustomfieldvalues')->get();

 

Would $all now be an array of all fieldid's relids and values? How is the information being stored? I'm using my browser to look at the php file I made for the hook to test it and I can't seem to figure out the SQL part. Any help appreciated!

 

Best Regards.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated