summaryrefslogtreecommitdiffstats
path: root/help/index.php
diff options
context:
space:
mode:
authorJakob Sack <kde@jakobsack.de>2011-04-16 17:49:57 +0200
committerJakob Sack <kde@jakobsack.de>2011-04-16 17:49:57 +0200
commitaf1e48df80680dfa2b6e1367752a41aee750c308 (patch)
tree6207783e6124c9fb795f2eb12b3d67886c239731 /help/index.php
parentb5f913a3fc66a3036fc7ea291d67a72f7a0ecd40 (diff)
downloadnextcloud-server-af1e48df80680dfa2b6e1367752a41aee750c308.tar.gz
nextcloud-server-af1e48df80680dfa2b6e1367752a41aee750c308.zip
Changes in the user experience
Diffstat (limited to 'help/index.php')
-rw-r--r--help/index.php33
1 files changed, 33 insertions, 0 deletions
diff --git a/help/index.php b/help/index.php
new file mode 100644
index 00000000000..0a54ddb9cf4
--- /dev/null
+++ b/help/index.php
@@ -0,0 +1,33 @@
+<?php
+
+require_once('../lib/base.php');
+require( 'template.php' );
+if( !OC_USER::isLoggedIn()){
+ header( "Location: ".OC_HELPER::linkTo( "index.php" ));
+ exit();
+}
+
+$settings = array();
+
+// Do the work ...
+if( $_POST["submit"] )
+{
+ if( $_POST["newpassword"] != $_POST["newpasswordconfirm"] ){
+ // Say "Passwords not equal"
+ }
+ else{
+ if( OC_USER::checkPassword( $_SESSION["username"], $_POST["password"] )){
+ // Set password
+ OC_USER::setPassord( $_SESSION["username"], $_POST["newpassword"] );
+ }
+ else{
+ // Say "old password bad"
+ }
+ }
+}
+
+$tmpl = new OC_TEMPLATE( "help", "index", "user" );
+$tmpl->assign( "settings", $settings );
+$tmpl->printPage();
+
+?>