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
0006063phplist applicationMessage Send Processpublic11-04-06 17:5118-02-08 14:06
Reportermarksu 
PrioritynormalSeveritymajorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version2.10.2 
Target Version2.10.7Fixed in Version2.10.4 
Summary0006063: Using multiple Criteria attributes at "ADVANCED CRITERIA MODE" gives false user filtering
Description# Bug when using checkbox group, and other form objects with multi selection on Criteria section when creating a message
# This fixes bug if you are using "Advanced Criteria" note not the normal Criteria setting
# The Default Criteria mode is propably faulty also
# To check if Advanced mode is set chekc config.php for line define("STACKED_ATTRIBUTE_SELECTION",1)

Below you can see the criteria sql string example, on a multi selection checkboxes.
Problem is that only the first selection element in this case 13 is valid rest has extra space in them.

This is ORIGINAL bad version
select userid from phplist_user_user_attribute as table2 where attributeid = 14 and find_in_set('13',table2.value) > 0 or find_in_set(' 14',table2.value) > 0 or find_in_set(' 16',table2.value) > 0 or find_in_set(' 17',table2.value) > 0 or find_in_set(' 20',table2.value) > 0 or find_in_set(' 22',table2.value) > 0

This is correct version after my bug fix
select userid from phplist_user_user_attribute as table2 where attributeid = 14 and find_in_set('13',table2.value) > 0 or find_in_set('14',table2.value) > 0 or find_in_set('16',table2.value) > 0 or find_in_set('17',table2.value) > 0 or find_in_set('20',table2.value) > 0 or find_in_set('22',table2.value) > 0

I presume the reason is that the phplist is retreaving the form objects multi selection in form "x, x, x, x" therefore the first number is only without extra space.
####### BUG FIX #####################
Add line: $crit_data["values"] = str_replace(" ", "",$crit_data["values"]);

above line (at line 658): # hmm, rather get is some other way, this is a bit unnecessary text

#####################################


Note this does not fix the default Criteria mode, but only "stacked attribute selection" Criteria mode. I presume default Criteria mode has the same bug. I have not tested that one as it is a separate code.

I spend countless days on this and it's time for me the start using the phplist instead of bug fixing it.

I have not yet been able to test it in real llife only test mode.

More info at: http://www.phplist.com/forums/viewtopic.php?t=4370&postdays=0&postorder=asc&start=0 [^]
Additional InformationThis is not same bug as the one where the criteria attributes where not saved.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
related to 0003721closed phplist 2.10.x 
related to 0007060resolvedmichiel Criteria does not refresh the correct amount 

-  Notes
(0012495)
michiel (manager)
11-04-06 18:24

that's a great find. !
(0021424)
marksu (reporter)
27-11-06 13:18

Well dont know why this date has changed. This is a bug change I sent beginning of year 2006 and not november.

According to this it has not yet been fixed to the 2.10.3 version.
(0021425)
marksu (reporter)
27-11-06 13:20

Well I mixed the days and months.
Well anyway, it's still not yet solved on 2.10.3.
(0021428)
michiel (manager)
27-11-06 15:07

the dates are american so you submitted it on the 11th of April. Sorry, unless loads of people start to help out coding, I simply don't have the time to fix everything immediately. As this feature is "advanced functionality" that is not enabled by default, it's not just yet a priority. Unfortunately the list of issues is increasing, but my time to sort them out isn't.
(0021439)
marksu (reporter)
27-11-06 17:22

Yes I understand.
I did not ment it to sound compaint.
Even though I am eger to get it fixed.

Have a nice day michiel.

Best Regards
Marksu


Copyright © 2000 - 2017 MantisBT Team
Powered by Mantis Bugtracker