Forums › Forums › Slimbox2 plugin › Maintenance mode
- This topic has 11 replies, 2 voices, and was last updated 15 years, 7 months ago by
imported_Ryan.
-
AuthorPosts
-
January 9, 2009 at 8:46 am #522
imported_Ryan
MemberMalcalevak, any chance you could set something like this up for the SlimBox2 plugin?
"https://geek.hellyer.kiwi/forum/http://localhost/phpBB3/viewtopic.php?t=6.msg3059#msg3059" wrote:It adds a maintenance mode. The menu can still be seen, but only if ?mln=on is appended to the URL. ie: https://geek.hellyer.kiwi/?mln=on would work (if I had the plugin installed here).…
I actually added this feature to allow users to turn it on and off in the PixoPoint Template Generator but then realised it was potentially useful for this purpose too.
When ?mln=on is used, the menu will stay on until the session is killed (usually when you close the browser). It can be turned off by adding ?mln=off.
If you did that I could add it as a demo inside the [iurl=https://geek.hellyer.kiwi/generator/]template generator[/iurl]. I don’t want to add it by default as I’m trying to keep my page loads to a minimum (it’s already swelling as is).
January 9, 2009 at 8:48 am #4560imported_Ryan
MemberYou can see how I did it in the latest beta, it’s all contained at the bottom of the source code in index.php.
January 9, 2009 at 12:06 pm #4561malcalevak
ModeratorI’ll look into it.
January 9, 2009 at 12:44 pm #4562imported_Ryan
MemberThanks. It’s not a big deal, but it makes it a little easier to demonstrate how it works when users can just click a button to activate it.
January 13, 2009 at 9:09 am #4563imported_Ryan
MemberI wanted a demo up ASAP so I added the maintenance mode functionality in.
Feel free to use it in the official plugin. Otherwise I’ll just use it here for the demo. It would be handy to be able to upgrade to whatever new version you may create though.
January 13, 2009 at 9:12 am #4564imported_Ryan
MemberOne mistake … the description box in the admin page is copy and pasted from another box so is entirely unrelated to the maintenance mode … just needs replaced with something more appropriate.
Oh, and it’s activated by ?slimbox=on. So shortly the following URL will activate the plugin here on the site … https://geek.hellyer.kiwi/?slimbox=on and the following will turn it off … https://geek.hellyer.kiwi/?slimbox=off
January 13, 2009 at 7:42 pm #4565malcalevak
ModeratorThanks, Ryan. I’ll try to remember to incorporate this with the next release, that I hope will come in the next 8 hours or so.
January 13, 2009 at 11:30 pm #4566imported_Ryan
MemberThanks. I just need this sort of functionality as I want to keep the load on the template generator to a minimum. Plus there’s no point loading a plugin if the user has no intention of ever implementing it. This way they can turn it on if they want to test it, or leave it off if they want. Plus I can set it to turn on or off depending on what part of the site they’re on.
I suppose this could be used by theme authors too. If they want a SlimbBox on one part of their site, but not another, then this would be a way to do that.
January 14, 2009 at 3:07 am #4567malcalevak
ModeratorThe coding for the next release is all done, but it’s late, so I’ll update the release tomorrow morning.
Once it’s out would you mind taking a look at my implementation of the maintenance mode feature? Your method seemed overly complicated (why were you setting a session variable?), I simplified it, and in my tests it appeared to be working, but I wanted to make sure I didn’t inadvertently cut something out.
January 14, 2009 at 4:07 am #4568imported_Ryan
MemberI set a session variable so that when you moved to another page the plugin would still work. Without it, when you moved to another page with the ?slimbox=on in the URL, the plugin would not work.
Since it only loads the session variable when in maintenance mode I didn’t worry about the extra server load of using the session variable.
And yep, I’ll take a look for sure.
January 14, 2009 at 9:16 pm #4569malcalevak
ModeratorThe release got delayed, the picasaweb script was broken (I’m waiting to see if the author can fix it, but not I’ll likely try myself), I also can’t seem to set a session variable in my own WordPress install, which is confounding me.
At first I thought I must’ve changed something in my code layout, but it didn’t work with the copy you provided either. I’m looking into the matter to see if I can find a simple resolution or not. I might switch to using a wordpress option, though I think this would be less than ideal.
On the off chance I just did something wrong in my testing, I’ve attached the unofficial release for review.
And unrelated to this issue, and probably actually an SMF issue, but when selecting reply with attachments it’d be nice to have any already typed reply copy over. Thankfully the back button still preserved the info.
January 16, 2009 at 11:55 am #4570imported_Ryan
Member[quote:3vn9yz81]And unrelated to this issue, and probably actually an SMF issue, but when selecting reply with attachments it’d be nice to have any already typed reply copy over.[/quote:3vn9yz81]
Good point. I’m not sure how to do that though, could be tricky.
-
AuthorPosts
- You must be logged in to reply to this topic.