Installed Stop Forum Spam...broke forum.

Started by Rhindeer, October 08, 2024, 02:25:37 AM

Previous topic - Next topic

Rhindeer

http://remnants.spiritsoftheearth.net/smf

So...I upgraded the forum from 2.0.19 to 2.1.4.

I tried to install the Stop Forum Spam mod (https://custom.simplemachines.org/index.php?mod=4311) and uh...everything broke.

If you click the link, it shows only the error:
QuoteParse error: syntax error, unexpected '|', expecting variable (T_VARIABLE) in /hermes/walnacweb05/walnacweb05ah/b2572/pow.rhiannonmchugh/htdocs/rote/smf/Sources/StopForumSpam.php on line 1023

I'm not sure what to do to fix it. D8 The forum is identical to my other forum, which I upgraded as well and installed this mod with no issues. So, haha, help? <3 I'm not sure what went wrong as the upgrade went smoothly and the mod installation showed no conflicts.

Illori

confirm which version of PHP is running on this forum. also you should be posting issues with mods in the mods support topic.

Arantor

Betting the issue is that you're not on PHP 8 which this mod explicitly requires.
Holder of controversial views, all of which my own.


Rhindeer

Crap. You're absolutely right. We're using PHP 7.4, and I didn't realize the mod had been updated to 8 when I installed it. I guess I'm using an older version for my other forum that I upgraded late last year. x__x

I'll have to contact my host to see if they'll upgrade to 8, but in the meantime, how can I revert this?

Also sorry about posting in the wrong spot. Dx If we need to move this I'm cool with that, my bad!


Rhindeer

Excellent! My last question is, my latest backup in Packages of this mod is from 2019, and I just upgraded my forum from 2.0.19 to 2.1.4. If I do the backup, will it effect the upgrade negatively?

Kindred

yowch.... ALWAYS take a backup before applying any mod or theme - at the very least!

Better is to take a nightly and/or weekly backup
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Rhindeer

I normally do, and the one time I don't is of course the time it all fails.🙃 because I didn't read that the mod had been updated, fml.

Best course of action? >_o

Kindred

follow the instructions in the FAQ...

If all else fails, you may have to manually revert the mod changes
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Rhindeer

I DO have file backups via my host, but unsure if this mod makes database changes. If it doesn't, I can just revert the changes via those backups.

Rhindeer

Yeah, following the suggestion in the link isn't going to work, since I upgraded to 2.1.4 and the files affected are files that are core, like index.php and such. Is my best bet to try the site backup and hope it works well enough to be able to access the forum and uninstall? The site backup will not affect the database, just the files. Welp. xD Lesson learned for sure. I am big dumb.

Edit: It did not work, if course, because of database changes. So I undid that, and am back where I started. How would I manually fix this? Because I think this is my last option. x__x

Doug Heffernan

Quote from: Rhindeer on October 08, 2024, 03:59:34 PMEdit: It did not work, if course, because of database changes. So I undid that, and am back where I started. How would I manually fix this? Because I think this is my last option. x__x

Overwrite your forum files with a fresh set from the 2.1.4. large upgrade package, minus the upgrade files. Then you can run the repair_settings.php tool to remove all hooks added by mods. That will ensure that all mods will be uninstalled automatically.

For future reference:

Quote from: Illori on October 08, 2024, 04:43:36 AMalso you should be posting issues with mods in the mods support topic.


Rhindeer

Quote from: Doug Heffernan on October 08, 2024, 04:31:59 PM
Quote from: Rhindeer on October 08, 2024, 03:59:34 PMEdit: It did not work, if course, because of database changes. So I undid that, and am back where I started. How would I manually fix this? Because I think this is my last option. x__x

Overwrite your forum files with a fresh set from the 2.1.4. large upgrade package, minus the upgrade files. Then you can run the repair_settings.php tool to remove all hooks added by mods. That will ensure that all mods will be uninstalled automatically.

For future reference:

Quote from: Illori on October 08, 2024, 04:43:36 AMalso you should be posting issues with mods in the mods support topic.


Thank you so much, will do that! <3

And lesson learned on all fronts! Sorry about posting in the wrong place! x__x Thank you so much for your help! (And Kindred and Arantor as well! <3)

Also, when I upload the fresh files, should I also NOT replace the settings.php file?

Doug Heffernan

Quote from: Rhindeer on October 08, 2024, 04:36:14 PMThank you so much for your help!

You are very welcome :)

Quote from: Rhindeer on October 08, 2024, 04:36:14 PMSorry about posting in the wrong place

Don't worry about it :)

Quote from: Rhindeer on October 08, 2024, 04:36:14 PMAlso, when I upload the fresh files, should I also NOT replace the settings.php file?

No, you must not replace/overwrite that file, because the file in question  holds all the database info, that the forum needs to connect to the database. If you overwrite it, the forum will stop working and you will have to re-create it in order for your forum to work again.



Rhindeer

Quote from: Doug Heffernan on October 08, 2024, 04:39:43 PMNo, you must not replace/overwrite that file, because the file in question  holds all the database info, that the forum needs to connect to the database. If you overwrite it, the forum will stop working and you will have to re-create it in order for your forum to work again.
Okay, awesome! <3 So replace everything EXCEPT for settings.php and don't include the upgrade files, then run repair_settings.php. Excellent! Thank you!!


Rhindeer

#16
So that fixed it! Thank you! (AND THANK YOU ILLORI! I forgot to mention you in my thank you post! Ahhh!)

https://remnants.spiritsoftheearth.net/smf/index.php

It just now looks, ah. Broken. I followed the instructions, kept settings.php untouched, installed everything but the upgrade files, and ran repair_settings.php to remove hooks as well as cleared logs, caches, and ran repair tools on the forum.

For reference, here's the sister forum: http://www.spiritsoftheearth.net/smf Sister forum has always been effortless even though I mirrored the mods and everything, haha. For some reason this one just has to be a butt. I'm not sure where it broke. >_o

It's been kind of bouncing back and forth between looking like a freshly installed forum, and looking like the image I provided. It keeps going back and forth between versions in mobile and desktop, for myself and other users. Myself and other users have cleared browser cashes and that doesn't seem to effecting the flip-flopping it's doing.

Doug Heffernan

Quote from: Rhindeer on October 08, 2024, 05:11:01 PMIt just now looks, ah. Broken

The forum loads fine to me. I don't get the broken layout. Can you load the repair_settings.php tool again and check if all the paths and urls are pointing to the right locations?

Rhindeer

That's the problem I'm afraid. ): Myself and the users I have testing it get the good version AND the broken version just minutes apart. Like I'm currently on desktop and I refreshed 10 minutes ago and it was the unbroken version, but now it's back to being broken again on the same device. My users are experiencing the same thing, which is why it's so perplexing. It keeps going back and forth between the versions.

Did repair_settings.php again and everything is what it should be. :\

Sir Osis of Liver

https://remnants.spiritsoftheearth.net/smf/index.php is not loading css, paths are still incorrect.  Run repair_settings again, make sure you save settings.

And disable forum cache and clear your browser.

When in Emor, do as the Snamors.
                              - D. Lister

Advertisement: