Thanks bro, i started a project while using your tutorials both CI API and VUE frontend, but i have one question if you can help me bro, after login from vue, how can i get userdata alongwith access token?? please help if you do, my project is opensource about free education to all, so i am not charging anything on that bro. i need help on this one
when i submit the 'form' Error pops up saying "Invalid argument supplied for foreach()" It shows error in "SYSTEMPATH\BaseModel.php at line 1544" how can i fix this ?
Could someone help me? I want to return the last id (Primary Key) from my table users after the registration ( $model->insert($data); ) How can I achieve that?
You welcome. Maybe when u have time, make a tutorial how to make a custom hook, i mean , after comments section, or after i commented on a article. Or a plugin, like how wordpress use. I don't want to use wp anymore, because for my projects is very complicated, and i try to make it sample. Thank u, again !
I'd faced this error. Class "App\Models\UserModel" not found while pressing Register Button and not able to find the solution over the stack over flow. Plz help with this issue
3 года назад
C:\xampp\htdocs\ci4\login\app\Controllers\Users.php must write to 3.line: use App\Models\UserModel;
Alex keep making video's Codeigniter can use a lot off good tutorials. But why you don't use the restfull routes that is so must straight forward. I like the way to put more in de models so why not using model validation? See this as a positve comment. Keep making videos
You mean why I did not use /users/profile or users/register ? If so then the priority for me is user's (visitor's) satisfaction, so I believe shorter uri's are always better. And for the user validation, the idea of validating the user by using validation form rules just seemed interesting scenario to create a custom rule and show to the people how you can create custom validation rules. Doing it in the Model would be also good. Thanks for the comment @andre jansen
Hello friends, I tried to run this code and i am getting an errors which says : Class 'APP\Models\UserModel' not found at line 48 which is : $model = new UserModel(); In my controller, i have included this line of code : use APP\Models\UserModel; In my Model, i have also included : use CodeIgniter\Model Can someone help on that please?
I'm getting the error min_lenght is not a valid rule. SYSTEMPATH\Validation\Exceptions\ValidationException.php at line 10 3 use CodeIgniter\Exceptions\ExceptionInterface; 4 use CodeIgniter\Exceptions\FrameworkException; 5 6 class ValidationException extends FrameworkException implements ExceptionInterface 7 { 8 public static function forRuleNotFound(string $rule = null) 9 { 10 return new static(lang('Validation.ruleNotFound', [$rule])); 11 } 12 13 public static function forGroupNotFound(string $group = null) 14 { 15 return new static(lang('Validation.groupNotFound', [$group])); 16 } 17
Hi I'm sorry for my bad english. instead of error codes, the screen appears as whoops. How can I open the error codes instead. I am waiting for your help.
Did you create a ".env" ? If no, then duplicate the "env" file into '.env', then find a line with # CI_ENVIRONMENT = production uncomment it and replace production with development CI_ENVIRONMENT = development
Hi Alex, do you have any video using transactions? I am trying to save information in two different tables. Documentation: $this->db->transStart(); $this->db->query('AN SQL QUERY...'); $this->db->query('ANOTHER QUERY...'); $this->db->query('AND YET ANOTHER QUERY...'); $this->db->transComplete(); But i want to: $myModelOne = new MyModelOne(); $myModelTwo = new MyModelTwo(); $this->db->transStart(); $this->myModelOne->insert($dataOne); $this->myModelTwo->insert($dataTwo); $result = $this->db->transComplete(); if($result){ //Success }else{ //error } I dont know how to do it. Can you help me? Thanks.
hey Alex, I copy your code as you do but in my case, the error list is not shown in my registration form like 9:17 the error list
if (! $this->validate($rules)) {
$data['validation'] = $this->validator;
}
Thanks bro, great tutorial, you save me ;D
hey Alex i copied the code but my errorlist is not showing... do u know what can be the problem?
what is the extension on the chrome? and can u please make tutorial on background image setting in codeigniter 4??
fake filler
Thanks bro, i started a project while using your tutorials both CI API and VUE frontend, but i have one question if you can help me bro, after login from vue, how can i get userdata alongwith access token?? please help if you do, my project is opensource about free education to all, so i am not charging anything on that bro. i need help on this one
when i submit the 'form' Error pops up saying
"Invalid argument supplied for foreach()"
It shows error in "SYSTEMPATH\BaseModel.php at line 1544"
how can i fix this ?
Thanks !!! very useful videos
You're welcome
Could someone help me?
I want to return the last id (Primary Key) from my table users after the registration ( $model->insert($data); )
How can I achieve that?
the best tutorial for CI. Subscribe button !!!!
Wow, thanks!
You welcome. Maybe when u have time, make a tutorial how to make a custom hook, i mean , after comments section, or after i commented on a article. Or a plugin, like how wordpress use. I don't want to use wp anymore, because for my projects is very complicated, and i try to make it sample. Thank u, again !
I'd faced this error. Class "App\Models\UserModel" not found while pressing Register Button and not able to find the solution over the stack over flow. Plz help with this issue
C:\xampp\htdocs\ci4\login\app\Controllers\Users.php must write to 3.line: use App\Models\UserModel;
Dont know why save is only updating but not inserting though primary key is there.
what is the name of the chrome extension that you use?
The name is Fake filler
Thank you so much for this awesome series .. one question tho, what is you vscode font face?
Hey, Sherif, it is the default one. I don't remember changing my font.
Thanks for watching.
Hi! Somehow in CI 4.0.4 min/max lenght rule not working.
Yeah strange, you figured it out?
I'm facing an error on register.php page that $validation variable is not defined........
Getting the same. Did you ever figure out the issue?
EDIT: Its the missing endif statement that's causing the error.
Thanks. Great Tutorial
Thank you.
I am getting a "WHOOOPS we seem to have hit a snag. Please Try Again Later" when i press the login button.
help :(
I've followed all your steps, but when i'm trying to log in, i can access even if the password isn't the correct one, can you help me?
What extension are you using to generate fake data ?
Hey Alex,
Prasad here
i download this prjct from github and i set .env and migrate also
but when i click register it will show me error please help
Thanks a lot...
Hi Alex, I have followed your tutorial and for some reason, the alert danger is not showing any error message. I don't know what went wrong.
i use this sentense
@@alejandrorosales thanks!
Alex keep making video's Codeigniter can use a lot off good tutorials.
But why you don't use the restfull routes that is so must straight forward.
I like the way to put more in de models so why not using model validation?
See this as a positve comment.
Keep making videos
You mean why I did not use /users/profile or users/register ?
If so then the priority for me is user's (visitor's) satisfaction, so I believe shorter uri's are always better.
And for the user validation, the idea of validating the user by using validation form rules just seemed interesting scenario to create a custom rule and show to the people how you can create custom validation rules. Doing it in the Model would be also good.
Thanks for the comment @andre jansen
@@AlexLancer For security reasons use csrf in the forms!
I miss that completely in your tuts.
I think that is a good choice for video 6 form security.
Yeah. Good idea thanks.
@@snelledre what do you mean by model validation I'm intrigued?
@@jigglypotatoes See the docs codeigniter.com/user_guide/models/model.html#validating-data
Thanks very helpfull
Glad to hear!
Hello friends,
I tried to run this code and i am getting an errors which says :
Class 'APP\Models\UserModel' not found
at line 48 which is : $model = new UserModel();
In my controller, i have included this line of code : use APP\Models\UserModel;
In my Model, i have also included : use CodeIgniter\Model
Can someone help on that please?
maybe namespace should be App\..... not APP\....
in the doc has an alert about the $upper parameter from getMethod of request, it says that now is deprecated, so what do i use instead?
got the same problem
did you find a solution?
I'm getting the error
min_lenght is not a valid rule.
SYSTEMPATH\Validation\Exceptions\ValidationException.php at line 10
3 use CodeIgniter\Exceptions\ExceptionInterface;
4 use CodeIgniter\Exceptions\FrameworkException;
5
6 class ValidationException extends FrameworkException implements ExceptionInterface
7 {
8 public static function forRuleNotFound(string $rule = null)
9 {
10 return new static(lang('Validation.ruleNotFound', [$rule]));
11 }
12
13 public static function forGroupNotFound(string $group = null)
14 {
15 return new static(lang('Validation.groupNotFound', [$group]));
16 }
17
Popo, please upload you code to github so that I can see it.
github.com/Danyyy9/Appcodeigniter
its because you have miss spelled as "min_lenght" and not "min_length" ....lol
What's is it 24:54, blue button? I like it
Chrome Extension Form Filler
@@AlexLancer thank you so much
Hi I'm sorry for my bad english. instead of error codes, the screen appears as whoops. How can I open the error codes instead. I am waiting for your help.
Did you create a ".env" ? If no, then duplicate the "env" file into '.env', then find a line with
# CI_ENVIRONMENT = production
uncomment it and replace production with development
CI_ENVIRONMENT = development
Thank you broh
You're welcome
I have followed this but I get the following error: "You must use the "set" method to update an entry." And my user is not being added to my database
Hey Dan thanks for watching my Codeigniter 4 tutorial. Can you share some code so that i can see what are you talking about exactly?
@@AlexLancer I managed to fix it, I was trying to add an additional field in my database
How can I move Register button little bit right side, in register.php
I am not sure if I understand you correctly, but try adding "float-right" class to your html button.
Error: getVar() is undefined
does someone know a fix to this???
Yeah, its ocurr bcz the PHP inteliphense
thanks
U r welcome
Hi Alex, do you have any video using transactions?
I am trying to save information in two different tables.
Documentation:
$this->db->transStart();
$this->db->query('AN SQL QUERY...');
$this->db->query('ANOTHER QUERY...');
$this->db->query('AND YET ANOTHER QUERY...');
$this->db->transComplete();
But i want to:
$myModelOne = new MyModelOne();
$myModelTwo = new MyModelTwo();
$this->db->transStart();
$this->myModelOne->insert($dataOne);
$this->myModelTwo->insert($dataTwo);
$result = $this->db->transComplete();
if($result){
//Success
}else{
//error
}
I dont know how to do it. Can you help me? Thanks.
Hey, Andrei, no I did not create any. Will have to look into it.
70 % water, you can do better
how i miss 'php artisan make:auth'
lol