Jump to content

adrian

PW-Moderators
  • Posts

    10,897
  • Joined

  • Last visited

  • Days Won

    348

Everything posted by adrian

  1. Turns out it already works ? Just use $repeaterPage instead of $page. Let me know if it works ok for you.
  2. Does this help? https://stackoverflow.com/questions/33758126/how-to-store-xml-obj-in-php-session-variable It might be related to the need to serialize the xml before storing. Is $xml->customer_id definitely a string?
  3. In fact I misspoke in my previous post. I've been using the new version but on a different local site Does this mean you are seeing the "open in window" icon on the new version? It should look like this: Just the Maximize/Restore icon and the close icon. The open in window icon should be hid by this rule: https://github.com/adrianbj/TracyDebugger/blob/077b5c26aea42de451dcd94d97ae186d3bbf8529/styles.css#L830-L833
  4. New version of Tracy includes 4.7.0
  5. That's ancient (10 months old) - you are missing out on so much ? but that explains why the icon is not hidden. There are lots of new options for making the Console panel larger - you can maximize the panel, but you can also fullscreen mode the editor/results panes. You can also "rollup" any Tracy panels by double-clicking on their title bar - nice to get it out of the way quickly. I'll see about restoring the "window" option, but no promises - it's been painful!
  6. Interesting because I actually purposely made this not obvious by hiding the icon that triggers the new window mode. Are you using SHIFT+Click to trigger this or is the icon not hidden for you? The reason I "disabled" this functionality is that it was a bit painful to get layout to work properly in this mode. And actually, the Console panel is completely broken for me at the moment in this mode at the moment. Are you running a much older version?
  7. Weird - I just tested upgrading Tracy with the PW Upgrades module and it deleted the old .module versions automatically. I have no idea why it wouldn't have worked the same for you. Thanks for the Adminer update note.
  8. I was worried that might happen. @bernhard added .php to the TracyDebugger.module file so that intellisense in vscode could work its magic. I thought I might starting adding the php extension to all my modules files because .module really is a silly extension in my mind. You'll be able to solve the issue my deleting the .module version. Same goes for ProcessTracyAdminer.module. I am curious what method you used to upgrade. I would have thought that the PW Upgrades module would handle this and a git update approach should also work. Updating via modules > add new should also work. Did you just unzip and copy?
  9. Hey @Tom. - I am not sure your exact goal here - not sure if the session storage is for production use, or just while developing/testing, but @bernhard and I just put this together: https://processwire.com/talk/topic/12208-tracy-debugger/?do=findComment&comment=176842 - which came about while he was working with foxycart and since you are as well, I just thought it might be worth mentioning ?
  10. Well it took several hours of discussions with @bernhard and lots of back and forwards on the best way to do things, but we've finally committed the "WebHooks" panel he posted about above. It's now called the Request Logger panel because in reality it is logging requests to a page on your site - who knows whether it's really a "webhook" request or something else. Instructions 1) In the PW admin, edit the page you want to log incoming requests for. 2) Open the Request Logger panel. 3) Click the "Enable logging on this page" button. 4) Send a request to that page. This may be something like a confirmation of payment webhook call from Paypal etc. 5) Reload the edit page in the PW admin to see the logged request. The reason we say to edit the page, rather than visit it on the frontend is because visiting the page would result in a logged request. Note that you can easily test incoming requests using the Postman app (https://www.getpostman.com/). You can choose POST or GET and under "Body" you'll want to specify Raw / JSON You'll notice the json supplied in the Postman Body is what shows up in the Request Logger panel under "input" and "inputParsed". This is all well and good, but here's where the magic really comes in ? There is a new getRequestData() method added to $page so you can get the logged data in your code. You can get logged requests by: ID (shown in the title of the logged entry in the Request Logger panel) ALL requests (an array of all logged requests for the page) The last logged request by passing "true" The current live request This allows you to have access to the data sent by the webhook without constantly having to trigger it each time - ie no need to continually make test payments over and over as you refine and debug the your scripts that consume/parse this data! You can even make use of $page->getRequestData() in your final live code if you want - this does not rely on Tracy being enabled - it just has to be installed. So you could potentially execute one request and then use the "true" option while testing, and then when you're ready to go live, you can remove the "true" so it returns the live request. There is a config setting to determine whether this method returns an array or an object. Please take it for a test drive and let us know what you think! @bernhard - did I miss anything worth mentioning?
  11. I am sure support could be added for this. Any chance you feel like having a go at implementing it? Sorry I am juggling lots of different commitments right now, but I'll take a look when I can if you don't get to it first ?
  12. I use curly braces, like this: {$page->title}-[Y_m_d_H_i_s]
  13. You should be able to specify any PHP date() format you want - if you want to replace those dashes with underscores you can. I think that should take care of the conflict with the "-n" suffix check.
  14. Does this help: https://processwire.com/blog/posts/processwire-3.0.107-core-updates/#page-gt-references
  15. Sorry about the issue with the unknown module error. I'll fix that in the next commit. Keep in mind that if you don't want it to appear under the Setup menu, you just need to make Admin > Setup > Adminer hidden. That way you could still use the Adminer panel from the Tracy debug bar. Does that help? Also, I know it's obvious, but only superusers will see the Setup > Adminer option.
  16. I am not certainly exactly what isis.pw uses, but I think it looks for things like a response from ?it and /assets/files paths to images. Maybe also ProcessWire in the header. Hopefully teppo will chime in.
  17. Hey @Guy Verville - great writeup and a great looking site! This is a question for both you and @teppo - I am wondering what is unusual about your site that is causing isit.pw to not be able to detect it as a PW site? Or maybe isit.pw is caching an old lookup for your site?
  18. Hey @bernhard - this looks really fantastic - thank you! I have a few comments re code styling to match the rest of Tracy, but I can clean that up after accepting the PR. What I am wondering is if it might be useful to add a $page->getWebHookData() method so that you don't need to know the ID of the hook. Obviously the data that is stored would need to include a pageid (I see you already store that) so this new method could grab an array of objects just for this page. I think it would also be great to be able to do: $page->getWebHookData()->last() to get the last one. Not sure how useful first() and eq() would be in this case. Maybe eq() could be in reverse order so you could get eq(0) as the last received, eq(1) as second last, etc - what do you think? I'll take a better look tomorrow and do some testing, but really excited to start using this!
  19. Thanks for the debugging. That actually makes sense because I have a check to not rename files with "-n" extensions because PW's automatic adding of "-n" when there is already a file of the same name. I'll have to see if I can sort out a workaround for this, but I won't be able to look until tomorrow.
  20. Couldn't CustumUploadNames be modified to handle this need?
  21. Strange - it seems to be working here. Is there something in your setup that differs from this?
  22. Not really sure that could be dealt with without maintaining a database of filename changes and associated page ids and checking against them whenever a page is changed. If you have a simple approach I am not thinking of, I'd be happy to implement.
  23. Good point. I am attaching a new version here for you to test. I don't have much time this morning to test it properly, but hopefully this will also handle that. @simonsays - could also please test this version? ProcessCustomUploadNames.zip
  24. Thanks @Robin S - I see that adding the tabbed interface was a significant amount of work - I think it's awesome though so thank you ? One small thing - it needs a fallback to tab_name if there is no label set. This should be an unlikely scenario, but without it, you can't get to the other tabs. $markup .= "<li class='tfw-tab{$active}' data-tab='tfw-{$tab_name}'>" . ($tab_data['label'] ?: $tab_name) . "</li>";
  25. @PWaddict - it should now work in the latest version. @simonsays - I think all your repeater issues should also now be fixed - sorry again for the huge delay on this.
×
×
  • Create New...