Page 1 of 2

Cant get to work

Posted: Mon May 31, 2021 6:40 pm
by captcurrent
I am running php7.2 on FreeBSD 12.1. I followed the instructions on the installation guide

creates a database sphider on mysql

added an user sphider and sphider-admin

changed database.php. to reflect the database and use sphider-admin

updated my.cnf to reflect Sphider-admin and its password

ran install.php (no real feed back)

then when I admn.php I het stuck on he login screen...

I am sure it is s something simple I have verified the user id and password with mysql. Any thoughts would be appreciated

Re: Cant get to work

Posted: Tue Jun 01, 2021 6:33 pm
by captquirk
Check to confirm that the user name and password in both database.php and my.cnf match EXACTLY. Case matters.
If there is still an issue, get back to me.

Re: Cant get to work

Posted: Fri Jun 04, 2021 1:21 pm
by captcurrent
there was a type which I corrected but still stuck on admin.php

Re: Cant get to work

Posted: Fri Jun 04, 2021 11:55 pm
by captquirk
In admin/auth.php, notice lines 17 and 18. Line 17 is commented out with "//", line 18 is not. Reverse this by removing the "//" on line 17 and inserting "//" at the beginning of line 18.
In admin/admin.php, do the same thing for lines 18 and 19.
This turns on error reporting. Try logging on again. Are you getting any error messages?

Re: Cant get to work

Posted: Sat Jun 05, 2021 2:32 pm
by captcurrent
I think you wanted this to be the result in both file

The developmental lines already activated in admin.php


I am getting this error in http-error log

PHP Fatal error: Directive 'safe_mode' is no longer available in PHP in Unknown on line 0

Re: Cant get to work

Posted: Sat Jun 05, 2021 3:48 pm
by captquirk
You are running PHP 7.2, but "safe_mode" has been deprecated since PHP 5.4! My understanding that the entry in the php.ini file, the setting safe_mode needs to be removed. Simply setting to "off" will not work.

I have never actually encountered this, so I am not positive this is the cause of the failure to get to the admin panel of Sphider. My suspicion is that your issue has to do with database access. To confirm this, comment out line 74 (last line) of auth.php. This should allow you to see the Sphider admin panel but there will be no functionality.... It will, however, rule out all PHP code problems and we can concentrate on database connectivity.

Re: Cant get to work

Posted: Sat Jun 05, 2021 5:39 pm
by captcurrent
The php.ini was a hold over from when I was running php 5.4. Removed the safe mode setting


last line was

require "$settings_dir/database.php";


now commented out

restarted apache

same problem as before

I checked the user sphider-admin and password with mysql and was able to logon to mysql

Stranger in a strange land

Re: Cant get to work

Posted: Sun Jun 06, 2021 1:14 am
by captquirk
With require "$settings_dir/database.php;" commented out, post a screenshot please.

Definitely strange! But we will figure it out. I'm not one to give up!

Re: Cant get to work

Posted: Sun Jun 06, 2021 12:41 pm
by captcurrent
Not sure how screenshot will help. It shows the screen then when I enter information it cycles to other credentials in memory

Re: Cant get to work

Posted: Sun Jun 06, 2021 5:05 pm
by captquirk
I just wanted to be certain of where we are getting hung up. Thank you.
Go to your browser settings and clear the cookie for "localhost", Try logging in again.
If (when?) that fails, clear the cookie again (this is going to become a very annoying habit until we get some success), and in admin.php, after line 22 ("require "auth.php";") add a line:
echo "auth passed";
After line 27 ("require "$settings_dir/conf.php";" add a line:
echo "config passed";

Try again and let me know if either or both display. This seems like a messy way of doing things, but short of installing a debugger it does help narrow down the problem! (Cleanup afterwards can become a real *****! So we hope for a quick resolution.)