bstellar Posted July 29, 2018 Share Posted July 29, 2018 How do I access the session variable user id to determine if the client is logged in? And then, how do I access the database class that will get me the client name for the user id that is logged in? There have been several people asking this question and no one answering it, except one guy that gave a solution in 2011 that appears to be obsolete now (there is no file called dbconnect.php) This is for a non-WHMCS page. Not a page in the WHMCS sub folders 0 Quote Link to comment Share on other sites More sharing options...
WGS Posted August 1, 2018 Share Posted August 1, 2018 Hi, In latest version of WHMCS, WHMCS has removed the dpconnect.php file. Now, in WHMCS you can find the file name with "init.php". Please use this file instead of dbconnect.php. And one thing mysql is deprecated in latest WHMCS. So, you have to use Capsule queries for that. For Capsule queries , follow this link: https://developers.whmcs.com/advanced/db-interaction/ 0 Quote Link to comment Share on other sites More sharing options...
bstellar Posted August 1, 2018 Author Share Posted August 1, 2018 WGS, Thank you so much! I have been struggling with this for 2 months. It's not easy trying to integrate with encrypted files. I will try again with the info you gave. Thank you. 0 Quote Link to comment Share on other sites More sharing options...
WGS Posted August 1, 2018 Share Posted August 1, 2018 2 hours ago, bstellar said: WGS, Thank you so much! I have been struggling with this for 2 months. It's not easy trying to integrate with encrypted files. I will try again with the info you gave. Thank you. Sure, The above information should be work for you. Just try it! 0 Quote Link to comment Share on other sites More sharing options...
bstellar Posted August 2, 2018 Author Share Posted August 2, 2018 WGS, I got it to work! I now have fully integrated my menu with WHMCS. Thanks again, Beth 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.