Simple Machines Community Forum

SMF Support => SMF 2.1.x Support => Topic started by: orelanic on June 12, 2019, 10:33:00 AM

Title: new install no admin page
Post by: orelanic on June 12, 2019, 10:33:00 AM
Hi
Not sure if this is a bug, I tried to install smf 2.1, all seemed to go well, forum was up and running and I could login with no issues, and even post to the forum, but I cannot enter into the Admin panel.


I can enter into the main forum, and all the sub pages that drop down form the Admin button such as, features and options, package manager, error logs, and permissions, except if I click on the main Admin button I get an error message.


Warning: require_once(/home/@@@@@/public_html/talkinglifelines.com/forum/Sources/Subs.php): failed to open stream: Permission denied in /home/@@@@@/public_html/talkinglifelines.com/forum/index.php on line 49

Fatal error: require_once(): Failed opening required '/home/@@@@@@/public_html/talkinglifelines.com/forum/Sources/Subs.php' (include_path='.:/usr/local/php71/pear') in /home/@@@@@@/public_html/talkinglifelines.com/forum/index.php on line 49

When I made the test post I seen this error in the log


Type of error: Critical
  The selected search API the forum is using is out of date - falling back to standard search. Please check file SearchAPI-Standard.php.  https://talkinglifelines.com/forum/index.php?action=post2;start=0;board=1 (https://talkinglifelines.com/forum/index.php?action=post2;start=0;board=1)

Any ideas whats best to do here, reinstall it? Its only a test forum so not urgent

Title: Re: new install no admin page
Post by: Illori on June 12, 2019, 10:40:19 AM
does the Subs.php file exist? if not ask your host what happened to it.

also take a look at

Search API error in 2.1 RC2 (https://www.simplemachines.org/community/index.php?topic=566687.0)
Title: Re: new install no admin page
Post by: orelanic on June 12, 2019, 12:20:57 PM
Thank you for the information it was very helpful, I did manage to alter the code in the php file and solve the main issue, but I have a new one.


When I make a post in the forum I get this error:


Parse error:  syntax error, unexpected 'SMF' (T_STRING), expecting ',' or ';' in /home/@@@@@/public_html/talkinglifelines.com/forum/Sources/Class-SearchAPI.php on line 153

When I check, the post has been successfully posted even with the error showing, if I go back and refresh the page I can see the post.


Is this one of those fix this then that brakes errors   ;D



Title: Re: new install no admin page
Post by: Shambles on June 12, 2019, 05:14:40 PM
Attach your current version of Class-SearchAPI.php to your next post, or show us (using code blocks) the 10 lines surrounding (before & after) line 153 of that file.
Title: Re: new install no admin page
Post by: orelanic on June 13, 2019, 06:45:36 AM

Thanks for taking the time
Sorry I am a bit late, work and all that stuff

I attached the file as a doc for your consideration.



Title: Re: new install no admin page
Post by: Gary on June 13, 2019, 08:41:09 AM
Your error is actually on line 148.

Find:

public $version_compatible = 'SMF 2.1 RC2;


Replace with

public $version_compatible = 'SMF 2.1 RC2';




Next time though, please just attach the file itself rather than a copy-paste into MS Word, it adds unnecessary steps to diagnose the problem. (copying back into a text editor and turning colour syntaxing on)
Title: Re: new install no admin page
Post by: orelanic on June 13, 2019, 09:13:57 AM
Thank you for your help, it all seems to work with no issues now it has been changed, and I have to say I am impressed with the new look.  8)

Thanks again