Welcome Guest, Not a member yet? Register   Sign In
Search Results
    Thread: CodeIgniter: the last year
Post: RE: CodeIgniter: the last year

Good to know Codeigniter community is active and going stronger. Thanks all the people who lead and moderate to make that possible!
4,553 Views
12 Replies
01-10-2024, 01:02 AM
dgvirtual
    Thread: Announcing: Bonfire - a drop-in admin area
Post: RE: Announcing: Bonfire - a drop-in admin area

You can see in my example (and in the official docs of Bonfire) that for the automatic detection to work the module classes should be namespaced like this: App\Modules\Modulename\[Controllers or Mo...
8,020 Views
24 Replies
12-28-2023, 04:04 AM
dgvirtual
    Thread: Announcing: Bonfire - a drop-in admin area
Post: RE: Announcing: Bonfire - a drop-in admin area

PHP Code: --  'App\Modules' => APPPATH . 'Modules/Pages', -- - you should not add Pages at the end. Leave it as in documentation: Code: --  'App\Modules' => APPPATH . 'Modules',  --
8,020 Views
24 Replies
12-28-2023, 12:49 AM
dgvirtual
    Thread: Announcing: Bonfire - a drop-in admin area
Post: RE: Announcing: Bonfire - a drop-in admin area

You can try adding this example module https://github.com/dgvirtual/bonfire2-pages-module And if it works, check for differences with yours. Did you really remake 40+ modules of yours to conform...
8,020 Views
24 Replies
12-28-2023, 12:02 AM
dgvirtual
    Thread: Checking if delete operation was successful
Post: RE: Checking if delete operation was successful

Today I checked my original code in the first post, and now, on Codeigniter 4.4.3, it works as expected, deleted row number is reported correctly (0 if nothing is deleted, 1 if one row...). Works with...
1,895 Views
5 Replies
11-24-2023, 06:01 AM
dgvirtual
    Thread: Let's share custom validation rules
Post: RE: Let's share custom validation rules

Another validation function checks if the supplied value is unique to a particular user; it presupposes that the user ID in a particular db table is saved in `user_id` field and that the current user ...
479 Views
1 Replies
10-03-2023, 01:34 PM
dgvirtual
    Thread: Let's share custom validation rules
Post: Let's share custom validation rules

I think it would be beneficial to share custom validation rules. So, I will post some of mine below. They might not be very universal, but still useful. [hr] Rule  for validation rule for Lithuani...
479 Views
1 Replies
09-29-2023, 03:17 AM
dgvirtual
    Thread: Unable to install Bonfire2 in CI appstarter project
Post: RE: Unable to install Bonfire2 in CI appstarter pr...

DejaDingo Wrote: (09-21-2023, 12:52 PM) -- I'm trying to create a base project from which I can compare any updates to CI4 and BF2 going forward, but I can no longer run the documented procedure for ...
1,099 Views
5 Replies
09-29-2023, 03:15 AM
dgvirtual
    Thread: How to access images under writable folder
Post: RE: How to access images under writable folder

This might be useful to some, so here is how to properly keep image files (or other files) not in public dir but in writable dir, still loadable in html (but also, if needed, restricting public access...
33,606 Views
14 Replies
09-16-2023, 10:12 AM
dgvirtual
    Thread: CodeIgniter HTMX
Post: RE: CodeIgniter HTMX

michalsn Wrote: (08-28-2023, 02:59 AM) -- @dgvirtual you can try following these instructions: https://michalsn.github.io/codeigniter-htmx/troubleshooting/ for BaseController. If that doesn't help, I...
8,941 Views
18 Replies
08-29-2023, 12:41 AM
dgvirtual
    Thread: Announcing: Bonfire - a drop-in admin area
Post: RE: Announcing: Bonfire - a drop-in admin area

kilishan Wrote: (08-28-2023, 06:30 AM) -- I would love a PR for making the password visible. That would be awesome. -- Great, it is done. See this PR: https://github.com/lonnieezell/Bonfire2/pull/4...
8,020 Views
24 Replies
08-28-2023, 09:50 AM
dgvirtual
    Thread: CodeIgniter HTMX
Post: RE: CodeIgniter HTMX

@"michalsn", is there any way to make vscode to recognize the codeigniter-htmx request and response methods? Annoying when it shows errors for htmx - specific methods.
8,941 Views
18 Replies
08-28-2023, 02:50 AM
dgvirtual
    Thread: Announcing: Bonfire - a drop-in admin area
Post: RE: Announcing: Bonfire - a drop-in admin area

I have two suggestions regarding registration screen: https://ibin.co/w800/7YPDd5pIIMFk.png 1. Do we really need the username? It seems to not be used at all anywhere in the system. And the com...
8,020 Views
24 Replies
08-28-2023, 01:09 AM
dgvirtual
    Thread: getting uri_string() to work with Controller tests (phpunit)
Post: RE: getting uri_string() to work with Controller t...

kenjis Wrote: (08-09-2023, 05:22 PM) -- Try this: PHP Code: --     public function testFirst()     {         /* */     } -- -- This does work, thanks!
772 Views
7 Replies
08-10-2023, 01:38 PM
dgvirtual
    Thread: getting uri_string() to work with Controller tests (phpunit)
Post: RE: getting uri_string() to work with Controller t...

kenjis Wrote: (08-09-2023, 01:12 PM) -- Oh, I thought see() was an assertion method. https://codeigniter4.github.io/CodeIgniter4/testing/response.html#dom-helpers But it just returns bool. The docu...
772 Views
7 Replies
08-09-2023, 01:23 PM
dgvirtual
    Thread: getting uri_string() to work with Controller tests (phpunit)
Post: RE: getting uri_string() to work with Controller t...

kenjis Wrote: (08-08-2023, 11:03 PM) -- The following test passes. PHP Code: --     public function testFirst()     {         $result = $this->withURI('http://example.com/checkup/first/second')...
772 Views
7 Replies
08-09-2023, 03:03 AM
dgvirtual
    Thread: getting uri_string() to work with Controller tests (phpunit)
Post: getting uri_string() to work with Controller tests...

I cannot make uri_string() and site_url() functions work within controllers when run through phpunit. For example, in a freshly installed composer project I add this route (in app/Config/Routes.ph...
772 Views
7 Replies
08-08-2023, 01:28 PM
dgvirtual
    Thread: phpunit testing routes only available after login
Post: RE: phpunit testing routes only available after lo...

kenjis Wrote: (08-07-2023, 02:25 AM) -- Yes, we can test only one request and the response at a time. When the page gets redirected, the browser will send a new request and gets the page you see. So...
1,328 Views
9 Replies
08-07-2023, 02:57 AM
dgvirtual
    Thread: phpunit testing routes only available after login
Post: RE: phpunit testing routes only available after lo...

kenjis Wrote: (08-06-2023, 05:50 PM) -- service[] is not an array key. Try $this->request->getPost('service') -- Thanks @"kenjis", actually it started to work :) The post array now looks like th...
1,328 Views
9 Replies
08-07-2023, 02:03 AM
dgvirtual
    Thread: phpunit testing routes only available after login
Post: RE: phpunit testing routes only available after lo...

And again, answering my own question, CI4 class mocking helps (only posting the Case2 test part): PHP Code: -- // Case2. form submitted with errors $security = $this->getMockBuilder('CodeIgn...
1,328 Views
9 Replies
08-06-2023, 11:57 AM
dgvirtual

Theme © iAndrew 2016 - Forum software by © MyBB