Skip to content
Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions components/com_content/src/Controller/ArticleController.php
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,11 @@ public function save($key = null, $urlVar = 'a_id')
$app = Factory::getApplication();
$articleId = $app->input->getInt('a_id');

if (\in_array($this->getTask(), ['save2copy', 'apply'], true))
{
return $result;
}

// Load the parameters.
$params = $app->getParams();
$menuitem = (int) $params->get('redirect_menuitem');
Expand Down
6 changes: 5 additions & 1 deletion components/com_content/tmpl/form/edit.php
Original file line number Diff line number Diff line change
Expand Up @@ -157,10 +157,14 @@
<?php echo HTMLHelper::_('form.token'); ?>
</fieldset>
<div class="mb-2">
<button type="button" class="btn btn-primary" data-submit-task="article.save">
<button type="button" class="btn btn-primary" data-submit-task="article.apply">
<span class="icon-check" aria-hidden="true"></span>
<?php echo Text::_('JSAVE'); ?>
</button>
<button type="button" class="btn btn-primary" data-submit-task="article.save">
<span class="icon-check" aria-hidden="true"></span>
<?php echo Text::_('JSAVEANDCLOSE'); ?>
</button>
<?php if ($this->showSaveAsCopy) : ?>
<button type="button" class="btn btn-primary" data-submit-task="article.save2copy">
<span class="icon-copy" aria-hidden="true"></span>
Expand Down
1 change: 1 addition & 0 deletions language/en-GB/joomla.ini
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ JREGISTER="Register"
JREQUIRED="Required"
JRESET="Reset"
JSAVE="Save"
JSAVEANDCLOSE="Save & Close"
JSAVEASCOPY="Save As Copy"
JSELECT="Select"
JSHOW="Show"
Expand Down