Advertisement:

Author Topic: Crashed forum - how to revert back to old theme?  (Read 1460 times)

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Crashed forum - how to revert back to old theme?
« on: January 04, 2018, 05:11:25 PM »
Dear community,

I'm desperate and I pray that someone can help me?

I have used SMF for a very long time (over a decade). I have built a very popular site that attracts millions of page views. It's on a bespoke theme based on "Exodus".

However, our server had a problem and has been upgraded to ubuntu 16.04 and php7; now the existing forum won't function and says it has a database error.

Not even repair_settings.php will run. It just gives a white screen, so I fear we have a software incompatibility problem.

I have been a diligent backup person and have twice-daily DB impressions and a complete site backup, but that is useless when I cannot unhook the DB from it's cluster of mods and its theme and revert it to a non-custom theme just to get it working again.

Can anyone help me? I'm so upset for my visitors and users.

Chris

Forum specs:

SMF 2.0.15
Ubuntu 16.04 (now) with PHP7.0, dedicated server; rest of website works fine - https://www.thenakedscientists.com/


Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #2 on: January 04, 2018, 05:25:40 PM »
Thanks; I think that the problem is also that I have a customised theme; this seems to break the database if it doesn't start up right.

So If I over-write everything with a fresh copy of 2.0.15 what theme will it try to use?

Should I also install the Exodus theme clean too?

Yours,

Chris

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #3 on: January 04, 2018, 05:31:58 PM »
You can overwrite the custom theme folder with a fresh version as well.
If needed, you should be able to get to the default theme also by using /index.php?theme=1
and then be able to access the admin control panel to change theme settings further.
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline Illori

  • Project Manager
  • SMF Legend
  • *
  • Posts: 51,421
Re: Crashed forum - how to revert back to old theme?
« Reply #4 on: January 04, 2018, 05:33:23 PM »
what is the error you are getting? usually a theme cannot cause a database error.

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #5 on: January 04, 2018, 05:42:24 PM »
Actually, I took a look and was unable to even open the forum address to see any error. My browser told me the address is stuck in an endless redirect loop. Perhaps make sure first that there isn't anything wrong on the server side that could be related to this?
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline Sir Osis of Liver

  • SMF Hero
  • ******
  • Posts: 9,353
Re: Crashed forum - how to revert back to old theme?
« Reply #6 on: January 04, 2018, 05:43:42 PM »
You can reset theme to default Curve in database by setting theme_default to '1' in _settings table, but I agree with Illori, this isn't theme problem.  I'm getting browser error 'This page can’t be displayed', that's a server glitch.

Offline Shambles

  • SMF Hero
  • ******
  • Posts: 5,187
  • Gender: Male
    • i30 Owners Club
Re: Crashed forum - how to revert back to old theme?
« Reply #7 on: January 04, 2018, 05:59:17 PM »
Quote
our server had a problem and has been upgraded to ... php7

See if you (or they) can put you back to php 5.6

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #8 on: January 04, 2018, 07:19:04 PM »
Thank you very much everyone for taking the trouble to reply.

The loop problem is something a bit different - that happened after the forum failed to resurrect because I was endeavouring to put a mitigating message in place.

It's bizarre, but I've had DB problems with it before; we customised the Exodus theme; whenever we move the forum URL it errors to a white screen with "database error"; I could only move themes about by reverting it to classic, then making the changes, then reinstalling the new theme.

I'll have a go with the advice offered here next (after I fix the redirect problem) and see if I can at least get it back to classic theme by editing the DB.

Chris

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #9 on: January 04, 2018, 07:40:54 PM »
I've fixed the loop and put the files back in there.

If you take a look at https://www.thenakedscientists.com/forum - you'll see a reported database error, and the theme doing weird stuff and duplicating bits of the page.

Thoughts?

Chris

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #10 on: January 05, 2018, 01:18:53 AM »
That does seem odd, to say the least.
You did mention you had problems running repair_settings earlier, does it work now and are all the settings correct?

A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #11 on: January 05, 2018, 02:20:02 AM »
Just a white screen when you call it

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #12 on: January 05, 2018, 02:23:56 AM »
Does the white screen leave anything in your server error log?
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #13 on: January 05, 2018, 02:36:32 AM »
In the logs are two entries -  "PHP Fatal error:  Uncaught Error: Call to undefined function set_magic_quotes_runtime() " at both the times I've tried to run it.

Thanks for your advice.


Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #14 on: January 05, 2018, 02:50:17 AM »
Okay, now we're getting somewhere. This function was DEPRECATED in PHP 5.3.0, and REMOVED as of PHP 7.0.0.

As far as I know, that shouldn't be a problem in the current repair_settings.php though. Are you using an old copy of the tool, or did you download a fresh one from the downloads site? https://download.simplemachines.org/index.php?tools
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #15 on: January 05, 2018, 03:18:53 AM »
Thanks - I'd not realised that was an old copy of the tool

With a new copy, that now run; I stripped the hooks but now the error is:  PHP Fatal error:  Uncaught Error: Call to undefined function Activity_Bar_css()

