Only other thing that you may or may not want to add is some sort of notification that upload_directory is not writable. It made me stumble for seconds but could be more confusing for others.
It turns out that CI has a function that checks for true writability. The function is located in Common.php, and is named is_really_writable(). The upload class is calling that function through Upload->validate_upload_path(). Tell me more about the problem. I assumed you meant you were having problems with uploading and there not being an error message when the directory is not writable, but you should be getting an error message if it isn’t writable.
This project looks really interesting and I would like to give it a spin, but I have been getting this error while trying to install the most recent tip.
Whenever I click “Run” I get this error:
Sorry, the following errors occured during the installation procedure: No Token Match
Note that CSRF is turned off in the application/config file.
I’ve not had anybody else complain about this error, and after reading your issue on bitbucket, I did a run-through on the installation without problems. I am interested to find out what is going on though. If there is a way I can have access to the server, I’d be more than happy to figure out what is going on.
Am totally new to codeigniter, but i came across your authenntication library and its really resourcefull in my fourth year project.
I was able to setup everything but i have had problems when a user registers, there is no mail sent for account activation or approval, and no account is registered at all.
The other issue is password recovery, also no link is sent to the provided email.
Am totally new to codeigniter, but i came across your authenntication library and its really resourcefull in my fourth year project.
I was able to setup everything but i have had problems when a user registers, there is no mail sent for account activation or approval, and no account is registered at all.
The other issue is password recovery, also no link is sent to the provided email.
Kindly advice.
Thanks in advance.
Paul Tanui
Hi Paul,
When in the development environment, which is set in index.php, emails are not sent. Instead, the email is stored in application/logs/email.
Apparently, I was able to see my emails and also set it to production mode but still a little bit in a fix, still unable to receive email link for account activation, where am i missing?
Apparently, I was able to see my emails and also set it to production mode but still a little bit in a fix, still unable to receive email link for account activation, where am i missing?
And thanks for sharing your work.
Paul K
If no email is sent, then chances are that the email config is not correct for your particular server. Some servers require SMTP authentication, and by default Community Auth is not configured to send emails via SMTP.
If the email is sent but no link is in the email, it is potentially the email client stripping the link out of the email. Most email clients allow you to browse the source of the email. I would take a look at the source and verify that the output is what you would expect. Since the output is derived from a simple view, you would need to trace a bug back through the registration code to find out what is wrong. Chances are it’s just a config issue, because this has been tested and re-testing, and used in a production environment for many days.
Remember, you have FirePHP, Firebug, and ChromePHP at your disposal. It shouldn’t take long to track down the error, but keep this in mind:
1) FirePHP is turned off at the top of MY_Controller if you are in the production environment.
2) FirePHP can cause a Community Auth CSRF cookie to disappear if you are following a link from an email client. Whenever you have a problem logging in or with forms that don’t seem to work, turn off FirePHP.
Note for docs: in your index.php you have hardwired the application folder name into the include statement for ChromePHP on line 104:
case 'development': case 'testing': error_reporting(-1);
// Load ChromePhp for PHP debugging in Google's Chrome browser include 'application/libraries/ChromePhp.php'; break;
this will throw an ugly looking warning for any installation where the CI docs have been followed regarding moving the system and application folders out of the webroot, and renaming them. I’d suggest making a note in the docs that if the application folder has been moved, you need to edit this line to reflect the true path to the application folder.
Wanted to let you know I’ve been TankAuth for quite some time, and I find your library and code far easier to work with in an environment where I’m adding user authentication to an existing application.
...and another little bug re CI docs and your installation process. If the user is going to be using database session authentication, following the CI docs for installation you are instructed to create the “ci_sessions” table in the database. If the “ci_sessions” table exists prior to running the Community Auth init controller, it’ll fail on line 176:
// If there are already tables created, or if the tables were just created if( count( $this->tables ) > 0 OR ( isset( $tables_status ) && $tables_status === TRUE ) ) { $view_data['tables_installed'] = TRUE;
because count( $this-tables ) > 0 will be true. Another note for docs - either don’t create the ci_session table before you install Community Auth, or change the test in line 176 to greater than one.
Note for docs: in your index.php you have hardwired the application folder name into the include statement for ChromePHP on line 104:
case 'development': case 'testing': error_reporting(-1);
// Load ChromePhp for PHP debugging in Google's Chrome browser include 'application/libraries/ChromePhp.php'; break;
this will throw an ugly looking warning for any installation where the CI docs have been followed regarding moving the system and application folders out of the webroot, and renaming them. I’d suggest making a note in the docs that if the application folder has been moved, you need to edit this line to reflect the true path to the application folder.
Wanted to let you know I’ve been TankAuth for quite some time, and I find your library and code far easier to work with in an environment where I’m adding user authentication to an existing application.
Ray, thanks for the feedback. I updated the repo. Instead of updating the docs, I chose to change how ChromePhp is loaded, moving it to the construct of MY_Controller. There I used APPPATH so no matter where the application directory resides, the class should still be loaded.
I’m glad you are pleased with Community Auth. I never liked using other people’s authentication libraries because I always felt like I needed to know exactly how they work. Having spent so much time developing Community Auth, I know this is not something everyone can do, and I’ve learned a lot. There’s still room for improvements, and I again I appreciate your feedback.
...and another little bug re CI docs and your installation process. If the user is going to be using database session authentication, following the CI docs for installation you are instructed to create the “ci_sessions” table in the database. If the “ci_sessions” table exists prior to running the Community Auth init controller, it’ll fail on line 176:
// If there are already tables created, or if the tables were just created if( count( $this->tables ) > 0 OR ( isset( $tables_status ) && $tables_status === TRUE ) ) { $view_data['tables_installed'] = TRUE;
because count( $this-tables ) > 0 will be true. Another note for docs - either don’t create the ci_session table before you install Community Auth, or change the test in line 176 to greater than one.
What do you think about the ci_session table being part of the Community Auth installation? If the developer chooses not to use it, it won’t hurt anything by being there.
Hey,
Thanks a lot guys, I forgot to respond back about the problem I had, luckily after following what Brian said, I was able to register users, send emails, and things are working perfectly as intended except for a few cases on my side.