Quote:
Originally Posted by AN-net
yeah since i was sort of pushed to get this out i didn't go extremely heavy on privacy but in version 2 i do expect to do that
|
AFAIK I fixed all the privacy issues in the version we run (things such as comments on private entries also being private). I haven't recorded every change I made but you're welcome to a copy of my journals.php and notes if it helps you.
The one in question above is fixed by finding the following in the "insertentry" code;
PHP Code:
$preupdate= $DB_site->query_first("SELECT entry_id FROM ".TABLE_PREFIX."journal_entries
WHERE journal_id='".$j."' AND entrytitle='".addslashes($title)."'
AND entrytext='".addslashes($message)."'
");
$DB_site->query("UPDATE ".TABLE_PREFIX."journals SET lastentry='".addslashes($title)."', lastentry_date='".TIMENOW."',
lastentry_id='".$preupdate['entry_id']."'".($setting['autoapprove_entries']==1 ? ',entrycount=entrycount+1' : '')." WHERE journal_id='".$j."'
");
$url="journal.php?do=showjournal&j=".$_POST['j']."";
eval(print_standard_redirect('redirect_journalentryinserted'));
and replacing it with;
PHP Code:
$preupdate= $DB_site->query_first("SELECT entry_id FROM ".TABLE_PREFIX."journal_entries
WHERE journal_id='".$j."' AND entrytitle='".addslashes($title)."'
AND entrytext='".addslashes($message)."'
");
if ($private == 0)
{
$DB_site->query("UPDATE ".TABLE_PREFIX."journals SET lastentry='".addslashes($title)."', lastentry_date='".TIMENOW."',
lastentry_id='".$preupdate['entry_id']."'".($setting['autoapprove_entries']==1 ? ',entrycount=entrycount+1' : '')." WHERE journal_id='".$j."'
");
}
$url="journal.php?do=showjournal&j=".$_POST['j']."";
eval(print_standard_redirect('redirect_journalentryinserted'));