Opened 16 years ago

Closed 16 years ago

#150 closed defect (fixed)

settings.php does not allow updating of 'spamtrap' or 'reminder' setting

Reported by: shalligan@… Owned by: rjl
Priority: normal Milestone: 1.0.0 RC6
Component: PHP scripts Version: 1.0.0 RC6
Severity: normal Keywords:
Cc:

Description

The update queries in both of these is wrapped in an if statement. For example, the spamtrap section: if (isset($HTTP_POST_VARSspamtrap?)) {

$spamtrap = (trim($HTTP_POST_VARSspamtrap?) == "yes" ? "Y" : "N"); if ($enable_spamtraps) {

$update = "UPDATE maia_users SET spamtrap = ? WHERE id = ?"; $dbh->query($update, array($spamtrap, $euid));

}

}

The 'if ($enable_spamtraps)' test fails always, so we never get the update. Ditto for the reminder setting and probably the charts setting.

I am not sure how varibles work between the php and the smarty template, but the variable works in the tpl (if it didn't the tr for the spamtrap setting wouldn't show up). It appears that varible isn't getting set in php.

Suggestion: There is no need for the if statement. All templates don't show this setting if enable_spamtraps in maia_config is 'N'.

Change History (1)

comment:1 Changed 16 years ago by dmorton

  • Resolution set to fixed
  • Status changed from new to closed

see [570]

Note: See TracTickets for help on using tickets.