-
Posts
10,897 -
Joined
-
Last visited
-
Days Won
348
Everything posted by adrian
-
Several more Tracy core updates just committed that improve live dump performance among other things. I have also changed the default editor protocol handler from Sublime Text to VSCode - I feel like this will be a more useful default as it seems VSCode is gaining lots of users around here.
-
Are ready.php hooks/addHookMethods called outside their use?
adrian replied to a-ok's topic in General Support
Why not cache the user's location in a session variable so you only need to make the API call once per session or with a cookie so it's potentially even less often? -
I wonder if it's to do with the htaccess symlink. I just symlink the wire directory and nothing else. Maybe your host doesn't support following symlinks in htaccess? I guess I would start by just doing the wire directory and see if that works.
-
Hi everyone, Just released v4.18 this morning which comes with the new Tracy core v2.6 I have managed to retain PHP 5.4.4+ support for now. If you are running PHP 7.1+ you will get the new Tracy core, otherwise you'll be using the old 2.5 branch. I decided not to ditch < 7.1 just yet because Debian stable still ships with 7.0. Here's the list of changes: 1) New multiple AJAX debug bars This allows you to see more than one consecutive AJAX call. There is a new module setting that controls the number of AJAX bars (default 3). Adjust this if you need, but keep in mind that you don't want lots of bars stacking up as you navigate around the PW admin where opening menu items / pages are all AJAX calls. This new feature also means that the AJAX dumps panel no longer needs to store consecutive dumps, but if you still want that, then the Dumps Recorder panel will do that. 2) BarDump (bd) and barDumpBig (bdb) calls now use LIVE This feature was always not quite right in the Tracy core, but it has been rebuilt and is now the default for these calls. This makes the dumping of large / multiple objects 10x faster. It also means that we can probably increase the default maxDepth setting and increase the value for the barDumpBig even further. I haven't made these changes yet, but I am going to start testing here and see how it goes. This means that there is no longer a need for the barDumpLive (bdl) method, so this has been removed. 3) Lots of other minor/rare bug fixes and improvements Nothing worth mentioning specifically, but definitely worth having ? There will likely be more improvements to these new core features coming pretty soon, so I'll make sure we stay up to date with those also. Let me know if you notice any problems. Cheers!
-
@Melvin Suter - I use a symlink for this purpose and it works great.
-
Hey @JoshoB - glad they sorted it out for you. I am curious to know what host this is. I would also add that I have had several issues with PW and hosts that run nginx as a reverse proxy for apache. I have sworn off these hosts for good - too many bad gateway errors.
-
Try hooking into: https://processwire.com/api/ref/pages/published/ and https://processwire.com/api/ref/pages/unpublished/ and add a wireMail call as needed.
-
@neophron - that tutorial is more than you need if you use this module, but it will give you ultimate flexibility - it really depends on your needs. If you use this module and just want a logout button you do have to have that button link to a url that performs a $session->logout() and redirect to where you want them to end up. It think in that example there is a logout page added to the admin and the template for that page does the logout and redirect. That should be all you need.
-
Sorry you must build your own.
-
[SOLVED] A question for PHP pros (variable as instanceof argument)
adrian replied to Gadgetto's topic in API & Templates
I know you need to check a constant or variable, but if you enter things directly, you don't need the namespace. I guess it's to do with quoting FieldtypeEmail when assigning to a variable or const that causes the problem. -
[SOLVED] A question for PHP pros (variable as instanceof argument)
adrian replied to Gadgetto's topic in API & Templates
Sorry @tpr - I actually even left the \ProcessWire\ in the version I posted above - d'oh. I did try without and wasn't getting an undefined wire error so assumed it was ok. -
[SOLVED] A question for PHP pros (variable as instanceof argument)
adrian replied to Gadgetto's topic in API & Templates
-
Hey @szabesz - a modules refresh and/or Tracy settings save will fix that. I converted one of the settings from a string to an array. I probably should have handled it better, but that's all you need to do.
-
Additional fields/pages slowing down the whole system.
adrian replied to NorbertH's topic in General Support
@NorbertH - thanks for the screenshot - nothing out of the ordinary there. There is no need to deactivate the RequestInfo panel, just uncheck the "Field List & Values" option from its settings: That will reduce the size and time of that panel considerably. The API Explorer and Captain Hook panels are naturally going to be large in size, but the time should be significantly lower the next time you load it because the content gets cached - for me it's 79ms. Hope that helps a little. -
Yeah, I kinda agree with you - it's a bit annoying at times - I have gotten used to the keyboard shortcuts to increase/decrease as needed. Not sure how easy it would be to do what you want because I make use of the splitjs library (https://github.com/nathancahill/split) for that stuff and it's a percentage based setup and not sure how I would go about overriding that at the moment - it's certainly on my mind though.
-
Thanks - I actually just committed one more change and did a version bump and updated modules directory.
-
And I think the key thing is that on a remote server you can still use the user switcher to change to a non-superuser and it will work - it's just that I don't want actual non-superuser users that might have the tracy-debugger permission from using it. I think that last version I just committed should be ok for this scenario. I am double checking here now, but could you confirm at your end also please?
-
Actually, thinking about non-superusers - not quite sure what I want to do here. Using the user switcher to switch to a non-superuser I think is OK for the console etc, but I don't actually think they should be available to non-superusers unless you're on local dev. Are you ok with that?
-
Hey @Robin S - sorry about - I went through a few different iterations of things and looks like I messed up a couple of things on the last version. I just made a quick fix (no version bump) that fixes it for local guest users, but I think I need to do a bit more to get non-superusers working. Feel free to test the recent commit, but hopefully will have a complete fix shortly.
-
Additional fields/pages slowing down the whole system.
adrian replied to NorbertH's topic in General Support
It would be good to know what part/panel of Tracy is causing the slowdown - I am thinking it's probably the Field List & Values section of the RequestInfo panel - I find on complex sites I tend to disable this and it can help significantly. -
@Tom. - it seems to work fine for me also. The one thing I did notice was that if I use your exact condition, it returns 'Low Stock' even though I don't have an "inventory" field at all. Not sure if a "less than" condition should return true if the field doesn't exist or there should be an error.
-
Glad you got it sorted. Just thought I'd mention that in addition to the procedural wireRender() file, we also have $files->render() https://processwire.com/api/ref/wire-file-tools/render/
- 1 reply
-
- 1
-
Hey @bernhard - sorry about that - it didn't work as you expected. Please try the latest version which lets the Console panel work as a guest when you use the "logout" option via the User Switcher and also it now works on localhost when using the "Force guest users into DEVELOPMENT mode on localhost" which should take care of @Robin S's request above. Hopefully the next version will include the new Tracy core features along with some other tweaks - just need to find some time ?
-
Why can't I update the my module's information in the module directory?
adrian replied to MoritzLost's topic in Dev Talk
I've made those changes for you. I guess you couldn't edit because you didn't set an author when you first submitted the module. The interface is pretty clunky at the moment. Hopefully Ryan will improve it with the revamp.