Using og2list.module,v 1.70.2.2 2006/08/31, the mailing list form doesn't retain the value for 'Subject prefix'. Any values entered in the form don't make it to the database.

It turns out the UPDATE query in og2list_listmail_form_submit() doesn't include any value for the 'prefix' column.

I have changed it to:

  db_query("UPDATE {og2list_groups} SET status = %d, moderate = %d, prefix = '%s' WHERE nid = %d", $form_values['og2list_ml_status'], $form_values['og2list_ml_moderate'], $form_values['og2list_subject_prefix'] ,$node->nid);

But that doesn't solve the issue, because for a reason I am unaware of, the values entered in the form (and present in $_POST) don't make it into the $form_values visible to og2list_listmail_form_submit().

So I have an ugly workaround:

if ($form_values['og2list_subject_prefix'] != $_POST['edit']['og2list_subject_prefix']) {
    $form_values['og2list_subject_prefix'] = $_POST['edit']['og2list_subject_prefix'];
}

There's got to be a better solution...

Comments

Amazon’s picture

Priority: Normal » Critical

I tested this and confirmed that I am not seeing anything in the UI to indicated the prefix is being saved. Moving to critical.

Kieran

Amazon’s picture

Status: Active » Fixed

Waiting for pre-fix outbound mail to be sent.

Moving to fixed as a saving the prefix has confirmed to work in the UI.

Update to the latest code.

Anonymous’s picture

Status: Fixed » Closed (fixed)