Kyberia v2.0
[mirrors/Kyberia-bloodline.git] / inc / eventz / upload_own_template.inc
1 <?php
2 /* This program is free software. It comes without any warranty, to
3 * the extent permitted by applicable law. You can redistribute it
4 * and/or modify it under the terms of the Do What The Fuck You Want
5 * To Public License, Version 2, as published by Sam Hocevar. See
6 * http://sam.zoy.org/wtfpl/COPYING for more details. */
7
8 function upload_own_template() {
9
10 global $db,$error,$node;
11 $node_id=$node['node_id'];
12 $node_template=$_POST['node_template'];
13
14 if (Is_Array($_FILES['template_file'])) {
15 copy($_FILES['template_file']['tmp_name'],OWN_TEMPLATE_DIR.'/'.$node['node_id'].".tpl");
16 }
17 $db->query("update nodes set node_template='$node_template' where node_id='$node_id'");
18 }
19
20 ?>
This page took 0.315305 seconds and 4 git commands to generate.