I think I need to go with the suggestion to replace all the site files from scratch and then reimplement the theme and mods...?

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #16 on: January 05, 2018, 03:21:41 AM »
Or if you can, revert to PHP 5.6? I'm guessing your troubles are because of mods that are incompatible with your current PHP version.
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #17 on: January 05, 2018, 03:27:48 AM »
I'll try a clean install first, which will confirm database integrity. If that is a problem then I'll go down the 5.6 route. I've got it installed on the server, but it would mean more disruption and downtime for the rest of the site while I revert to use 5.6

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #18 on: January 05, 2018, 03:28:07 AM »
OK, good luck :)
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #19 on: January 05, 2018, 04:04:59 AM »
Thank you for your patient help. It is so nice to have a sympathetic ear!

I have over-written all of the Themes and Sources and then used the access that granted me to revert all users back to the classic theme, using the current db impression. That's now working again, so users and search engines can at least see the content and log in, albeit on a theme that we've not used for a long time! When my blood pressure reverts to normal, I'll take on resetting the mods and the previous theme...

Incidentally, I was using Exodus because it's a nice, clean responsive layout, but it does have some foibles, especially with moving the forum around - like the problem I have just had.

Do you know of any alternative responsive themes that are SMF approved?

Thanks again

Chris

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #20 on: January 05, 2018, 04:07:58 AM »
Nice to hear you got it working at least. :)

I haven't played around with themes a lot, but you could take a look at this Responsive Curve for Curve
or search around the theme site for a suitable theme :)

P.S.
Nice stats on the forum ;) Mine gets about 25% of the page views yours is getting. I can understand the stress. :)
« Last Edit: January 05, 2018, 04:52:20 AM by Aleksi "Lex" Kilpinen »
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline Illori

  • Project Manager
  • SMF Legend
  • *
  • Posts: 51,421
Re: Crashed forum - how to revert back to old theme?
« Reply #21 on: January 05, 2018, 05:16:07 AM »
since you loaded fresh files did you also remove all the hooks before you started to install mods again? if not you need to do so. https://wiki.simplemachines.org/smf/Manually_setting_a_package_installed_or_uninstalled

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #22 on: January 05, 2018, 06:09:35 PM »
Thank you both; I haven't stripped the hooks yet because the present install is an interim measure; I ran out of steam once I at least restored access. That's tomorrow's job!

What I really need to do is work out how I can overlay the original files and theme to restore it to health without causing that bizarre database error; there is something about the Exodus theme in the modified format I am using that does that and I have no idea why or how. The database is clearly happy and healthy, so it must be some strange hook in the theme that does it.

Any idea where I might start looking?

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #23 on: January 06, 2018, 03:03:54 AM »
That would be this theme right?
http://demo.smftricks.com/index.php?theme=68

In itself I don't think the theme has anything that would obviously explain it - you might want to try getting a fresh copy of the theme
https://custom.simplemachines.org/themes/index.php?lemma=2836
Install it, and test it to see if it works as is ( just don't change everyone to use it yet ) - If everything is fine and dandy,
then I'd still be inclined to say it was something in the modifications, not the theme itself.

If however it doesn't work nicely, then take a look at your server error log to see if there is anything that might explain it.
« Last Edit: January 06, 2018, 03:26:42 AM by Aleksi "Lex" Kilpinen »
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #24 on: January 06, 2018, 05:56:50 AM »
That's the theme, but I customised index.template.php to replace the top half of the screen with our own logo and drop-down. There must be something in those changes that cause the bug; I'll spend time today sniffing it out...

Thanks.

Offline Aleksi "Lex" Kilpinen

  • A Peculiar Finn
  • Lead Support Specialist
  • SMF Super Hero
  • *
  • Posts: 18,693
  • Gender: Male
  • Don't worry, I'm n00b friendly
    • Aleksi.Kilpinen on Facebook
    • LexArma on GitHub
    • aleksi-kilpinen on LinkedIn
    • There's No Place Like 127.0.0.1
Re: Crashed forum - how to revert back to old theme?
« Reply #25 on: January 08, 2018, 05:21:29 AM »
Just thought I'd let you know - While that theme has a lot of small things that ( in my opinion ) need tweaking before going live on a production site, it does work just fine on 2.0.15.

I have recently installed it on my own production forum ( thanks for the tip ) due to it's great mobile compatibility,
and am now in the process of customizing it to my liking - and have not run in to any notable issues ( apart from the recent posts block on the index not working correctly. ) No errors, no breaking. :)
A Finnish Support Specialist
 Happily running multiple SMF 2.0 installations.
  Fooling around with an i7 990X @ 3,47Ghz / 12Gb / Win 10 x64 / 3840x2160


How you can help SMF

"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum.
 Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

Offline thenakedscientists

  • Semi-Newbie
  • *
  • Posts: 25
Re: Crashed forum - how to revert back to old theme?
« Reply #26 on: January 15, 2018, 06:53:46 AM »
Thanks for this update; I've tweaked things quite extensively, as you'll see if you take a look at the now-working "properly" site.