Contact Us Today! | vcare@wdmtech.com

WDMtech

Topic-icon Upload extension files

  • Damien Soitout
  • Damien Soitout's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
More
26 Apr 2016 02:16 #2439

Hi again :P
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:
/components/com_vaccount/views/expense/tmpl/edit.php
line 376

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!

Please Log in or Create an account to join the conversation.

  • Damien Soitout
  • Damien Soitout's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
More
26 Apr 2016 01:23 #2438

My bad, there is absolutely no extension that work, I just realized the PDFs I submitted earlier aren't there eaither.....

Please Log in or Create an account to join the conversation.

  • Damien Soitout
  • Damien Soitout's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
More
26 Apr 2016 01:19 #2437

Hello,

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!

Please Log in or Create an account to join the conversation.