* @copyright Copyright (C) 2002-2005 Markus Westphal, * 2006-2008 Malcolm Cowe, 2010 Matteo Lucarelli, * 2010-2012 Uwe Steinmann * @version Release: @package_version@ */ /** * Include parent class */ require_once("class.Bootstrap.php"); /** * Class which outputs the html page for EditUserData view * * @category DMS * @package SeedDMS * @author Markus Westphal, Malcolm Cowe, Uwe Steinmann * @copyright Copyright (C) 2002-2005 Markus Westphal, * 2006-2008 Malcolm Cowe, 2010 Matteo Lucarelli, * 2010-2012 Uwe Steinmann * @version Release: @package_version@ */ class SeedDMS_View_EditUserData extends SeedDMS_Bootstrap_Style { function js() { /* {{{ */ header('Content-Type: application/javascript'); ?> function checkForm() { msg = new Array(); if ($("#pwd").val() != $("#pwdconf").val()) msg.push(""); if ($("#fullname").val() == "") msg.push(""); if ($("#email").val() == "") msg.push(""); // if (document.form1.comment.value == "") msg.push(""); if (msg != "") { noty({ text: msg.join('
'), type: 'error', dismissQueue: true, layout: 'topRight', theme: 'defaultTheme', _timeout: 1500, }); return false; } else return true; } $(document).ready( function() { /* $('body').on('submit', '#form', function(ev){ if(checkForm()) return; ev.preventDefault(); }); */ $("#form").validate({ invalidHandler: function(e, validator) { noty({ text: (validator.numberOfInvalids() == 1) ? "".replace('#', validator.numberOfInvalids()) : "".replace('#', validator.numberOfInvalids()), type: 'error', dismissQueue: true, layout: 'topRight', theme: 'defaultTheme', timeout: 1500, }); }, rules: { fullname: { required: true }, email: { required: true, email: true }, pwdconf: { equalTo: "#pwd" } }, messages: { fullname: "", email: { required: "", email: "" }, pwdconf: "", }, }); }); params['dms']; $user = $this->params['user']; $enableuserimage = $this->params['enableuserimage']; $enablelanguageselector = $this->params['enablelanguageselector']; $enablethemeselector = $this->params['enablethemeselector']; $passwordstrength = $this->params['passwordstrength']; $httproot = $this->params['httproot']; $this->htmlAddHeader(''."\n", 'js'); $this->htmlStartPage(getMLText("edit_user_details")); $this->globalNavigation(); $this->contentStart(); $this->pageNavigation(getMLText("my_account"), "my_account"); $this->contentHeading(getMLText("edit_user_details")); $this->contentContainerStart(); ?>
:
:
:
:
:
:
:
: hasImage()) print ""; else printMLText("no_user_image"); ?>
: printFileChooser('userfile', false, "image/jpeg"); ?>
:
:
contentContainerEnd(); $this->contentEnd(); $this->htmlEndPage(); } /* }}} */ } ?>