News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

SMF 2.1 R3 Bookmarks Mod Problem

Started by gevv, October 26, 2020, 02:58:25 PM

Previous topic - Next topic

gevv

Hi,

I am using the modified version Bookmarks Mod  for smf 2.1

There was no problem in rc2 version but problem in rc3 version

topics are not added to favorites

forum error message; 

QuoteWhen using the replace mode, the key column is a required entry.

error log;


QuoteType of error: Critical
Change the method of db insert to insert or add the pk field to the key array
Function: addBookmark
Sources/Bookmarks.php (Line 175)

line 175;


array()


how do i solve the problem

thanks
ElkArte is a modern, powerful community building forum software. https://www.elkarte.net/

Arantor

Code (find) Select
$result = $smcFunc['db_insert']('replace', '{db_prefix}bookmarks',
array(
'id_member' => 'int',
'id_topic' => 'int',
),
array(
'id_member' => $id_member,
'id_topic' => $id_topic,
),
array()
);


Code (replace) Select
$result = $smcFunc['db_insert']('replace', '{db_prefix}bookmarks',
array(
'id_member' => 'int',
'id_topic' => 'int',
),
array(
'id_member' => $id_member,
'id_topic' => $id_topic,
),
array('id_member', 'id_topic')
);


The parameter has to align with the unique index on the table.
Holder of controversial views, all of which my own.


gevv

ElkArte is a modern, powerful community building forum software. https://www.elkarte.net/

Advertisement: