I am developing an app that helps to organize and visualize many PDF documents by topic/theme. I can upload and read a single PDF but I have difficulty in reading multiple PDF documents.
For single PDF document:
ui.R
---
fileInput('file1', 'Choose PDF File', accept=c('.pdf'))
---
server.R
--------
library(pdftools)
-------
mypdf<-reactive({
inFile <- input$file1
if (is.null(inFile)){
return(NULL)
}else{
pdf_text(inFile$datapath)
}
})
To upload multiple PDF files, I have to use multiple = TRUE in the ui.R portion of the code, but how can I read in all the uploaded files?