Jump to content

Richard Jedlička

Members
  • Posts

    100
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Richard Jedlička

  1. Hi all, really great work. Why don't you use this logo you have posted before? I think it is much better then the one on the website.
  2. DEV branch is updated, should be PW 2.6 compatible now. And InputfieldImage is not parent of InputfieldPDF anymore. Check it out.
  3. Hi, thanks for the reply. I haven't tried the PW 2.6 yet. The reason why I used image inputfield is to render the PDF thumbnails exactly the same way as images. But maybe you are right, I should have used my own render method. I'll check it out.
  4. Great. I've removed the "git clone" section in my proposal, because I think it is not the guide how to install a module, but how to clone git repo from github (so not related to PW). The scenario is already cover by "Installing from URL".
  5. Hi, what can I do to help publish this on the website? What do you think about the proposal, does it need some changes?
  6. Hi, new version is here, as I promised. It's currently on the dev branch: https://github.com/uiii/ProcessWire-FieldtypePDF/tree/dev. The readme is updated so everything should be clear. It contains tests and they successfully passed for PW 2.4, 2.5. If you can try the module, I'd be glad to hear your opinions and suggestions.
  7. Here is my proposal. The HTML is in attachments. There are multiple ways how to install the module. Installing from directory (recommended) -------------------------------------- If the module is uploaded in the official *ProcessWire Modules/Plugins Directory* (http://modules.processwire.com), you can use this method. 1. Log in to your ProcessWire admin and go to the *Modules* page. 2. Go to the *New* tab and expand the *Add Module From Directory* section. 3. Enter the *Module Class Name* (can be found in the module's detail page, e.g. FieldtypeMapMarker). 4. Click the *Download and Install* button. Installing from URL ------------------- If the module is not in the official *ProcessWire Modules/Plugins Directory* (http://modules.processwire.com), but the module ZIP is accessible from URL, use this method. 1. Log in to your ProcessWire admin and go to the *Modules* page. 2. Go to the *New* tab and expand the *Add Module From URL* section. 3. Enter the *Module ZIP file URL* (can be found in the module's detail page, e.g. https://github.com/ryancramerdesign/FieldtypeMapMarker/archive/master.zip). 4. Click the *Download* button. 5. The downloaded modules are now listed on top of the page. Click the install button next to any of the new modules that you want to install. Installing from upload ---------------------- If the module ZIP file is not accessible from web or you have it already downloaded, you can upload the file. 1. Log in to your ProcessWire admin and go to the *Modules* page. 2. Go to the *New* tab and expand the *Add Module From Upload* section. 3. Select the *Module ZIP file*. 4. Click the *Upload* button. 5. The uploaded modules are now listed on top of the page. Click the install button next to any of the new modules that you want to install. Installing manually ------------------- If any of the above methods isn't suitable for you, you can install the module manually. 1. Place the .module file in your /site/modules/ directory. If the module contains more than one file (like supporting .css or .js files for example), it should be created in it's own directory under /site/modules/ with the same name as the module (.module file). For instance, the FieldtypeMapMarker module and supporting files should be placed in /site/modules/FieldtypeMapMarker/. 2. Log in to your ProcessWire admin and go to the *Modules* page. 3. Click the *Check for New Modules* button. 4. New modules are now listed on top of the page. Click the install button next to any of the new modules that you want to install. *Note: All third party modules should be placed in /site/modules/. You might also notice that ProcessWire keeps core modules in /wire/modules/ – You should avoid installing your modules there, as that location is reserved for core modules.* How to uninstall a module ------------------------- 1. Log in to your ProcessWire admin and go to the *Modules* page. 2. Find and click the module name that you want to uninstall. 3. Expand the *Uninstall* section, check the checkbox. 4. Click the *Submit* button. 5. It is now safe to remove the module's files from /site/modules/ if you want to. how-to-install.html
  8. Hi, I think that the page http://modules.processwire.com/install-uninstall/ should be updated according to the current PW's capabilities (Add module from directory/URL/upload). I'm writing this because it would be much better to have the instructions in one place instead of writing them to each module's readme. I'm not sure who is responsible for the content of the page, Ryan? I can update the text if you want, or at least write the proposal.
  9. Hi, it looks that only minimum of people there care about this. If the PW's license is GPL v2, what license the module is allowed to be? E.g. if I derive Pagefile class, may the derived class be licensed under MIT (or any other), or it must also be under GPL v2 license? Thanks
  10. I've just removed unnecessary code from install.php, modify output for console and add cmd options.
  11. So here is the gist: https://gist.github.com/uiii/f1877686bca81fe6d668. See the comment below the gist.
  12. @Horst: Yes, I think so from his message, but I'm not sure because he is also trying to make the PW cli installer (according to this thread: https://processwire.com/talk/topic/9124-command-line-installer/?hl=installer ).
  13. Hi, this tool is really cool idea. It would be great to have command for full PW installation, not just download. I've managed it by modifying original install.php file from PW 2.5 sources. But I'm not sure if it is production ready, it works but I haven't tested all edge cases. It requires config file with configuration array (db connection, profile, admin user credentials, ...). If you are interested I can post it somewhere. I plan to do it also for PW 2.4. With this comes and idea for 'new' command to allow installation of another versions other than the latest. EDIT: Hari KT, don't you have the same intention? What do you mean by 'one click installer'. Installer for wireshell or for PW?
  14. Hi, I'm just trying to delete file field via API. I want to delete it completely without concerning which pages is using it. I found this code: $fields = wire('fields'); foreach ($fields->find('name=field_name') as $field) { foreach ($field->getFieldgroups() as $fieldgroup) { $fieldgroup->remove($field); $fieldgroup->save(); } $fields->delete($field); } This removes the field from database it is OK. But it doesn't remove the files (from filesystem) that ware added to pages. As I was going through PW source code I've found that I have to save the page also, but it really complicates the thing. The problem starts in FieldtypeFile::___deletePageField method where the $pagefile is handled differently according to field output formatting. If the $pagefile is PageFile, the unlink is called which also deletes the file from filesystem. If the $pagefile is PageFiles the deleteAll is called which only adds hooks on page save. Why is it done this way? This makes inconsistency when deleting the field. Is there some better way to delete the field without caring about pages?
  15. Hi Mike, I haven't seen this GS error before. I'm not an expert in Ghostscript nor ImageMagick, I have just go through many internet discussions and found working php code for pdf to image conversion. But as you say, it looks like a GS bug. This is one of the issues in PW 2.5 as I mentioned earlier. See https://github.com/uiii/ProcessWire-FieldtypePDF/issues/6. If you want, you can temporarily use somatonic's fork or wait for my upgrade.
  16. Really, so you are lucky . There are some issues https://github.com/uiii/ProcessWire-FieldtypePDF/issues. Not all issues are fatal, but needs to fix. I have already fixed all of them but not published yet. I have also changed the API (still backward compatible). The new version isn't ready yet, I need to update the documentation and want to add some tests.
  17. Hi Mike, I'm not sure if there is some minimal version of ghostscript needed. I have installed ghostscript 9.15 with imagemagick 6.9.0 and according to phpinfo the php's imagick module is of version 3.1.2. In this configuration everything works fine. No binaries are executed directly from php, the php's imagick module is used (imagick.so in php.ini), but you must have installed ghostscript and imagemagick as a system package. Hope this helps you. BTW: If you are going to use this module on PW 2.5, you will probably get some errors. I'm working on that and hope to finish it this week. PW 2.4 should be ok.
  18. Ah, ok. So, I'll try to do my own solution.
  19. Hi, can you please share the installer somewhere? I'm really interested. Thanks
  20. Hi, I'm still there, but I don't have much time to fix the issues. Sorry. If you find the solution you can create a pull request or make your version of the module. If I find some time a will try to look at that. Once again, sorry.
  21. Hi, thanks for your report. Sorry, but I don't have enough time now to solve the issue. If you can wait until mid-August I will look at that and try to replace the scale function with the ProcessWire's one.
  22. I've updated the module. Added requirements check and ImageMagick settings.
  23. Fine, thanks. I'll update the module soon. Yes, I've found it and got a little inspiration. Originally I wanted to use it, but I don't like it requires exact, properly named fields to work. And conversion of the whole PDF isn't my need, just the first page thumbnail. But based on this a got an idea to add optional parameter to the thumbnail method specifing the page number to convert.
  24. Hi, thanks for the replies. Yes, that's right. When and how is the proper way to print this error? I haven't much experience with ImageMagick. I've just found somewhere the code snippet of "pdf to image" conversion and use it. What consequences will have these two options? The "delegate" thing - I think it's not related to the module itself. Hey, I didn't know that it's so simple . If it's better or not I don't know, maybe the class is more suitable for future module's extensions.
  25. PDF Fieldtype/Inputfield Module for ProcessWire allowing you to easily generate thumbnails of the PDF files embedded to the site. Current version: 1.1.2 (Changelog) Module page: http://modules.processwire.com/modules/fieldtype-pdf Github: https://github.com/uiii/ProcessWire-FieldtypePDF For detailed instructions see: https://github.com/uiii/ProcessWire-FieldtypePDF/blob/master/README.md
×
×
  • Create New...