phplist

NOTE:: Before reporting an issue, make sure you are running the latest version, currently 3.3.1


View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0017708phplist applicationMessage Send Processpublic26-05-15 15:3206-07-15 17:04
Reporterduncanc 
PrioritynormalSeverityminorReproducibilitysometimes
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version3.0.12 
Target Version3.0.XFixed in Version3.2.0 
Summary0017708: Attribute placeholder not replaced when subscriber does not have a value for the attribute.
DescriptionA problem reported in the new user forum about a user attribute placeholder not being replaced when the subscriber does not have a value for that attribute
https://discuss.phplist.org/t/personalisation-how-to-remove-name-if-contacts-names-are-blank-in-list/265 [^]

I thought in that case the placeholder was replaced by an empty string but that is not the case.

Looking at function getUserAttributeValues(), that returns only the user attributes for which the subscriber has a record in user_user_attribute, but excludes any attributes for which the subscriber does not have a record.
I'm not sure that is the right thing to do. It would be more useful to return all user attributes. If a subscriber does not have a value for any attribute then either an empty string or perhaps null could be returned.

This behaviour might be a side-effect of this earlier Mantis report https://mantis.phplist.org/view.php?id=16671 [^]
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0056164)
michiel (manager)
26-05-15 16:00


Yes, that should be fixed. In the meantime it can be avoided by using a fallback value:

eg Dear [NAME%%Friend]

(0056270)
michiel (manager)
02-07-15 20:37

https://github.com/phpList/phplist3/commit/b6ed79eb393752b4e22ac618111cb671532e56f7 [^]


Copyright © 2000 - 2017 MantisBT Team
Powered by Mantis Bugtracker