Thanks for the reply but I am not trying to access the folder as a user would. The code that I developed on a windows environment needs to run in the Ubuntu environment. However, the dropdoc.php and the uploadhandler.php don’t execute inside the documents folder even though the documents folder has the permission of 777. I tried to open a text file from the documents folder via the browser but the websever won’t allow the viewing of a text file or html file.
This file /openemr/sites/default/referral_template.html is in the folder above the documents folder and I can access it in the browser. However when I copy it to the documents folder. It will not show in the browser. I get the
Forbidden
You don’t have permission to access /openemr/sites/default/documents/referral_template.html on this server.
Apache/2.4.7 (Ubuntu) Server at Port 80
Now if you can tell me how to get this to work, I would be most appreciative.
Yes, all code should be in the standard locations for things, like interface/ and library/ - site/…/documents tree is just for documents storage only specific to that database site
On the flip side, if a system allows scripts to be installed and executed in the documents folder, that means the system has not been properly secured and is more vulnerable to remote execution exploits.
Hi Sherwin,
Regarding the importing and viewing of documents, will be able to guide best route to plug your code into this during the code review(note there are functions in OpenEMR that will import/collect documents for you automatically without needing to worry about couchdb etc.). When have it on github, let us know.
-brady OpenEMR