Page MenuHomePhabricator

GWToolset displays the ' character as an Ampersand '&' in the preview of the Global categories field
Closed, DeclinedPublic

Description

Reported by @MartinPoulter on the glamtools mailing list:

I chose a category which includes an apostrophe character:
Files uploaded by the Bodleian Libraries' Wikimedian In Residence
The system renders this as:
Files uploaded by the Bodleian Libraries&
This is easy to fix post-upload with cat-a-lot or a similar tool, but it would be nice to fix it in code.

Event Timeline

JeanFred raised the priority of this task from to Needs Triage.
JeanFred updated the task description. (Show Details)
JeanFred added subscribers: JeanFred, MartinPoulter.
Restricted Application added subscribers: StudiesWorld, Steinsplitter, Aklapper. · View Herald Transcript

Learned from further testing: the category itself survives the transfer to Commons Beta intact. This error only shows up in the metadata *preview* (when GWToolset parses the first three records and shows the results). Hence this is a more minor error than my first message suggested.

JeanFred renamed this task from GWToolset replaces the ' character with an Ampersand '&' in the Global categories field to GWToolset displays the ' character as an Ampersand '&' in the preview of the Global categories field.Jan 29 2016, 12:25 PM
JeanFred triaged this task as Lowest priority.
JeanFred set Security to None.

Thanks @MartinPoulter, I clarified the task title. :)

@MartinPoulter Could you attach a test XML file that triggered this behaviour?

Note that it's not the XML itself that triggers the behaviour. In the GWToolset form, after I've chosen the file, one of the form entries asks for categories that will be applied to all the uploaded files. When I enter the category "Files uploaded by the Bodleian Libraries' Wikimedian In Residence" (without quotes) the next step is the example three metadata records, and it's at this stage that I get the error.

Note that it's not the XML itself that triggers the behaviour. In the GWToolset form, after I've chosen the file, one of the form entries asks for categories that will be applied to all the uploaded files. When I enter the category "Files uploaded by the Bodleian Libraries' Wikimedian In Residence" (without quotes) the next step is the example three metadata records, and it's at this stage that I get the error.

Right, my mistake. Thanks for clarifying :)