Jump to content

hintraeger

Members
  • Posts

    22
  • Joined

  • Last visited

About hintraeger

  • Birthday 04/03/1968

Contact Methods

  • Website URL
    www.hintraeger.com

Profile Information

  • Gender
    Male
  • Location
    Leutasch, Österreich, Neu-Ulm, Deutschland

Recent Profile Visitors

796 profile views

hintraeger's Achievements

Jr. Member

Jr. Member (3/6)

14

Reputation

  1. I have no files prepended/appended and tracy debuger is also disabled. But I know the problem now. The downloaded file is only unreadable on my older Mac by Acrobat, Preview and Safari. In Brave it is and on newer operating system versions there is also no problem. The pdf must have been altered somehow so that it is no longer compatible with older pdf readers. A bit strange. But it would be nice if processwire had a solution here on how to prevent the download of files directly via an url link. Maybe there is already such a solution and I just don't know it. I think there was a solution in drupal. There you could decide whether the files should be stored in a directory outside the web directory and thus be protected from direct access. Unfortunately I don't know how the download was solved via a template. It would be great if there was a solution in the future. Many thanks for your answers.
  2. Thanks, yes I tried that too, but unfortunately it's not quite what I need.
  3. ... is just a placeholder, I have removed the correct path. The file with the correct file size is downloaded, but it is broken. But if I download the same file outside of processwire in the same way, then the file is OK.
  4. sorry i have forgot something. The download works, but the downloaded file is defect: Acrobat Reader reports: An error occurred while opening this document. This file is damaged and cannot be repaired. Outside processwire with the same procedure in pure php the same downloaded file is ok.
  5. I would like to protect files (pdf) that are located in the site/assets/files folder from being downloaded directly via the url that leads to this file. However, when a page containing the file field is called up, it must be possible to make this file available for download. Is there a solution for this in processwire. The access should be controlled depending on the role of the current user and another parameter. I tried it like this: I have protected the folder site/assets/files with .htaccess file: <FilesMatch "\.(pdf)$"> <IfModule mod_authz_core.c> Require all denied </IfModule> <IfModule !mod_authz_core.c> Order allow,deny Deny from all </IfModule> </FilesMatch> Then created a template that makes the file path available for download as follows: <?php if( $ok ) { header("Content-type:application/pdf"); header("Content-Disposition:attachment;filename=$downloadname" ); header("Expires: 0"); header("Cache-Control: must-revalidate, post-check=0,pre-check=0"); header("Pragma: public"); readfile("/var/www/...".$download); } This works perfectly in a test php file, but when integrated via a template file in processwire it does not work. My guess is that a header is delivered by processwire, a different content-type or something like that. In the template I have tried contentType application/pdf and empty, neither works.
  6. The SOAP-Service could not be reached. Please take a look in your php-configuration with phpinfo(); Is there SOAP-Client enabled? (https://stackoverflow.com/questions/11391442/fatal-error-class-soapclient-not-found)
  7. This little module is for verifying a vat number (UID) through a SOAP webservice (http://ec.europa.eu/taxation_customs/vies/checkVatService.wsdl). After installing this module you get a additional option in details-tab to check the field, if it is a real UID. https://modules.processwire.com/modules/inputfield-uid/ https://github.com/hintraeger/PW-InputfieldUID
  8. Thank you for this module. I like it. Is there a posibility to notice them who saves the cookie. To make a documentation of it. So far I know, the privacy policy says, you have to do that. Its very strange and nonsensical in my opinion. Perhaps it ist possible to make a entry in logs. This would be very great. Perhaps others know, what is realy necessary.
×
×
  • Create New...