Jump to content

dragan

Members
  • Posts

    2,007
  • Joined

  • Last visited

  • Days Won

    21

Everything posted by dragan

  1. yeah, first load jQuery, then slick.js, and at the end init your slider; also, you should wrap it in a document.ready function.
  2. Try to load JS+CSS without AIOM. It takes over 3 seconds to load... Also, load the Font Awesome fonts locally, not from remote. First time to byte is abysmal: over 5 seconds (until ready for interaction: 9s).
  3. Nice! (or "chapeau", as we say in Zürich). The article even in two languages! How did you do the inline frontend editing feature? Custom developed or a module?
  4. dragan

    Writing ninja code

    I think in my case it was Typo3
  5. dragan

    Writing ninja code

    Don't forget the classic https://github.com/Droogans/unmaintainable-code https://goo.gl/xAt1P2
  6. Congrats to your new module. I'm sure it will be a godsend for large import (or utility) tasks. I hope I'll have time to try it out soon. As for your question: I guess I'd try to first get the IDs. And I'll probably also use findMany() - apparently it's faster than find(). https://processwire.com/api/ref/pages/find-many/ https://processwire.com/blog/posts/find-and-iterate-many-pages-at-once/
  7. It seems like you don't really need the AIOM module anymore - all the 3 JS files are already minified. The only advantage you'd have is the concatenation (1 instead of 3 files). What do you see when you open the browser inspector? As for the general slowness of the site - we would need more hints/infos.
  8. Well, I guess Ryan could shed some light on the inner workings of selectors / optimizations. I never had to deal with millions of pages... It would be interesting to replicate the same query with vanilla mysql, and compare the time it takes to fetch results "directly" vs. inside PW. Perhaps some kind of time(stamp) calculations are not optimized (your original first two queries your selector produced). Creating DB indexes normally speed up queries, but I have no clue whether PW is already doing that somehow, or if it is possible to add one on your own.
  9. I'm sorry. I once (wrongly) assumed that there are certain "reserved" words (not hypens) like "title" or "page" that would cause problems in Lister Pro. Turned out, after clearing cache and session, everything was working as expected.
  10. I witnessed some rather strange behaviour some time ago (in another context), when using template (or field) names with -. I would avoid using the - chararacter altogether; use camelCase or _ instead.
  11. If $x is a counter var, shouldn't it be $x = 0; // instead of empty string? ?
  12. That's probably done with push notifications and the Push API (not sure about service workers). https://developers.google.com/web/fundamentals/codelabs/push-notifications/ Apparently it's not widely supported yet, so I guess you'll have to look out for fallbacks.
  13. Yes. Kidding aside: If you really want to split each tutorial into several pages, I would put them all on the same level. Perhaps use a tutorial-parent page for summary and introduction only (and maybe a "further links and downloads" section), and each child-page as actual tutorial-content.
  14. Have you tried using one of these? https://processwire.com/blog/posts/find-and-iterate-many-pages-at-once/ https://modules.processwire.com/modules/pages-sum/
  15. That leaves us with only IE11 supporting CSS grids only half-baked... Sadly, we still have to support it for client projects.
  16. I guess you'll need to define $upload_path. Take a look here https://gist.github.com/somatonic/5233338
  17. Perhaps SwiftMailer would be a good library (also, apparently, it can detect rejected addresses) https://swiftmailer.symfony.com/docs/sending.html#sending-emails-in-batch
  18. Where do you need this "label" to be visible? You could try adding a title field to the role template. This way, when you drill down the admin page-tree, you will see the title instead of the name.
  19. Simply create a new role, and assign only the permissions you want to that role. If you have existing super-users, change their role to that new "not-so-super-user" role
  20. Users are also stored as pages, so most API methods/variables apply here too. See the docs: https://processwire.com/api/variables/user/ and / or the PW cheatsheet: http://cheatsheet.processwire.com/
  21. Hi, and welcome to the PW-forum. Can you tell us more about your PHP apps? Do you intend to use PW for more than just user-management? Do you plan to rewrite your custom apps with PW?
  22. maybe you could use this? http://cheatsheet.processwire.com/pagearray-wirearray/getting-items/a-unique/
  23. @flydev I'd like to test too. (Especially after I tried to set up backup/sync cron jobs via a server's crappy control panel where everything just works half-baked...)
  24. Luckily, we have more than a dozen real devices. We don't rely on just desktop browser resizing and emulation. Only exception being responsive HTML emails, where we use Litmus - but thank God we only do such stuff like once a year.
  25. There's always good old pagination you could use... https://processwire.com/api/modules/markup-pager-nav/ Maybe in 2017 that's not considered "sexy", but hey - if it works, it works
×
×
  • Create New...