Jump to content

adrian

PW-Moderators
  • Posts

    10,866
  • Joined

  • Last visited

  • Days Won

    348

Everything posted by adrian

  1. Hi @Laegnur - thanks for the report. I don't honestly know when this stopped working as expected, but I have added array('allowCustom' => true) to the "$pages->find" call that results from the selector you define and it works now in the latest version. Let me know if you have any continuing issues.
  2. Hi @virtualgadjo - I see where you're coming from, but I am wondering whether this would be a system wide setting or if it would need to be a setting on each rule? I am tempted to think that your suggestion for hooking into customRenameUploads() might be the best option though, but if you feel like adding a setting for your needs, I'd be happy to accept a PR.
  3. Works for me if it's inside a: $(document).ready(function() { On a somewhat related note, are you making sure to manually call: $this->wire('modules')->get('ProcessPageList'); I wasn't getting the page list to load without that. I assume you are because you're in a process module, but I wasn't getting it to work and came across this old thread: https://processwire.com/talk/topic/15938-typeerror-aprocesspagelist-is-not-a-function-in-admin/
  4. If you were testing on the backend, I am struggling to figure out how a template could be involved. I don't even know how it would get the code the from the template. Can you please provide the relevant code from the template and the code you were running in the console that is causing this. Otherwise I really am just guessing :)
  5. It will appear as a checkbox on the Console when used on the frontend. Compare: with: The code in home.php is: $page->title = 'Test modify'; which only takes effect if that "Template resources" option is checked.
  6. @MarcC - your response makes me think I didn't explain things properly because given the behavior you're seeing, I feel like you are probably already using that feature. If you're not using it, then there might be a bug causing the issue you are seeing so it would be great to know more about how you have things set up.
  7. Hi @MarcC - it should only work that way if you check the "Template resources" option in the Console. If it's happening for you without that checked can you please provide the exact code you have in your template that is resulting in this.
  8. $role->branch_parent is what you're looking for rather than admin_restrict_branch. But otherwise your example code should work.
  9. @biniyam if you configure this module to the restriction you need you should be fine if your form assigns the required role to the users. It sounds like the "Role Specified Branch Parent" might be the best option based on your description - shouldn't need a php script.
  10. You're right, but how is it possible to move sideways (x-axis) without going slightly up or down (y-axis)? I don't really understand why y-axis movements should trigger any change at all.
  11. MacOS Brave and Chrome both have the issue for me.
  12. Am I the only one seeing major bugs with the new template width functionality? See how the percent is going down, but then jumps back up again as I continue to drag to the left?
  13. @Jonathan Lahijani - that's my plan for now. I don't know for certain that 2.4.63 will fix this issue, but from what I understand it sounds like it will. That said, it still hasn't even been released on their Github repo yet: https://github.com/apache/httpd/tags so not sure how long it will be before it makes its way to APT etc, especially for Debian if it's not considered a security update.
  14. @bernhard - the thing is that the loading of the Tracy bar is handled by the core Tracy package - I just call the PHP command to enable it: https://github.com/adrianbj/TracyDebugger/blob/63eae91b18b1881e0ac99f6c33930f93ba764956/TracyDebugger.module.php#L1508. If you view the page source, you'll notice that weirdly it is added after the closing </html> - maybe that is part of the problem? I have lots of sites with fixed footers and never seen the issue you are referring to and FOUCs are a pet peeve of mine :)
  15. Nevermind, I think I just found it - an empty email address for one user :)
  16. @nbcommunication or anyone else ever seen this error in the "wire-mailgun" log? 'recipient-variables' parameter is not a valid JSON $recipientsArr[$emailAddress] = [ 'id' => $recipient->id, 'email' => $emailAddress, 'first_name' => $recipient->first_name ]; $mailer->addRecipientVariables($recipientsArr); It happens during a loop of email sends - there are lots of different emails, each sent to one or a few people so the emails are sent in batch mode, but it seems like only one of the emails in the loop actually triggers this error. I feel like perhaps there is something weird with the first name for one of the recipients (maybe a strange character or something), but before I pull all my hair out, I was hoping to hear that someone else had already come across this and know what to look for :)
  17. On a side note, I would really recommend you upgrade your PHP version - 7.x hasn't had security updates for quite some time now!
  18. Hi @aComAdi - sorry for the issues you've been having, but thanks for narrowing things down. I think it's likely this commit: https://github.com/adrianbj/TracyDebugger/commit/4b35ecddfb184cd7a04c3614fb40ac72d0a62874 to fix this issue: https://github.com/adrianbj/TracyDebugger/issues/96 I have never set up a site in a subfolder in such a way that an AJAX call to "/" doesn't work as expected, so I can't really test this, but I think the latest version should fix things for you. @Jonathan Lahijani - can you please make sure this new version doesn't affect the issue you had with bootstrapped files?
  19. Just a follow up here for those who haven't found the Github issue: https://github.com/processwire/processwire-issues/issues/1952 It looks like the next version of Apache (2.4.63) will include a fix (https://github.com/apache/httpd/commit/a1a93beb58b81f1de2b713ae5f96c41ed5952a74) that should hopefully prevent this from being an issue for PW.
  20. It's not quite as simple as a user being unpublished - it could be changes to the account pages referencing them as well and it's multiple different templates. The other reason for this approach is that I want to continue to alert users with a wire()->warning which wouldn't persist if I hooked on unpublished or changes to those other pages. Same kinda goes for emails or other alerts - I feel like this one needs to be a constant reminder. Perhaps a better approach would be to prevent unpublishing any user tied to an account page and prevent saving an account page unless a valid published user is selected. So many options :)
  21. Thanks @BitPoet - it probably is pretty similar in actuality, but it feels semantically correct in your case and just a bit off for my needs which aren't related to the theme's markup or menu etc. Thanks @ryan - I tried without a hook in templates/admin.php but the code was still called twice (again, the AJAX request for the page list), but as you suggest, I could definitely wrap it in a if($!$config->ajax) check. I think that probably makes the most sense. I initially thought things like Processwire::finished or Proccess::execute would only be called once but again that page list AJAX is the problem. And thanks for the session idea which sounds like a good option. Just an FYI - I have a check to make sure the integrity of some page reference fields (selected staff on client accounts) and I need to make sure if a staff member is unpublished that a warning is given. It's pretty efficient but I don't really want to run it on every admin page load, but ProcessLogin::loginSuccess isn't really enough either because our sessions don't often expire given how often we are in the admin.
  22. I feel pretty silly asking this question, but I am realizing that there don't seem to be many options for a hook that is only triggered once when the admin is loaded because most of the usual suspects also get called a second time during the AJAX request to load the page tree. So far the only one I can actually find is: AdminThemeFramework::getUserNavArray Does anyone else have a better idea? And also, what about a hook that is called once when a user first loads the admin in the current browser window. I am not talking about ProcessLogin::loginSuccess because that is only called after the username and password has just been entered, but rather that first time when a user opens the admin while their session is still valid from the last time. Thanks!
  23. @DrQuincy - I think you should really change your entire DB because that utf8mb3_general_ci encoding has caused you other problems as well. IIRC in your other related post I linked to a resource that explains how to make the change.
  24. @ryan - I have responded again to the ones that I think I bugs that still need fixing. You are right that some are feature requests - my point being that I think these are really useful requests that others would also benefit from. Of course it's up to you to decide if you agree, but obviously we are all going to push for things that we'd personally like to see.
×
×
  • Create New...