• Content count

  • Joined

  • Last visited

  • Days Won


BitPoet last won the day on April 14

BitPoet had the most liked content!

Community Reputation

1,729 Excellent

1 Follower

About BitPoet

  • Rank
    Hero Member

Profile Information

  • Gender
  • Location
    Near Munich / Germany
  • Interests
    programming, writing, scuba diving, long distance hiking

Recent Profile Visitors

4,397 profile views
  1. No need for thanks. I hit my head on that problem a few times myself, so it's pure self-preservation in the long run My approach above, as I figured out just a little too late, won't work out anyway, since it might not be original object that starts the recursion.
  2. That would only catch flat recursion though. The only way to catch deeper nesting I can think of would be to pass the starting object along. Something like this (untested): public function resetTrackChanges($trackChanges = true, $startingObj = null) { parent::resetTrackChanges($trackChanges); if(!$startingObj) $startingObj = $this; foreach($this->data as $key => $value) { if(is_object($value) && $value instanceof Wire && $value !== $startingObj) $value->resetTrackChanges($trackChanges, $startingObj); } return $this; } Of course, that method signature and logic might have to be implemented by all Wire derived classes that implement their own resetTrackChanges method. On second thought, that doesn't help either. You're spot on with keeping track of seen pages outside of recursion. On the other hand, multiple resetTrackChanges calls might happen in the same program run, so there needs to be a mechanism that cleans up the tracking list.
  3. You might find out more if you print out the names ($key) of all properties of type page and their value's (page) ids. There should be some kind of repeating pattern then that leads from subscriber to tester back to subscriber, but their might be (quite) some hops in between.
  4. You can use page.fieldname on the right hand side in your selector, so you need something like this: parent=/hotels/, template=hotel, hotel_country=page.destination_country, sort=title There's a discussion with a similar setup here:
  5. You can find the answer in this thread:
  6. I think your files shouldn't be compiled (or at least the compiled files not used) at all. Does moving the namespace declaration to the very first line of your php files change anything? How you specify the include files' paths might also be relevant if you use different approaches in your class files and templates.
  7. Have you tried adding /*NoCompile*/ to the require_once() inside Master_Order.class.php?
  8. That's what I'm thinking too. I'd like to add a few neat things though before I actively go for more spotlight on it on the web. Auto save is a neat feature but probably not wanted in all scenarios, so I want to make it optional, and another feature I definitely want to get "wired" in is lool's revision history. Currently, it's far too easy to overwrite a perfectly fine document with no way back.
  9. Update: LoolEditor now uses its own simple modal without a title bar since the editor's close button also closes the modal. Things feel a lot smoother now. I think PW is currently the only CMS that integrates LibreOffice for free
  10. Brilliant! I only now got a chance to reply, and you have already changed things around just the way I imagined. I'll take your module on a test drive in our intranet on Monday.
  11. I have only recently started to work on something similar, only streamlined for frontend editing, so kudos for tackling that topic I'm likely going to peek inside the code and steal a few pieces. The only nitpick I have is that the behavior of the replacement option might not be clear to end users. The field should probably be a little more verbose and tell the user that description and/or tags are replaced by those of the selected file, or they might assume it's the other way round. Perhaps a "Replace with" option would be even more intuitive (use the selected file and keep the rest as is). It's how I'd write it as a user story - "I have a file entry on the page with a description and tags and just want to replace the old file with a new one in that entry". Just playing devil's advocate here, as I'm thinking of my 50+ intranet editors who only update their pages a few times every year.
  12. ProcessWire supports that out of the box. See here for a getting started documentation.
  13. Yes, you'll probably have to hook before Pages::trash.
  14. There are different possible approaches, but this should work: create a subdirectory in your web root for every domain, named exactly like the domain make sure ownership is correct add a rewrite rule in .htaccess before #12 that prepends the requested host name to the path: RewriteCond %{REQUEST_URI} ^/?\.well-known RewriteRule "(^|/)(.*)$" $1%{HTTP_HOST}/$2 [L] start letsencrypt with webroot option pointing to /path/to/pw/domain-in-question for every domain enjoy
  15. If you add the error line to Ryan will no doubt make short work of it.