Page 1 of 1

open document in own java software

PostPosted:Mon Jan 27, 2020 2:43 pm
by drago
hello everybody,
i want to show in my java project a list of pdf-documents located in openkm. With .findByKeywords() this is no problem. But now i want make the list clickable: when the user is clicking on doc1, i want to open this (without logindata) document. Have somebody idea to implement this?
I tried it with directlink (http://user:password@openkm_host/OpenKM/Download?path=/okm:root/test/test.pdf) but then the browser starts to download the pdf, that is not what i want. My next idea is to download it in temporary windows path, open it and delete after close, but is this the best way?

Thank a lot.

Re: open document in own java software

PostPosted:Thu Jan 30, 2020 6:57 pm
by jllort
You should use man-in-the-middle concept -> use always the same user but without sharing credentials I suggest doing all the action with SDK for example downloading file with SDK using the getContent method ( in combination with your own Servlet ) https://docs.openkm.com/kcenter/view/sd ... getContent

Re: open document in own java software

PostPosted:Fri Jan 31, 2020 9:32 am
by drago
Thank you, that is a good solution.