Jason LeMahieu (MadtownLems)
Forum Replies Created
-
Forum: Plugins
In reply to: [Surge] Cache 404s?>> Hope that helps!
Yes – it helps a ton and we’re now Surge-caching our 404 pages. Thanks for the continued support!
Forum: Plugins
In reply to: [Post Type Switcher] Multisite compatible?Yup. Can either be activated network-wide or for individual sites without issue.
Thanks! Works great and being able to filter the entire argument array gives us some additional flexibility. cheers!
I have the same problem as Patrice when Advanced Custom Fields PRO is active. When it’s active, the entire left sidebar (“Media Library Organizer -> Settings icon, new folder, sort, etc.”). That entire bar is present in the DOM, but not visible in the window.
However, the JS fix that worked for Patrice does NOT seem to work for me.I dug through the code a bit, and a couple of things:
1) This issue was unrelated to 3.5.1 -> 3.5.1.1. The issue was that Simply Static somehow got stuck thinking it was already running an export. After clearing the site option for simply-static_multisite_export_running , we got cooking again.2) I think that Exception line may need an update for PHP 8.3 compatibility as to not fatal error (and possibly other Exceptions; I haven’t checked)
Forum: Plugins
In reply to: [Simply Static - The Static Site Generator] Admin Bar and ss_user_capabilityWorks as expected in 3.5.1.1 – thanks!
Just confirming this is working as expected – thanks!
I love that. I’m not overly concerned about a stray table – it was just the files that I was concerned about.
So long as clearing “the temporary directory” also includes the generated zip (and debug.txt files), then this sounds great to me!!Forum: Plugins
In reply to: [Simply Static - The Static Site Generator] Export Filename SuggestionsNow we’re cooking – thanks! π₯
I donβt think weβll add that to the core plugin for now
Fair. I respect that decision, and can certainly work with what’s there – especially now that there’s a button to clean house! At the same time, I’d like to give a few more things for you to think about while you consider everything.
– Uninstall hooks almost never get run in MultiSite. In a world where Site Administrators aren’t installing/uninstalling plugins, only choosing from what’s available, they are much more likely to be Activated/Deactivated.
– Uninstall hooks typically don’t get run when sites use version control. Things are only ‘uninstalled’ by the plugin code simply vanishing at some point.
– Your plugin, by the nature of what it does, leaves a HUGE footprint. We’re not talking about leaving a trivial couple of rows in wp_X_options or something. We are talking about leaving behind an entire static version of the site AND often all that zipped up.
– In MultiSite, these temporary files and static exports sit inside the uploads folder and count against the site’s storage quota. Simply generating a site static export can use or even exceed a site’s storage quota instantaneously. In one of my tests, a site with a < 5 MB media library ballooned to using 136 MB of storage simply by generating a static export (which is actually what clued me into looking at this whole situation).
– If someone deactivates the plugin, then reactivates it at some later point – they’ll almost certainly want to generate a fresh static export at that point anyway, so storing the temporary files and static export was all for nothing.For plugins with a smaller footprint, that might want to be reactivated later and have the same settings preserved… I completely agree that one shouldn’t clean house too much on deactivation. But I feel this is different and users would likely prefer that things get cleaned up on deactivation. Just some food for thought π
On a related note, if I was going to go looking for a button to clear the static export and/or temporary files, I can’t say that ‘Debug’ would have been my first guess. I’d have looked at Utilities first (which just so happens to already contain several over ‘reset’ style utilities). That feels like a more natural home.
Thanks again for everything!
I dug into the code a bit, and it looks like you might be trying to do this cleanup on “Uninstall” as opposed to “Deactivation”.
You mentioned “auto-clear the directory on deactivation”, but added it to uninstall.php, so I’m not 100% sure what your intention is here. But my vote would be to clean house on deactivation (as well as uninstallation).Forum: Plugins
In reply to: [Simply Static - The Static Site Generator] Export Filename SuggestionsHeya – thanks!
I just tried this as written, and it made my “click here to download” link be ONLY “simply-static…. .zip” – no domain name or folder or anything πAs a result, I can’t actually find it was able to write the zip anywhere, or where.
I’m not sure if you’re intention was to have the filter edit only the FILE name, or the entire directory path (but I would have thought just the FILE name). I couldn’t find anywhere in the debug log that actually says where the zip is supposed to be saved.>> We extended our uninstall.php file now to remove the entire simply-static directory in wp-content/uploads on uninstalling the plugin for better cleanup.
Deactivating the plugin isn’t removing this directory for me. π€I took a quick look and noticed it should be dropping its tables, as well – but that ALSO doesn’t appear to be the case. I’m left with wp_X_simply_satic_pages after deactivation. So perhaps there’s a larger issue with the deactivation hook?
The button added to Debug does remove the temporary files, though! One minor UI suggestion: Consider being clear that removing Temporary Files will ALSO remove the generated backup. I think one could easily assume that temporary files are only the files required to generate the backup.Working perfectly now – thanks a ton!
Woop woop!
One thing, though – can you be sure to escape the names?
I have a site titled: Jason’s “Sample” Site (specifically to test this because it comes up all the time)
and it gets displayed in the dropdown as:
Jason's "Sample"Site