Upload extension files
Ok so looking into it more in detail: backend worked perfectly, so I wondered if the upload on frontend was faulty or not:
IT IS NOT. It works fine, it is just the link to download the file on FRONTEND that was faulty.
Fix to provide to your code:
you put: <a target="_blank" href="components/com_vaccount/uploads/<?php echo $this->expense->reciept;?>"><?php echo $this->expense->reciept;?></a>
when in reality the upload folder is located in administrator/components/com_vaccount.
I simply changed the code as follows:
<a target="_blank" href="administrator/components/com_vaccount/uploads/<?php echo $this->expense->reciept;?>"><?php echo $this->expense->reciept;?></a>
and now I can see the files without issue directly from frontend.
Maybe there exists a safer way to do so, but since it was an emergency for me... I hope it helps others!
I have tried to tweek the code as to add zip as a valid extension to upload when creating an expense. In Mexico, an invoice is composed of both a PDF and XML files and both need to be submitted when doing your declaration etc...
The file uploads but when I want to download it, it says it does not exist (basically deleted after upload). Why would that be? If the other file extensions get keeped, why not zip?
Thanks in advance!