Environment: DXP 7.1 with Fix Pack 11 and hotfix-2036
Steps to reproduce:
Log in as Admin
Go to Content > Documents and Media
Upload a docx file (eg: "demo.docx")
Leave the Title field as it is
Go to info for that document and check the WebDAV URL
Paste it into a browser tab and the downloader will automatically associate the file with Word
Upload the "demo.docx" file again
Change the title to "demo file"
Take its WebDAV URL and paste it into a new tab
Actual behavior: The WebDAV link does not contain the file extension and the downloader will not recognize the file and will not associate it with a default program.
Expected behavior: Even if the file is called "demo file", the link and the file itself should have the corresponding ".docx" extension.
As per this comment this comment, the extension is not added to the link because that way, WebDAV could not differentiate between an MS Word document with title "A" and an MS Word document with title "A.doc". However, this should not be a concern any longer (the linked LPP is for 6.1), because Liferay does not let you upload 2 documents that would have the same fileName in the DB. Consider the following scenario:
Try to upload the same file by entering only "demo" as title
Result: you will receive an error: Please enter a unique document name.
Based on this, I think it should be possible to create a correct WebDAV URL by adding the extension at the end (for example, from the extension column in the DB).
Also tested on:
7.1.x @c33098f5ada458e432f3ecc61e73ad285ddd8940 ->Same issue
Master @ee1c1a89d1535adcddce004ac1a003dafd02924b ->Same issue