diff --git a/pages_template/vouchers/Default.html b/pages_template/vouchers/Default.html
new file mode 100644
index 0000000..858176f
--- /dev/null
+++ b/pages_template/vouchers/Default.html
@@ -0,0 +1,27 @@
+
"],"",$html));
$ui->assign("writeable",is_writable($path));
@@ -61,7 +71,12 @@ if(strpos($action,"-reset")!==false){
if(file_exists($path)){
$html = _post("html");
run_hook('save_pages'); #HOOK
- if(file_put_contents($path, str_replace(["
"],"",$html))){
+ if(file_put_contents($path, $html)){
+ if(_post('template_save')=='yes'){
+ if(!empty(_post('template_name'))){
+ file_put_contents("pages/vouchers/"._post('template_name').'.html', $html);
+ }
+ }
r2(U . 'pages/'.$action, 's', Lang::T("Saving page success"));
}else{
r2(U . 'pages/'.$action, 'e', Lang::T("Failed to save page, make sure i can write to folder pages,
chmod 664 pages/*.html"));
diff --git a/ui/ui/page-edit.tpl b/ui/ui/page-edit.tpl
index d0ae192..a44bdd0 100644
--- a/ui/ui/page-edit.tpl
+++ b/ui/ui/page-edit.tpl
@@ -1,50 +1,82 @@
{include file="sections/header.tpl"}