[MGNLDMS-209] Invalid characters should not break the link Created: 07/Mar/11  Updated: 20/Apr/12  Resolved: 18/May/11

Status: Closed
Project: Document Management System (closed)
Component/s: None
Affects Version/s: 1.5.1
Fix Version/s: 1.5.2

Type: Bug Priority: Major
Reporter: Matt Dertinger Assignee: Jan Haderka
Resolution: Fixed Votes: 0
Labels: dms
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
dependency
relation
is related to MGNLDMS-61 % (percent) characters in a file name... Closed
is related to MGNLDMS-107 When title contains invalid character... Closed
is related to MGNLDMS-230 File is displayed regardless of its name Closed
is related to MGNLDMS-173 Documents with special characters lik... Closed
Template:
Acceptance criteria:
Empty
Date of First Response:

 Description   

Hi,

Currently, it looks like the value of an Asset's document node data uses the Asset's title node, this can cause issues, especially when the value of the title node data contains / characters.

Steps to Reproduce

  1. Login to Admin Central and navigate to Documents/demo-project/img/opener
  2. Double click in the Title column for the Asset named wooden-table-from-above to edit the title
  3. Change the value from wooden table from above 588x368 to wooden table from above w/papers
  4. Make sure wooden-table-from-above is selected, then click Edit document to open the Edit dialog
  5. Note that the thumbnail image in the dialog is no longer found
  6. Click on the Meta Data tab, for the Static Link, note that it's using the value of the title node (i.e. /dms-static/81eb4ad5-ac2d-48a4-b120-bdddb0bc9255/wooden%20table%20from%20above%20w_papers.jpg) instead of the assets name wooden-table-from-above

Please let me know if you have any other questions.

Thanks,
Matt



 Comments   
Comment by Magnolia International [ 22/Mar/11 ]

iirc, the part between the last / and the extension is ignored. It does generate an ugly url, but it seems to be properly encoded - what kind of issues are you encountering ?

Also note that there's always two kinds of links for dms assets - the /dms-static/ ones, using the uuid, and /dms/ ones, using the path to the document.

Comment by Magnolia International [ 06/Apr/11 ]

Guys, a lot of details are to be found on the support issue, reported by Matt. Once we figure it out, let's report the relevant bits here !

Comment by Ondrej Chytil [ 22/Apr/11 ]

Actual issue here was fact that with changing of title also fileName was updated to match this value and therefore links were generated with that name (during generating the link the fileName is called).
Question is what was reason to have such a mechanism here.
Also this worked both ways (and since the second one doesn't break functionality it still remains). When you update name of document via edit dialog then title is changed to that name.

Comment by Jan Haderka [ 16/May/11 ]

just removing the possibility to set the file name via title is not fixing the issue. The proper fix should use already existing methods for encoding the file name and control should be updated to use encoded file name as well.
Also there is currently discrepancy between the links produced by getLink() and getStaticLink() methods in Document class.

Generated at Mon Feb 12 00:49:28 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.