Advertisement:

Author Topic: SMF 2.0.x and PHP 7.1 mark board as read [] operator not supported for strings  (Read 2033 times)

Offline vbgamer45

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 19,350
    • smfhacks on Facebook
    • VBGAMER45 on GitHub
    • @createaforum on Twitter
    • SMF For Free
Marking a board as read results in "operator not supported for strings" on SMF 2.0.x using PHP 7.1

https://www.simplemachines.org/community/index.php?topic=554409.0

Affected code and bug fix:
Sources\Subs-Boards.php         
Code: [Select]
$logBoardInserts = '';
while ($row = $smcFunc['db_fetch_assoc']($result))
$logBoardInserts[] = array($modSettings['maxMsgID'], $user_info['id'], $row['id_board']);


Find change to
Code: [Select]
$logBoardInserts = array();
while ($row = $smcFunc['db_fetch_assoc']($result))
$logBoardInserts[] = array($modSettings['maxMsgID'], $user_info['id'], $row['id_board']);

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 Colin

  • Lead Developer
  • SMF Hero
  • *
  • Posts: 7,767
  • Gender: Male
  • SMF Developer
    • colinschoen on GitHub
Thank you!
"If everybody is thinking alike, then somebody is not thinking." - Gen. George S. Patton Jr.

Colin

Offline Colin

  • Lead Developer
  • SMF Hero
  • *
  • Posts: 7,767
  • Gender: Male
  • SMF Developer
    • colinschoen on GitHub
"If everybody is thinking alike, then somebody is not thinking." - Gen. George S. Patton Jr.

Colin