Advertisement:

Author Topic: SMF Wiki is crashed after Update SMF to 2.0.14. Please help  (Read 2682 times)

Offline neo67

  • Semi-Newbie
  • *
  • Posts: 14
Hello folks,

after we updated SMF to 2.0.14, our Wiki (https://www.simplemachines.org/community/index.php?topic=272676.0) has an error by doing the first call: https://www.linuxmintusers.de/index.php?action=wiki [nofollow]
The error is:
Code: [Select]
Invalid value inserted or no type specified.
We are not able to uninstall the update, because we have to edit some core files, to probably run SMF after update to 2.0.14. This was no good update for us....

I will send the wiki with as a zip folder, which have the wiki-Source ( a few files) in it.
I try to search for the error, but I don't find, what reports the error:
Code: [Select]
Invalid value inserted or no type specified.
I ask for help, because we need the wiki back!!!!

Many Thanks

Regards
neo67

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 19,350
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Re: SMF Wiki is crashed after Update SMF to 2.0.14. Please help
« Reply #1 on: May 29, 2017, 09:15:43 AM »
You have to redo this changes in the mysqli part of that file
Code: [Select]

<file name="$sourcedir/Subs-Db-mysql.php">
<operation>
<search position="replace"><![CDATA[strpos($db_string, '{db_prefix}') !== false]]></search>
<add><![CDATA[strpos($db_string, '{db_prefix}') !== false || strpos($db_string, '{wiki_prefix}') !== false]]></add>
</operation>

<operation>
<search position="after"><![CDATA[
if (!isset($matches[2]))]]></search>
<add><![CDATA[
if ($matches[1] === 'wiki_prefix')
return $GLOBALS['wiki_prefix'];
]]></add>
</operation>

<operation>
<search position="before"><![CDATA[global $db_connection, $db_prefix;

$table = str_replace('{db_prefix}', $db_prefix, $table);]]></search>
<add><![CDATA[
if (isset($GLOBALS['wiki_prefix']))
$table = str_replace('{wiki_prefix}', $GLOBALS['wiki_prefix'], $table);
]]></add>
</operation>

<operation>
<search position="before"><![CDATA[ // Replace the prefix holder with the actual prefix.
$table = str_replace('{db_prefix}', $db_prefix, $table);]]></search>
<add><![CDATA[
if (isset($GLOBALS['wiki_prefix']))
$table = str_replace('{wiki_prefix}', $GLOBALS['wiki_prefix'], $table);
]]></add>
</operation>
</file>

Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline neo67

  • Semi-Newbie
  • *
  • Posts: 14
Re: SMF Wiki is crashed after Update SMF to 2.0.14. Please help
« Reply #2 on: May 29, 2017, 10:03:31 AM »
Hello vbgamer45,

in which file I must redo changes?

Subs-Db-mysql.php?

Edit:

as a example:

This line (301)in Subs_Db-mysql.php I have to change from:

Code: [Select]
if (empty($db_values['security_override']) && (!empty($db_values) || strpos($db_string, '{db_prefix}') !== false || strpos($db_string, '{wiki_prefix}') !== false))
into:

Code: [Select]
if (empty($db_values['security_override']) && (!empty($db_values) || strpos($db_string, '{db_prefix}') !== false
???


and so one...
THX


Edit:
Oh my god... I dont know, what to do with the other lines...

are you able to clean the file?
Here is the original live file.

THANKS!




« Last Edit: May 29, 2017, 10:36:25 AM by neo67 »

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 19,350
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Re: SMF Wiki is crashed after Update SMF to 2.0.14. Please help
« Reply #3 on: May 29, 2017, 05:14:06 PM »
updated file attached
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Offline neo67

  • Semi-Newbie
  • *
  • Posts: 14
Re: SMF Wiki is crashed after Update SMF to 2.0.14. Please help
« Reply #4 on: May 30, 2017, 05:33:45 AM »
@vbgamer45

Thanks a lot. It's running again!
 :)  :)  :)  :)  :)  :)  :)  :)  :)  :)  :)

greetz
neo67
 8)

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 19,350
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Re: SMF Wiki is crashed after Update SMF to 2.0.14. Please help
« Reply #5 on: May 30, 2017, 08:24:45 AM »
Glad to help.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro