Welcome Guest, Not a member yet? Register   Sign In
I can i declare Thirdparty Library globally
#1

I can i declare Library globally

 $this->ionAuth    = new \IonAuth\Libraries\IonAuth();
i want to access $this->ionAuth from anywhere. So how can i declare this globally so that i can access $this->ionAuth form Models, View , and Controller
Reply
#2

This would be a good idea to use a service.

CodeIgniter 4 User Guide - Services
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply
#3

Solved using service and helper Smile
Reply
#4

(03-04-2020, 02:40 AM)samyam Wrote: Solved using service and helper Smile
you are right but i dind like the way declearing
auth() as function
Reply




Theme © iAndrew 2016 - Forum software by © MyBB