mirror of
https://github.com/monstra-cms/monstra.git
synced 2025-08-01 10:50:37 +02:00
Pages Plugin: clone action improvements.
This commit is contained in:
@@ -123,6 +123,9 @@
|
|||||||
// Get original page
|
// Get original page
|
||||||
$orig_page = $pages->select('[slug="'.Request::get('name').'"]', null);
|
$orig_page = $pages->select('[slug="'.Request::get('name').'"]', null);
|
||||||
|
|
||||||
|
// Generate rand page title
|
||||||
|
$rand_page_title = $orig_page['title'].' [copy]';
|
||||||
|
|
||||||
// Clone page
|
// Clone page
|
||||||
if ($pages->insert(array('slug' => $rand_page_name,
|
if ($pages->insert(array('slug' => $rand_page_name,
|
||||||
'template' => $orig_page['template'],
|
'template' => $orig_page['template'],
|
||||||
@@ -130,8 +133,9 @@
|
|||||||
'robots_index' => $orig_page['robots_index'],
|
'robots_index' => $orig_page['robots_index'],
|
||||||
'robots_follow'=> $orig_page['robots_follow'],
|
'robots_follow'=> $orig_page['robots_follow'],
|
||||||
'status' => $orig_page['status'],
|
'status' => $orig_page['status'],
|
||||||
'access' => $orig_page['access'],
|
'access' => (isset($orig_page['access'])) ? $orig_page['access'] : 'public',
|
||||||
'title' => $rand_page_name,
|
'expand' => (isset($orig_page['expand'])) ? $orig_page['expand'] : '0',
|
||||||
|
'title' => $rand_page_title,
|
||||||
'description' => $orig_page['description'],
|
'description' => $orig_page['description'],
|
||||||
'keywords' => $orig_page['keywords'],
|
'keywords' => $orig_page['keywords'],
|
||||||
'date' => $orig_page['date'],
|
'date' => $orig_page['date'],
|
||||||
|
Reference in New Issue
Block a user