Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
[request] Save As, Save New button for 4.5+
For the love of [your favorite deity] let’s get a f*!ing “save as” or “save new” button on the write page. I believe this has been standard practice since computers first saved files to storage devices.
Offline
Re: [request] Save As, Save New button for 4.5+
Umm would this work? http://forum.textpattern.com/viewtopic.php?pid=73494
Offline
Re: [request] Save As, Save New button for 4.5+
Um no. Here’s why
Offline
Re: [request] Save As, Save New button for 4.5+
mrdale wrote:
For the love of [your favorite deity] let’s get a f*!ing “save as” or “save new” button on the write page. I believe this has been standard practice since computers first saved files to storage devices.
+1
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Re: [request] Save As, Save New button for 4.5+
Bumpity Bump. “Save New” anyone?
Offline
Re: [request] Save As, Save New button for 4.5+
I’ve made experimental rah_dupliquer, that adds ⌘+D (or CTRL+D on other platforms) shortcut support to Article, Form and Page panels. The plugin is only for 4.6-dev, but you can feel free to install it using Composer or to compile it; I don’t offer support or install packages, it’s destined to break before 4.6.0 is out.
You can use the JavaScript the plugin is build around to make similar solution for 4.5. To save the current article form as new, doesn’t take more than running:
var form = $('form');
form.find('[name=exp_year], [name=url_title]').val('');
form.append([
'<input type="hidden" name="publish" value="1" />',
'<input type="hidden" name="publish_now" value="1" />',
'<input type="hidden" name="Status" value="1" />'
].join(''));
form.off('submit.txpAsyncForm').trigger('submit');
The above:
- Finds the form on the page.
- Removes expiration year and URL title.
- Adds in needed inputs (makes the form to create new article).
- Turns off
submit.txpAsyncForm
event (on 4.5.x you will have to unregister the wholesubmit
event I suppose, or clone the form without handlers, e.g.form.clone().trigger('submit')
), and triggers submit.
Last edited by Gocom (2013-10-20 10:13:18)
Offline
Re: [request] Save As, Save New button for 4.5+
Nice! Gives site editors the ability to duplicate articles from the write screen and as a bonus gives them a keyboard shortcut…
From a UI perspective it needs a simple change, a big “duplicate” or “save-new” button. That would work way better for casual site editors than an inexplicable keyboard shortcut tooltip.
What say you, J-dizzle?
Offline
Re: [request] Save As, Save New button for 4.5+
mrdale wrote:
What say you, J-dizzle?
That particular plugin is just for a shortcut, sorry. J-dizzle here doesn’t wear diamonds.
I personally don’t much dig button arrays, thus the ⌘+D and ⌘+S plugins of mine. I outlined the core JavaScript functionality so that someone else can scratch together a plugin that runs that same code on a button click.
Last edited by Gocom (2013-10-20 17:39:56)
Offline
Re: [request] Save As, Save New button for 4.5+
OK got it. J-dizzle don’t do UX :) Badass!
So a random tooltip floating next to a button with no explanation is good enough…
…D-dawg puts on his jquery coveralls.
Offline
Offline
Re: [request] Save As, Save New button for 4.5+
Gonna have to do better than that for intuitive UX sir.
Offline
Re: [request] Save As, Save New button for 4.5+
mrdale wrote:
Gonna have to do better than that for intuitive UX sir.
That is debatable; the whole duplication is a secondary action (once a five years event for me) and the whole point of the plugin is to be buttonless and to add a keyboard shortcut. If you want a button, the plugin isn’t that. That’s why I voluntarily tried to help and shared the actual code you will need to save the form as a new article.
Offline