Krlos

Members
  • Content Count

    69
  • Joined

  • Last visited

Community Reputation

40 Excellent

About Krlos

  • Rank
    Full Member

Recent Profile Visitors

864 profile views
  1. Thank you @Soma, you were absolutely right. Using get instead of post fixed my problem!
  2. Hi, I have a page with a form for searching field data. After the results are shown I have a link to view details for every result match. Everything is working fine but after I click to view a detail and try to go back to the results page I get ERR_CACHE_MISS on Chrome and Firefox. I have been reading about this issue here The solutions posted is to add this headers to the page: header('Cache-Control: no cache'); How can I add this header to a template? Thank you
  3. Krlos

    Exactly, I know about this. Could be posible to capture the download file and open it in pdf.js for example? Right now I'm using secure file like this: I pass the file ID to a download template where it queries and serve the file. I was experimenting with Fancybox, usign this code: <a data-fancybox data-type="iframe" data-src="download/?=fid" href="javascript:;"> Sample PDF file </a> If I use a hardcoded or a relative pdf url it woks, but as SecureFile has no URL (As far as I know) I'm getting an error not found.
  4. Krlos

    Hello Again! I was able to make this module work... but now my client wants to open the PDF file on a lightbox or something so users don't need to download and open the files everytime. I have tried many things but browers allways open download prompt, there is a way I can alter the behavior? Much appreciated
  5. Thank you, I will do that.
  6. No, the profile template is not access managed is by default .
  7. I just found this fieldtype, I will look in to that. Thank you.
  8. Hello, I'm trying to build a simple Intranet system but I have been stumbling due to my lack of knowledge of Processwire. I need a very basic functionality, I don't need users to access backend or edit pages or upload content. I have built everything that is content related using pages, custom fields etc, everything is working fine as Processwire is awesome in this regard. This is what I'm missing: I have la 100 users that will read the content of this Intranet, send forms and download files. I have created 10 custom fields in the system template to hold information (Name, Last Name, Date of Birth, Phone, Cellphone etc), but I also need to add a Profile Photo, and 3 fields to hold a PDF file in each field (Contract, curriculum, and some other internal PDF). Here are my problem: I need this 4 fields (PDF and Profile Image) to be secured only accesed by 2 roles (user himself and other more privileged user) and nobody else from outside world. I've set $config->pagefileSecure = true in the config.php but I'm not sure if I don't understand how to use this or I'm doing it wrong. As I only need to show the data I have created a front end page called my-profile, in this page I present the currently logged-in user his/her information including Photo profile and the 3 PDFs. This is where I'm lost: I have give view access to the custom field profile_image only to Employee (Trabajador in spanish) role According to how I think it works... when I activated $config->pagefileSecure = true I have restricted access to this custom field only to Employee role, but if I copy the full URL and pasted in another computer I can direct access the photo profile. What I'm doing wrong?, should I to access manage the template my-profile where I'm displaying this image instead of the profile_image field? I'm planing to do the same with the PDF files but now I'm not sure if I can make this to work I would appreciate some help
  9. Hello, I'm trying to create a front end search from custom fields stored in the user system template. For example I've created a custom field "last_name", what selector can I use to find all the users with "smith" last name in my users table? and how how to combine search terms?, for example to match a search for last name "smith" that have a status of married (married also a custom field in the user template) Thank you
  10. Krlos

    Further investigation and I think I'm having the same problem. When I add the guest role it works as it shoud, If remove the guest Role the images are not viewable even so the path is correct.
  11. Krlos

    I think I have the same problem. I'm working in simple Intranet with user profiles. I'm using the System User template to add my custom fields. I have like 10 custom fields and 1 image field holding a profile image. I have enabled $config->pagefileSecure = true in my config.php file I have created a new template file called profile.php to use it in the front end for users to see her/his profile information including the profile photo. Processwire has created for every user a folder with a '-' in front of the folder. When I access the profile template in the front end using the superuser I can see my image profile. When I switch to an other user profile not superuser and visit the profile page I don't see the profile image. Inspecting the source code for the page the output for: <?= $user->profile_foto->first()->url; ?> is http://intranetms.cl:8888/site/assets/files/1131/julie-paredes-perfil.jpg Without the '-' in front of the folder name. Still logued in the profile page I copy and paste the JPG path in the Browser address and Chrome start to output gibberish. I'm using ProcessWire 3.0.98 Is this still a bug?
  12. Krlos

    Hello, I'm trying to make this module to work but It seems that my Processwire knowledge is not enough to make it work. I have a user profile with some pdf files that I need to be secured for every user. Only the owner can dowload his/her own files. So, I added the custom field 'profile-contract' to the system user template, so far so good. The secure file module is saving the files outside of the document root. Now I have created a new template in the front end (profile.php) so users can download their files and access other information about their profile. I have been using this: $user->profile_name, $user->birth_date etc to access custom field data from the user template and printed to the profile.php template The question is how can I make a link to download a secured file stored in the user system template?, in this case a custom field named $user->profile_contract in to the profile.php template Thank you.
  13. Krlos

    Hey @adrian, what is that Console window? looks really usefull
  14. You are absolutely right about this, you can build the same or better with PW api, but the views module in Drupal makes so easy for people with little or no technical background to build or modify query of content with no code at all.
  15. IMHO this is the fundamental element in this discussion. In my first discovering of Processwire I did not understand how it really worked, since I came from more trational CMSs. I have always thought that there is a lack of information on how to do "things" that are easy in other CMSs. I know that the power of Processwire comes from the freedom of doing things "your way", but sometimes someone needs just a functionality. In my case I came from Drupal and from time to time I miss a module like Views in Processwire that makes so easy to build any type of queries from simple list to complex building blocks . Maybe we need more documentation on "how to do common things".