in reply to Possible PM bug?
A "fix" that I've previously proposed is: Add <base target="_blank"> for the node comment on and override the preview form to use <form target="_self" ...> such that any "distractions" from previewing will open into another window, leaving the preview intact. That is about all that HTML / HTTP will allow. And I suspect that anyone who cares can probably implement that solution right now with custom CSS. I usually refuse to pretend to be a CSS expert so I'll let someone else fill in the details on how to do that and correct any HTML mistakes I've made above.
There are quite a few other tricks that would allow the last update that got submitted to be recoverable even if your browser's "Back" button doesn't work out (such failures are the minority in my experience but also happen far more often than makes sense), but that would lose updates made between the most recent submit and the "distraction". Having PerlMonks store each user's most-recent preview(s) is one of those that I've long called for.
Also, you could write JavaScript to do all manner of whacky things related to this. I suspect I'd find most of them to be worse cures than the disease, except perhaps that JavaScript doesn't work (by my choice or by limitation, sorry, "bug") in most browsers that I use. But if you like that stuff, the Free Nodelet is there for you.
I'd be for adding the target= "fix" to PerlMonks but we'd probably have to make it a user setting (default it on, however) as there are too many members with irrational hatred for target=. I'd also make comment on to, when it doesn't find a valid preview, load or link to site documentation that SiteDocClan can wordsmith explaining how you might have gotten there without a preview, why a new window may have just opened up, how to disable this protection, etc.
- tye
|
|---|