Welcome Guest, Not a member yet? Register   Sign In
Search Results
    Thread: How to load config options into library from model. in Ci4.5
Post: RE: How to load config options into library from m...

This works, didn't think it would be that easy for some reason lol. PHP Code: -- $config = array( 'Sandbox' => FALSE, 'APIUsername' => $pp_username, 'APIPassword' => $pp_password, ...
597 Views
1 Replies
05-30-2024, 12:21 PM
xsPurX
    Thread: How to load config options into library from model. in Ci4.5
Post: How to load config options into library from model...

I have this from ci2.2 I want to know how I can do this in CI4.5 PHP Code: -- $config = array( 'Sandbox' => FALSE, 'APIUsername' => $pp_username, 'APIPassword' => $pp_password, 'APISi...
597 Views
1 Replies
05-30-2024, 06:53 AM
xsPurX
    Thread: codeigniter 4.5 loading view issue
Post: RE: codeigniter 4.5 loading view issue

ozornick Wrote: (05-27-2024, 08:16 PM) -- PHP Code: -- return $this->test2(); -- Each return must have a return higher when called. :huh: -- Ah I see. This app was written in ci2.2 so I guess ...
1,057 Views
3 Replies
05-28-2024, 07:25 AM
xsPurX
    Thread: codeigniter 4.5 loading view issue
Post: codeigniter 4.5 loading view issue

PHP Code: -- function test() { $this->test2(); } function test2() { return view('/themes/default_2024/layouts/Gateway/test'); } -- I get a wh...
1,057 Views
3 Replies
05-27-2024, 12:36 PM
xsPurX
    Thread: 4.4.1 to 4.4.8 base_url php spark closes..
Post: RE: 4.4.1 to 4.4.8 base_url php spark closes..

kenjis Wrote: (05-09-2024, 05:36 AM) -- I forgot to mention that the above code is vulnerable because it does not validate the value of $_SERVER['HTTP_HOST']. In a production environment, all user i...
1,979 Views
6 Replies
05-09-2024, 06:21 AM
xsPurX
    Thread: Protect certain pages in Shield?
Post: RE: Protect certain pages in Shield?

Edit /Config/Filters.php Code: --   public array $filters = [         'group:admin,superadmin,user'  => ['before' => ['UserDashboard', 'UserDashboard/*', 'Order', 'Order/*']],     ]; -- Just an exam...
897 Views
2 Replies
05-08-2024, 08:34 AM
xsPurX
    Thread: QueryBuilder inside
Post: RE: QueryBuilder inside

So this wouldn't work either? just an example. Cause I have this code from active record codeigniter 2. so if I rewrote this. in query builder? Code: -- $uri_web = $this->uri->segment(3); $sites =...
1,772 Views
5 Replies
05-07-2024, 07:11 AM
xsPurX
    Thread: 4.4.1 to 4.4.8 base_url php spark closes..
Post: RE: 4.4.1 to 4.4.8 base_url php spark closes..

kenjis Wrote: (05-07-2024, 01:50 AM) -- Your code does not work with spark due to a PHP Fatal error. > PHP Fatal error:  Uncaught CodeIgniter\Exceptions\ConfigException: Config\App::$baseURL "http://...
1,979 Views
6 Replies
05-07-2024, 06:37 AM
xsPurX
    Thread: 4.4.1 to 4.4.8 base_url php spark closes..
Post: 4.4.1 to 4.4.8 base_url php spark closes..

Hi, I'm working on updating to 4.4.8 and my base url is defined like below. Code: -- public string $baseURL = BASE_URL; -- in config/Constants.php I have Code: -- $base_url = (isset($_SERVER['HTT...
1,979 Views
6 Replies
05-06-2024, 11:31 AM
xsPurX
    Thread: Cannot access protected property CodeIgniter\HTTP\IncomingRequest::$uri
Post: RE: Cannot access protected property CodeIgniter\H...

Bosborne Wrote: (05-03-2024, 03:39 AM) -- xsPurX Wrote: (04-25-2024, 02:10 PM) -- who was the idiot that did that.... it breaks an entire system. Why do standards keep changing so much to render an...
6,972 Views
12 Replies
05-03-2024, 07:17 AM
xsPurX
    Thread: Filters in filters folder. how to use them?
Post: Filters in filters folder. how to use them?

Might seem like a dumb question, but I created this filter below, I am using Shield, I want the user to be redirected when accessing a protected controller. Right now it redirects to /login. and I wan...
488 Views
0 Replies
05-01-2024, 03:01 PM
xsPurX
    Thread: request URL not found
Post: RE: request URL not found

IF your using ci 4.5 check in app/config/routing.php that autoroutes is turned on. public bool $autoRoute = true; Not sure why in Ci 4.5 they have it off by default.
2,500 Views
7 Replies
04-30-2024, 05:46 AM
xsPurX
    Thread: Pagination is slow?
Post: RE: Pagination is slow?

Thanks, That actually worked! :D
861 Views
2 Replies
04-29-2024, 04:50 AM
xsPurX
    Thread: Pagination is slow?
Post: Pagination is slow?

Hi, I ran the pagination system and there is a 1-2 second delay to load my page now. Even though there is only a few records. Where without pagination it loads fast. The development debugger doesn't e...
861 Views
2 Replies
04-28-2024, 01:01 PM
xsPurX
    Thread: Modify users data as an admin
Post: RE: Modify users data as an admin

Can just wrap your edit() function to do an if around it, to reload the form if the validation is false, or go somewhere else if its good. Either that or in your update() whatever your form action is....
3,663 Views
4 Replies
04-27-2024, 01:37 PM
xsPurX
    Thread: Modify users data as an admin
Post: RE: Modify users data as an admin

This sql query will give you a list of users, and you can use the user_id to make changes depending on what you want to do, if you need to update data in two tables just run two different update queri...
3,663 Views
4 Replies
04-27-2024, 10:54 AM
xsPurX
    Thread: Cannot access protected property CodeIgniter\HTTP\IncomingRequest::$uri
Post: RE: Cannot access protected property CodeIgniter\H...

who was the idiot that did that.... it breaks an entire system. Why do standards keep changing so much to render an entire system needing an upgrade cause someone changes the syntax.  ridiclous.
6,972 Views
12 Replies
04-25-2024, 02:10 PM
xsPurX
    Thread: Update to v4.5.1, same using FactoriesCache
Post: RE: Update to v4.5.1, same using FactoriesCache

kenjis Wrote: (04-17-2024, 07:47 PM) -- Ah, remove psr extention. It is outdated. https://github.com/jbboehr/php-psr -- how do you remove it?
2,381 Views
6 Replies
04-25-2024, 08:31 AM
xsPurX
    Thread: Codeigniter Shield Banning users?
Post: RE: Codeigniter Shield Banning users?

Ok, thanks very much. Makes sense now. :)
1,414 Views
5 Replies
04-24-2024, 05:37 PM
xsPurX
    Thread: Codeigniter Shield Banning users?
Post: RE: Codeigniter Shield Banning users?

So I would get the user like this? Code: -- $users = auth()->getProvider(); $user = $users->findById(123); --
1,414 Views
5 Replies
04-24-2024, 04:52 PM
xsPurX

Theme © iAndrew 2016 - Forum software by © MyBB