Jump to content
  • 0
BillDjango

Connecting to remote database

Question

I'm using WHMCS and WBTeamPro as a project management tool.   Our old project management tool isn't exactly friendly for exporting and importing, so instead of doing that,  i'm writing a module that adds a tab to each clients profile where you can click the link to view the past projects, tasks and time logs directly from that systems database. 

I swore off PHP years ago in favor of Python, so i'm a bit out of practice.     In my module config i'm collecting the usual DB connection information, and then trying to pass it to mysqli to connect to the remote database from within the module/lib/Admin/controller.php file.     

For some reason I get an error:  "Error: Class 'WHMCS\\Module\\Addon\\activecollabdisplay\\Admin\\mysqli' not found in /home/www/....."

At first I thought maybe mysqli isn't installed.  So I took at look at the php info and it shows it is enabled. 

Any hints or suggestions on how I can make this happen?

 

Thanks!

Share this post


Link to post
Share on other sites

1 answer to this question

Recommended Posts

  • 1

This was resolved by support.     Since my posts usually are moderated for a day + I wrote them and asked.

I just had to add use mysqli to the beginning of the file then laravel let me use it.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×

Important Information

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