Closed elgg-gitbot closed 11 years ago
cash wrote on 39882500-12-25
I hate this bug. It just annoys me.
Attached is a patch. It assures that array order is preserved for metadata when using get_metadata_byname() [which is what ElggEntity->get uses].
Attachment added by cash on 39882501-10-11: metadata_array_order.diff
brettp wrote on 40029981-09-26
(In [svn:3793]) Fixes #538. Applied Cash's patch. This is an old one...jeepers.
Original ticket http://trac.elgg.org/ticket/538 on 38862411-02-12 by trac user kevinjardine, assigned to unknown.
Elgg version: Github Master
If I enter three tags, eg. "Toronto, Leiden, Winnipeg" in a profile form, the display order is reversed when I view my profile.
This is not an alphabetical sort, but just a reversal, presumably because as usual Elgg displays the most recently created metadata item first.
Suggestion - use array_reverse to reverse the results of string_to_tag_array in metadata.php before that function returns its tag array.