diff options
author | neoraider <devnull@localhost> | 2006-12-14 01:06:02 +0100 |
---|---|---|
committer | neoraider <devnull@localhost> | 2006-12-14 01:06:02 +0100 |
commit | 543336aef16562369c01992817f58e17144c9cad (patch) | |
tree | d49cd8549a836c740df7096ddcf7788ed7920c37 /pages/Pages:Edit.xml | |
parent | 93e1133ee88b03e7cae7318cb19761e698e57b86 (diff) | |
download | neon-543336aef16562369c01992817f58e17144c9cad.tar neon-543336aef16562369c01992817f58e17144c9cad.zip |
Base-Type durch Subst-Erweiterungen unnoetig gemacht; Type-Konzept entfernt.
Diffstat (limited to 'pages/Pages:Edit.xml')
-rw-r--r-- | pages/Pages:Edit.xml | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/pages/Pages:Edit.xml b/pages/Pages:Edit.xml new file mode 100644 index 0000000..e481258 --- /dev/null +++ b/pages/Pages:Edit.xml @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<page> + <info> + <name>Pages:Edit</name> + <template>phpexec</template> + <access>9:0</access> + </info> + <data> + <code> + <![CDATA[ +<?PHP + Uses('pages', 'links', 'util'); + + + if($_POST['back']) { + header('Location: ' . Unquote($_POST['backlink'])); + exit(); + } + + if(!$_POST['name'] || !$_POST['backlink']) exit(); + + if(!$GLOBALS['pages']->HasWriteAccess(Unquote($_POST['name']))) + exit(); + + $data = array(); + + foreach($_POST as $key => $val) { + if(substr($key, 0, 5) != 'data_') continue; + + $data[substr($key, 5)] = Unquote($val); + } + + $GLOBALS['pages']->Edit(Unquote($_POST['name']), $data); + + header('Location: ' . Unquote($_POST['backlink'])); + exit(); +?> + ]]> + </code> + </data> +</page> |