Welcome Guest, Not a member yet? Register   Sign In
Search Results
    Thread: HTML 303
Post: RE: HTML 303

chaos Wrote: (02-19-2023, 01:01 PM) -- UPDATE: I found out that the Filter CSRF was causing the redirect. Now i have to find how to exclude some routes form the filter CSRF. -- You can exclude some ...
848 Views
3 Replies
02-19-2023, 02:41 PM
Mobostar
    Thread: Replace image if it already exists while uploading
Post: RE: Replace image if it already exists while uploa...

I replaced Quote: -- $img->store($filepath, $filename) -- with Quote: -- $img->move($filepath, $filename, true) -- which solved the issue. The third parameter move() method accepts tells i...
2,807 Views
6 Replies
01-24-2023, 11:15 AM
Mobostar
    Thread: Replace image if it already exists while uploading
Post: RE: Replace image if it already exists while uploa...

In case anyone is interested, I think I found a solution. If I use $img->move() method instead of $img->store() then I can pass "true" to the move() method as the third parameter which tells it to ove...
2,807 Views
6 Replies
01-23-2023, 06:29 PM
Mobostar
    Thread: Replace image if it already exists while uploading
Post: RE: Replace image if it already exists while uploa...

captain-sensible Wrote: (01-23-2023, 01:23 PM) -- you must have heard the adage prevention is better than cure ? what I do with an upload  via a form is use of "file_exists" . I use file name from th...
2,807 Views
6 Replies
01-23-2023, 02:28 PM
Mobostar
    Thread: Replace image if it already exists while uploading
Post: Replace image if it already exists while uploading

Hi, I am having a problem with uploading images. Upload works but it renames the image and creates a new file with a new name if the image is already in the folder. If "image_name.jpg" already exists...
2,807 Views
6 Replies
01-23-2023, 12:36 PM
Mobostar
    Thread: PHPUnit code coverage report
Post: RE: PHPUnit code coverage report

OK found it. "defined('BASEPATH') or exit('No direct script access allowed');" was hiding in a file I kept around from when I was working with CI3.  I have no idea how and why PHPUnit is processing t...
756 Views
2 Replies
01-15-2023, 09:44 PM
Mobostar
    Thread: PHPUnit code coverage report
Post: PHPUnit code coverage report

Hello, I've been working on making some PHPUnit tests. The tests so far have been working fine, but when I try code coverage report I am getting the following error: Quote: -- phpunit tests/Cus...
756 Views
2 Replies
01-15-2023, 07:44 PM
Mobostar
    Thread: Class "Kint\Renderer\Renderer" not found
Post: RE: Class "Kint\Renderer\Renderer" not found

Yes, I initially made the mistake of not checking the upgrade instructions Michalsn mentioned. It is all good now. Thanks
8,996 Views
3 Replies
01-11-2023, 10:56 AM
Mobostar
    Thread: Class "Kint\Renderer\Renderer" not found
Post: Class "Kint\Renderer\Renderer" not found

Hi, I am getting the error below after I upgraded to 4.3 (from 4.2.11). Quote: -- Class "Kint\Renderer\Renderer" not found SYSTEMPATH/Config/Factories.php at line 129 -- I noticed that C...
8,996 Views
3 Replies
01-10-2023, 11:39 AM
Mobostar
    Thread: Function inside a validation rule
Post: RE: Function inside a validation rule

kenjis Wrote: (01-03-2023, 07:13 PM) -- The closure validation rule will be added in v4.3.0. See https://github.com/codeigniter4/CodeIgniter4/pull/6951 -- Great. Good to know. Thanks.
1,129 Views
4 Replies
01-03-2023, 07:31 PM
Mobostar
    Thread: Function inside a validation rule
Post: Function inside a validation rule

Hi, This type of custom validation rule used to work in CI3 but I am getting an error with CI4. Code: PHP Code: -- $validation->setRrules([     'room' => [         'label'    => 'Room',         'rul...
1,129 Views
4 Replies
01-03-2023, 01:07 PM
Mobostar
    Thread: Announcing Shield: an Official Authentication library
Post: RE: Announcing Shield: an Official Authentication ...

I wonder if this means Myth/Auth will be abandoned at some point in the future.
36,021 Views
42 Replies
08-11-2022, 05:10 AM
Mobostar
    Thread: Failed asserting that 302 is identical to 200
Post: RE: Failed asserting that 302 is identical to 200

kilishan Wrote: (04-18-2022, 08:07 PM) -- You can simulate a logged in user with the AuthTestTrait (https://github.com/lonnieezell/myth-auth/blob/develop/docs/testing.md#authtesttrait). It would be s...
1,989 Views
4 Replies
04-19-2022, 08:34 AM
Mobostar
    Thread: Failed asserting that 302 is identical to 200
Post: Failed asserting that 302 is identical to 200

Hello, I am working on this personal project just to learn CI4 and Myth Auth. I am getting the PHPUnit failure message you see in the topic line. "Failed asserting that 302 is identical to 200." when ...
1,989 Views
4 Replies
04-18-2022, 01:13 PM
Mobostar
    Thread: Error: Use of undefined constant ENVIRONMENT - CI 4.1.5
Post: RE: Error: Use of undefined constant ENVIRONMENT -...

I did a fresh CI4 installation via Composer and that error disappeared.
3,616 Views
4 Replies
11-22-2021, 09:28 AM
Mobostar
    Thread: Error: Use of undefined constant ENVIRONMENT - CI 4.1.5
Post: RE: Error: Use of undefined constant ENVIRONMENT -...

The following is the "PHP stack trace" for the same error in case it helps. Code: -- PHP Stack trace: PHP  1. {main}() /var/www/xyz.com/spark:0 PHP  2. require() /var/www/xyz.com/spark:44 PHP  ...
3,616 Views
4 Replies
11-20-2021, 08:10 PM
Mobostar
    Thread: Error: Use of undefined constant ENVIRONMENT - CI 4.1.5
Post: Error: Use of undefined constant ENVIRONMENT - CI ...

Hello, I am getting this error when I run "spark" to create a migration. Code: -- $ php spark migrate:create create_posts_table PHP Warning:  Use of undefined constant ENVIRONMENT - assumed 'ENVIRONM...
3,616 Views
4 Replies
11-20-2021, 06:50 PM
Mobostar
  Thumbs Up Thread: CodeIgniter 4.0 is here!
Post: RE: CodeIgniter 4.0 is here!

Congrats :)
212,235 Views
132 Replies
02-24-2020, 10:51 AM
Mobostar
    Thread: CI4 and Myth Auth
Post: RE: CI4 and Myth Auth

Base URL is correct but I had forgotten to change $indexPage = 'index.php' to $indexPage = '' in Config/App.php. Once I fixed that Auth stopped using "index.php" when redirecting to login page.
8,695 Views
4 Replies
02-17-2020, 05:16 PM
Mobostar
    Thread: CI4 and Myth Auth
Post: CI4 and Myth Auth

Hello, I will need an Auth for CI4 and I decided to check out Myth Auth for CI4. So, I installed it via Composer, and did the basic settings following the instructions at https://github.com/lon...
8,695 Views
4 Replies
02-11-2020, 03:41 PM
Mobostar

Theme © iAndrew 2016 - Forum software by © MyBB