I am having problems with users who are unable to log in to the company, this includes all users, even me. I am not sure how to explain this, but I will try.
First of all (to understand): When a pilot logs in with all the correct credentials, he is redirected to the dashboard, which is normal. But when a pilot tries to log in but the credentials are really wrong, an alert appears above the form, like this: https://prnt.sc/qm1bys
What is happening: Yes, if the pilot misses the credentials, the site does what it should do, show the alert saying it’s wrong, so far so good. But if the pilot tries to enter the correct credentials, by pushing the login button, the site sees that the credentials are correct but he does not log in, he redirects to Darshbaord but he show warning that says: “You must be logged in to access this feature!” That is , when logging in, it redirects to Dashboard, but already redirects logged out, thus showing the warning that it must be logged.
This started to happen a short time ago, but I didn’t update any files before it started this error.
In the root folder of phpVMS should be a file named error_log. Also, at least in my PHP 7.2 with my host, I needed to create a “.user.ini” file which includes a directive to enable logging of errors (this file supposedly overrides the php.ini file on a folder by folder basis).
.user.ini - file contents for error logging
error\_reporting = 32759 display\_errors = On display\_startup\_errors = Off log\_errors = On log\_errors\_max\_len = 0 error\_log = /\<path to phpvms install\>/error\_log
<path to phpvms install> can include “home/public_html/<rest of path>/error_log”
I also have the same thing set up in my /admin folder to show admin errors.
I suggest changing back to the default user and admin skins and test the log in again. If its working in the default skins, there is probably something messed up in your custom skins.
In the root folder of phpVMS should be a file named error_log. Also, at least in my PHP 7.2 with my host, I needed to create a “.user.ini” file which includes a directive to enable logging of errors (this file supposedly overrides the php.ini file on a folder by folder basis).
.user.ini - file contents for error logging
error_reporting = 32759 display_errors = On display_startup_errors = Off log_errors = On log_errors_max_len = 0 error_log = /<path to phpvms install>/error_log
<path to phpvms install> can include “home/public_html/<rest of path>/error_log”
I also have the same thing set up in my /admin folder to show admin errors.
I suggest changing back to the default user and admin skins and test the log in again. If its working in the default skins, there is probably something messed up in your custom skins.
Thanks for the answers. I updated the file “.user.ini” but nothing appeared in “error_log”, I also made the change “local.config.php” and nothing appeared in core / logs. But I just realized that the hosting creates an error file, and in it the last error it had was on 05, so I believe it has no error.
But I did what ProAvia suggested, I changed the skin to default and apparently, the error is really in the skin, I think I’ll have to redo it.
But I have a question: my skin uses a jQuery which is the newer version and phpVMS uses another jQuery which is an older version. So as there are two jQuery on the site, it appears this error:
Quote
Uncaught TypeError: $(…).ajaxForm is not a function
My very basic understanding is that using different jquery versions can cause all sorts of issues. And converting phpVMS to use a newer jquery version is going to require a lot of code changes. Since you said your skins are custom, any chance you can get them working with the same jquery versions presently used by phpVMS?
Maybe reach out to other skin developers (see the forum here on site) and see what they suggest.
Once you get these skins working correctly, any chance you will release them as freeware for others to use?
My very basic understanding is that using different jquery versions can cause all sorts of issues. And converting phpVMS to use a newer jquery version is going to require a lot of code changes. Since you said your skins are custom, any chance you can get them working with the same jquery versions presently used by phpVMS?
Maybe reach out to other skin developers (see the forum here on site) and see what they suggest.
Once you get these skins working correctly, any chance you will release them as freeware for others to use?
So, I just found the error, and it was literally a mistake made. Had placed a cookie in the header to not accept unsafe sites, I removed it and returned to work normally.