Jump to content

dragan

Members
  • Posts

    2,007
  • Joined

  • Last visited

  • Days Won

    21

Everything posted by dragan

  1. Lots of infos here: https://processwire.com/blog/posts/composer-google-calendars-and-processwire/
  2. You have a lot of weird invisible characters in your code - this happens sometimes when you copy-and-paste from forums. Luckily, good text editors / IDEs spot such stuff and give warnings. I cleaned up your code and attached it here (together with two minor hints re: code) kalimati.zip
  3. You probably need to tell PW that it should look in that folder instead of wire/modules/. Did you clone the entire module folder to site/modules/ ?
  4. Strange. According to the official docs, this should work. Maybe a caching issue? Can't you just use @import ? Try adding a Custom Editor JS Styles Set, and then follow these steps: https://processwire.com/docs/fields/ckeditor/#custom-editor-js-styles-set
  5. Yeah, I was thinking the same. tl;dr: there's probably something broken with my server, rather than PW. In my several tests, I had to shut down Laragon (and Apache manually via Task Manager) and restart the server. I also found an Apache error, same as reported here, (installing a new Apache didn't help) + a PHP error: #8 C:\laragon\www\pwdev\wire\core\ProcessWire.php(444): ProcessWire\Session->__construct(Obj in C:\laragon\www\pwdev\index.php on line 64 [13-Jul-2019 19:00:41 Europe/Zurich] PHP Fatal error: Exception: SQLSTATE[70100]: <<Unknown error>>: 1317 Query execution was interrupted (in C:\laragon\www\pwdev\wire\core\WireDatabasePDO.php line 480) I also switched to InnoDB in the meantime... So most likely there's something broken now with my LAMP setup ? But I'll disable every hook now and also some modules, and see how it goes. Does anyone know if it's safe to delete DB-sessions manually in mySQL?
  6. @gunter I guess it's the last block of code of @bernhard's post from 4th October:
  7. You're on a roll! Thanks for all these tutorials, and a very good weekend to you, too! ???
  8. I've never tried, but a quick search suggests you can do this:
  9. Well, instead of creating 8 InputfieldFile fields with maxFiles=1, why not just create one InputfieldImage field? Not sure about customizing your special file path for storing though - usually PW stores files/images under site/assets/files/page-id/ ...
  10. Wow, PW (backend) became absolutely unusable after I created some 14k pages. Absurd long loading times. Something like discussed here? Interesting. Gotta try it out too...
  11. There's also https://modules.processwire.com/modules/duplicator/
  12. @Jim Bailie You'll find plenty of examples in the dedicated pro forum threads, once you buy it. And people are happy to share their own code-snippets / advices in those forums. "site sample": not sure if you think of it as a special installable site-profile. If so, then I would guess no.
  13. I guess I would try option 3, but of course some more information about these "tasks" and "tools" would be needed. Maybe I'd use JSON storage only for settings. This module would perhaps be useful.
  14. Did you try to manually delete all the contents of site/assets/cache/FileCompiler/ ?
  15. re: Composer It's like npm for PHP, and super-easy to use. Some scripts out there require lots of dependencies, and they also check if your system meets all requirements. Downloading all dependent libraries yourself manually can be time-consuming. You can install Composer locally, install your spreadsheet stuff, and then copy / FTP the generated vendor folder to site/wherever/. From there on, just make sure your include_once() points to the proper path, and follow the docs. tl;dr: Composer is certainly not overkill ?
  16. Just get it from Github: https://github.com/PHPOffice/PhpSpreadsheet Then include() or require() it wherever you want.
  17. You could use a simple PHP script that serves the image with readfile() and set appropriate headers in that script. Maybe setup a dummy PW page with URL-segments enabled (or use a plain old query string) that will act as a "gateway" to those images. If you don't need to have the exact same filename on each request (download), then you you could even create the filename dynamically each time with adding / injecting time() or microtime() to the filename PHP will create for you: header('Content-Disposition: attachment; filename="'.basename($file).'"');
  18. On a sidenote: You can also disable caching while Chrome inspector is open inside the settings: (of course, if you're testing with several other browsers plus mobile devices at the same time, the query-string approach is better)
  19. You could try using a pure client-side pagination that turns in-the-middle-ellipsis into a dropdown, like http://flaviusmatis.github.io/simplePagination.js/
  20. Do you know what they used before?
  21. Nice one! I never realized the comments field type is language-agnostic (because... I have never really used it, d'oh). Maybe @ryan would be interested in making it language-aware in the core?
  22. If you have 5 cars, then you'd have 5 rows of data (1 row = 1 record-set), not 2. use a classic foreach loop or for debugging purposes print_r($cars)
  23. I just installed mySQL 5.7.26 and switched to that version - everything works just fine (Laragon, Windows).
×
×
  • Create New...