#1463 open
Peter

Theme screwed, unable to login

Reported by Peter | March 22nd, 2022 @ 05:10 PM | in User issues

I am creating a test site at www.britishtrolley.org.uk/2-4-3 - this is a separate folder within the live site structure - to create a new theme. It is at version 2-4-3 for now, my intention

With the theme almost complete, I had a small issue with the top menu pull-downs. Having seen on a different theme that this problem did not occur, I went into the theme management page to view the site with the other available themes as a starter for where to look to update that. A couple of the alternative themes worked fine in terms of I could see the problem didn't exist. I clicked on the copy of the live site theme to see what that looked like and the browser window went blank. Page source was empty.

The new theme is based on bootstrap5theme. The live site theme is btstheme. After lots of messing about, I deleted the btstheme files from the server. The web site now displayed, but using a default theme. I tried to log in but each attempt went back to the home page h a message that I'm logged out. I did a repair on the database but that didn't help.

I then tried re-uploading btstheme, and again the screen went blank. So it looks like it's trying to use btstheme which seems to be incompatible with my customised theme, which as far as I know is still the default. I checked conf.php, it was set to btstheme so I changed it back to bootstrap5theme. That made no difference.

Somehow it is confused on which theme to use? At the same time I can't log in from the default theme. Any ideas please? Anything I can check myself? If you need to look I'd need to set up a username, but as I can't log in that's an issue. I may still have details of the last login I gave you which should still work, but I'll need to dig around to find it.

Thanks.
Peter.

Comments and changes to this ticket

  • Peter

    Peter March 22nd, 2022 @ 05:10 PM

    • Assigned user changed from “expNinja” to “dleffler”
  • dleffler

    dleffler March 22nd, 2022 @ 07:29 PM

    • State changed from “new” to “open”
    • Tag set to bug

    Several issues could be at work against each other:
    - what version of exponent are you running? 2.4.3 or 2.6.0? and if so what patch? or the development code? - What bootstrap 5 package are you using? beta1, beta2, rc1? As stated in those docs, each release must be aligned with the specific version/patch which they were created for. Likewise v2.6.0 or later is required to have the underpinnings to support the sample bootstrap5theme - What version is your MySQL server? v5.x, v8.x?

    When you have a blank page, the code crashed prior to output. In this case it appears to be the coding in the custom theme's class.php or index.php files.

    When all else fails, you may have to manually edit the /framework/conf/config.php file.
    - You can change the theme to a built-in one to get the site back up. define("DISPLAY_THEME_REAL",'bootstrap3theme'); If you enter a non-existent theme, it'll use the fallback theme. - It is best to leave error-reporting turned on to display errors and warnings, define("DEVELOPMENT",'1');

  • Peter

    Peter March 23rd, 2022 @ 01:05 PM

    Thanks for the fast response. I was planning to get back to this today, but so far more urgent things keep getting in the way. I'll need to see if I can work out the answers to your questions definitively. From memory it was 2.4.3 with all patches and theme 5 at the latest level. The site was working fine over the last few weeks until I asked to view it with the old btstheme, when it screwed up.

    Briefly today I changed config.php to bootstrap3theme just to see what happened. It still loads with the default theme and a note at the bottom saying my default theme is btstheme, even though it never was the default. The btstheme folder doesn't exist because with it I get the blank screen problem. Something other than config.php is telling Exponent that my default theme is not what the default theme should be.

    Later today I'll upload btstheme folder contents a file at a time to see at what point the system dies. I'll let you know.

    Peter.

    PS - Just uploaded the theme files, btstheme index.php throws the error:

    Fatal error: Uncaught Exception: Serialization of 'ReflectionClass' is not allowed in [no active file]:0 Stack trace: #0 {main} thrown in [no active file] on line 0

  • dleffler

    dleffler March 23rd, 2022 @ 02:11 PM

    I suspect several issues are caused by a PHP version upgrade on your server. v2.4.3 was only compatible up to PHP v7.2. Support for PHP v7.3 was added in Exponent v2.5.0, PHP v7.4 in Exponent v2.5.1 patches (Reflection changed), and PHP v8.0 in v2.6.0 patches...still working on some PHP v8.1 issues.

    The bootstrap 5 theme ONLY works with Exponent v2.6.1 and the matching patches. I'm not sure what might happen if you drop it into an earlier version (basically it would be ignored?)

    What PHP version is your server now running?

    bootstrap3theme ships with most Exponent versions and should exist in the /themes folder. No other 'config' files are loaded, but you might look at the Overrides.php file in the root folder if it exists. That is a fallback for 'overriding' variables when Exponent loads.

  • Peter

    Peter March 23rd, 2022 @ 03:11 PM

    Looks like PHP 7.4. I seem to have a bit of a bugger's muddle and maybe I should upgrade the test site to 2.6 before doing anything else. That would make changeover easier as well. Only concern with that is I've always been logged in when I've done upgrades, but I can't login. Any advice please?

    You mention 2.6.1 but searching for updates I find a reference to patch 3 but it seems to be unavailable - see attached?

    Peter.

  • dleffler

    dleffler March 23rd, 2022 @ 03:38 PM

    I'll assume your server likely upgraded MySQL versions also? PHP v5.7 added 'strict' mode as a default, unless you customize the my.ini file. Additionally, MySQL v8 added a new 'rank' keyword which causes issues in most modules.

    • Exponent v2.6.0 added support for MySQL v5.7 strict mode - this will sometimes prevent logons and adding new items/modules, etc...
    • Exponent v2.6.0patch3 fixed the MySQL v8 'rank' issue
    • Exponent v2.6.0patch3 matches bootstrap5 package rc2
  • dleffler

    dleffler March 23rd, 2022 @ 04:02 PM

    Sorry, v2.6.1 is the next release (development code branch), kind of 2.6.0patch4 :)

  • Peter

    Peter March 23rd, 2022 @ 04:07 PM

    MySQL 10.3.34-MariaDB

  • dleffler

    dleffler March 23rd, 2022 @ 04:53 PM

    Maria DB v10.3.34 is MySQL v5.7 clone so it needs the 'strict' mode fixes

  • Peter

    Peter March 23rd, 2022 @ 05:04 PM

    I've just installed 2-6-0 in a new folder with bootstrap3theme. Site is working and I can log in after copying config.php across without running install.

    I've now downloaded patch3 ready to install. I think I'll stop messing with the old version and redo my css customisations on 2.6.0.

    Thank you for the help so far. We can probably close this ticket down.

    Peter.

  • Peter

    Peter April 22nd, 2022 @ 03:59 PM

    • Tag changed from bug to advice on formatting

    So after a bit of a delay I have created the site at version 2.6.0 at https://britishtrolley.org.uk/2-6-0 . Everything is going to plan, but I do have one query please.

    I would like to imbed the Search box at the bottom of the fixed position horizontal menu rather than at the top of each page, where it scrolls away. Please could you tell me how to do that? I'm uploading the main theme index page so you can see what I've done so far.

    Thank you.
    Peter.

  • Peter

    Peter April 27th, 2022 @ 12:43 PM

    No response, will open new ticket. Please close this one. Thanks.

  • dleffler

    dleffler June 30th, 2022 @ 01:06 PM

    • Milestone set to User issues

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Bug Tracker for Exponent CMS

Shared Ticket Bins

People watching this ticket

Attachments

Pages