aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/css/jquery-ui-1.8.14.custom.css3
-rw-r--r--core/css/multiselect.css2
-rw-r--r--core/css/styles.css24
-rwxr-xr-xcore/js/jquery.infieldlabel.min.js12
-rw-r--r--core/js/js.js12
-rw-r--r--core/js/multiselect.js12
-rw-r--r--core/js/setup.js12
-rw-r--r--core/lostpassword/index.php32
-rw-r--r--core/lostpassword/resetpassword.php27
-rw-r--r--core/lostpassword/templates/email.php1
-rw-r--r--core/lostpassword/templates/lostpassword.php (renamed from core/templates/lostpassword.php)9
-rw-r--r--core/lostpassword/templates/resetpassword.php14
-rw-r--r--core/templates/installation.php57
-rw-r--r--core/templates/layout.guest.php2
-rw-r--r--core/templates/login.php22
-rw-r--r--core/templates/resetpassword.php10
16 files changed, 180 insertions, 71 deletions
diff --git a/core/css/jquery-ui-1.8.14.custom.css b/core/css/jquery-ui-1.8.14.custom.css
index 2ddee46c84f..887e4b5e57b 100644
--- a/core/css/jquery-ui-1.8.14.custom.css
+++ b/core/css/jquery-ui-1.8.14.custom.css
@@ -33,6 +33,9 @@
/* states and images */
.ui-icon { display: block; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat; }
+/* states and images */
+.ui-icon { width: 16px; height: 16px; }
+.ui-icon-closethick { background-image: url(../img/actions/delete.png); }
/* Misc visuals
----------------------------------*/
diff --git a/core/css/multiselect.css b/core/css/multiselect.css
index 22e5098d3bf..ee426351769 100644
--- a/core/css/multiselect.css
+++ b/core/css/multiselect.css
@@ -1,5 +1,5 @@
ul.multiselectoptions { z-index:49; position:absolute; background-color:#fff; padding-top:.5em; border:1px solid #ddd; border-top:none; -moz-border-radius-bottomleft:.5em; -webkit-border-bottom-left-radius:.5em; border-bottom-left-radius:.5em; -moz-border-radius-bottomright:.5em; -webkit-border-bottom-right-radius:.5em; border-bottom-right-radius:.5em; -moz-box-shadow:0 1px 1px #ddd; -webkit-box-shadow:0 1px 1px #ddd; box-shadow:0 1px 1px #ddd; }
-div.multiselect { padding-right:.6em; display:inline; position:relative; display:inline-block }
+div.multiselect { padding-right:.6em; display:inline; position:relative; display:inline-block; vertical-align: bottom; }
div.multiselect.active { background-color:#fff; border-bottom:none; border-bottom-left-radius:0; border-bottom-right-radius:0; z-index:50; position:relative }
div.multiselect>span:first-child { margin-right:2em; float:left; }
div.multiselect>span:last-child { float:right; position:relative }
diff --git a/core/css/styles.css b/core/css/styles.css
index 343ee4ca42d..8f309333318 100644
--- a/core/css/styles.css
+++ b/core/css/styles.css
@@ -16,7 +16,7 @@ body { background:#fefefe; font:normal .8em/1.6em "Lucida Grande", Arial, Verdan
/* HEADERS */
#body-user #header, #body-settings #header { position:fixed; top:0; z-index:100; width:100%; height:2.5em; padding:.5em; background:#1d2d44; -moz-box-shadow:0 0 10px #000, inset 0 -2px 10px #222; -webkit-box-shadow:0 0 10px #000, inset 0 -2px 10px #222; box-shadow:0 0 10px #000, inset 0 -2px 10px #222; }
-#body-login #header { margin:-2em auto 0; text-align:center; height:10em;
+#body-login #header { margin: -2em auto 0; text-align:center; height:10em;
-moz-box-shadow:0 0 1em #000; -webkit-box-shadow:0 0 1em #000; box-shadow:0 0 1em #000;
background: #1d2d44; /* Old browsers */
background: -moz-linear-gradient(top, #35537a 0%, #1d2d42 100%); /* FF3.6+ */
@@ -42,13 +42,13 @@ input[type="checkbox"] { width:auto; }
#quota { cursor:default; }
#body-login input { font-size:1.5em; }
-#body-login input[type="submit"] { float:right; margin-right:.8em; }
+#body-login input[type="text"], #body-login input[type="password"] { width: 13em; }
+#body-login input.login { width: auto; float: right; }
#remember_login { margin:.8em .2em 0 1em; }
form.searchbox input[type="search"] { position:fixed; font-size:1.2em; top:.4em; right:3em; padding:.2em .5em .2em 1.5em; background-image:url('../img/actions/search.svg'); background-repeat:no-repeat; background-position:.5em center; border:0; -moz-border-radius:1em; -webkit-border-radius:1em; border-radius:1em; }
input[type="submit"].enabled { background:#66f866; border:1px solid #5e5; -moz-box-shadow:0 1px 1px #f8f8f8, 0 1px 1px #cfc inset; -webkit-box-shadow:0 1px 1px #f8f8f8, 0 1px 1px #cfc inset; box-shadow:0 1px 1px #f8f8f8, 0 1px 1px #cfc inset; }
input[type="submit"].highlight{ background:#ffc100; border:1px solid #db0; text-shadow:#ffeedd 0 1px 0; -moz-box-shadow:0 1px 1px #f8f8f8, 0 1px 1px #ffeedd inset; -webkit-box-shadow:0 1px 1px #f8f8f8, 0 1px 1px #ffeedd inset; box-shadow:0 1px 1px #f8f8f8, 0 1px 1px #ffeedd inset; }
-
/* CONTENT ------------------------------------------------------------------ */
#controls { width:100%; top:3.5em; height:2.8em; margin:0; background:#f7f7f7; border-bottom:1px solid #eee; position:fixed; z-index:50; -moz-box-shadow:0 -3px 7px #000; -webkit-box-shadow:0 -3px 7px #000; box-shadow:0 -3px 7px #000; }
#controls .button { display:inline-block; }
@@ -61,17 +61,22 @@ input[type="submit"].highlight{ background:#ffc100; border:1px solid #db0; text-
/* LOG IN & INSTALLATION ------------------------------------------------------------ */
#body-login { background:#ddd; }
-#body-login p.info { width:16em; margin:2em auto; padding:1em; background:#eee; -moz-box-shadow:0 1px 0 #bbb inset; -webkit-box-shadow:0 1px 0 #bbb inset; box-shadow:0 1px 0 #bbb inset; -moz-border-radius:1em; -webkit-border-radius:1em; border-radius:1em; }
-#body-login p.info a { font-weight:bold; }
+#body-login div.buttons { text-align: center; }
+#body-login p.info { width:22em; text-align: center; margin:2em auto; color:#777; text-shadow:#fff 0 1px 0; }
+#body-login p.info a { font-weight:bold; color:#777; }
#login { min-height:30em; margin:2em auto 0; border-bottom:1px solid #f8f8f8; background:#eee; }
-#login form { width:18em; margin:2em auto 5em; padding:0; }
+#login form { width:22em; margin:2em auto 2em; padding:0; }
#login form fieldset { background:0; border:0; margin-bottom:2em; padding:0; }
#login form fieldset legend { font-weight:bold; }
-#login form label { position:absolute; margin:.8em .8em; font-size:1.5em; color:#666; }
-#login #dbhostlabel, #login #directorylabel { display:block; margin:.95em 0 .8em -7em; }
+#login form label { margin:.8em .8em; color:#666; }
+/* NEEDED FOR INFIELD LABELS */
+p.infield { position: relative; }
+label.infield { cursor: text !important; }
+#login form label.infield { position:absolute; font-size:1.5em; color:#AAA; }
+#login #dbhostlabel, #login #directorylabel { display:block; margin:.95em 0 .8em -8em; }
#login form input[type="checkbox"]+label { position:relative; margin:0; font-size:1em; text-shadow:#fff 0 1px 0; }
-#login form ul.errors { background:#fed7d7; border:1px solid #f00; list-style-indent:inside; margin:0 0 4em 0; padding:1em 1em 1em 5em; }
+#login form ul.errors { background:#fed7d7; border:1px solid #f00; list-style-indent:inside; margin:0 0 2em; padding:1em; }
#login form #selectDbType { text-align:center; }
#login form #selectDbType label { position:static; font-size:1em; margin:0 -.3em 1em; cursor:pointer; padding:.4em; border:1px solid #ddd; font-weight:bold; background:#f8f8f8; color:#555; text-shadow:#eee 0 1px 0; -moz-box-shadow:0 1px 1px #fff, 0 1px 1px #fff inset; -webkit-box-shadow:0 1px 1px #fff, 0 1px 1px #fff inset; }
@@ -105,6 +110,7 @@ tbody tr:hover, tr:active { background-color:#f8f8f8; }
#body-settings .personalblock, #body-settings .helpblock { padding:.5em 1em; margin:1em; background:#f8f8f8; color:#555; text-shadow:#fff 0 1px 0; -moz-border-radius:.5em; -webkit-border-radius:.5em; border-radius:.5em; }
#body-settings .personalblock#quota { position:relative; margin-top:4.5em; padding:0; }
#body-settings #controls+.helpblock { position:relative; margin-top:7.3em; }
+.personalblock > legend { margin-top:2em; }
#quota div, div.jp-play-bar, div.jp-seek-bar { padding:0; background:#e6e6e6; font-weight:normal; white-space:nowrap; -moz-border-radius-bottomleft:.4em; -webkit-border-bottom-left-radius:.4em; border-bottom-left-radius:.4em; -moz-border-radius-topleft:.4em; -webkit-border-top-left-radius:.4em; border-top-left-radius:.4em; }
#quotatext {padding: .6em 1em;}
diff --git a/core/js/jquery.infieldlabel.min.js b/core/js/jquery.infieldlabel.min.js
new file mode 100755
index 00000000000..8f0ab9f7c5e
--- /dev/null
+++ b/core/js/jquery.infieldlabel.min.js
@@ -0,0 +1,12 @@
+/*
+ * In-Field Label jQuery Plugin
+ * http://fuelyourcoding.com/scripts/infield.html
+ *
+ * Copyright (c) 2009 Doug Neiner
+ * Dual licensed under the MIT and GPL licenses.
+ * Uses the same license as jQuery, see:
+ * http://docs.jquery.com/License
+ *
+ * @version 0.1
+ */
+(function($){$.InFieldLabels=function(b,c,d){var f=this;f.$label=$(b);f.label=b;f.$field=$(c);f.field=c;f.$label.data("InFieldLabels",f);f.showing=true;f.init=function(){f.options=$.extend({},$.InFieldLabels.defaultOptions,d);if(f.$field.val()!=""){f.$label.hide();f.showing=false};f.$field.focus(function(){f.fadeOnFocus()}).blur(function(){f.checkForEmpty(true)}).bind('keydown.infieldlabel',function(e){f.hideOnChange(e)}).change(function(e){f.checkForEmpty()}).bind('onPropertyChange',function(){f.checkForEmpty()})};f.fadeOnFocus=function(){if(f.showing){f.setOpacity(f.options.fadeOpacity)}};f.setOpacity=function(a){f.$label.stop().animate({opacity:a},f.options.fadeDuration);f.showing=(a>0.0)};f.checkForEmpty=function(a){if(f.$field.val()==""){f.prepForShow();f.setOpacity(a?1.0:f.options.fadeOpacity)}else{f.setOpacity(0.0)}};f.prepForShow=function(e){if(!f.showing){f.$label.css({opacity:0.0}).show();f.$field.bind('keydown.infieldlabel',function(e){f.hideOnChange(e)})}};f.hideOnChange=function(e){if((e.keyCode==16)||(e.keyCode==9))return;if(f.showing){f.$label.hide();f.showing=false};f.$field.unbind('keydown.infieldlabel')};f.init()};$.InFieldLabels.defaultOptions={fadeOpacity:0.5,fadeDuration:300};$.fn.inFieldLabels=function(c){return this.each(function(){var a=$(this).attr('for');if(!a)return;var b=$("input#"+a+"[type='text'],"+"input#"+a+"[type='password'],"+"textarea#"+a);if(b.length==0)return;(new $.InFieldLabels(this,b[0],c))})}})(jQuery); \ No newline at end of file
diff --git a/core/js/js.js b/core/js/js.js
index a75e1d41f60..61a60c52485 100644
--- a/core/js/js.js
+++ b/core/js/js.js
@@ -252,7 +252,7 @@ $(document).ready(function(){
}
$('form.searchbox').submit(function(event){
event.preventDefault();
- })
+ });
$('#searchbox').keyup(function(event){
if(event.keyCode==13){//enter
if(OC.search.currentResult>-1){
@@ -290,6 +290,9 @@ $(document).ready(function(){
// 'show password' checkbox
$('#pass2').showPassword();
+ //use infield labels
+ $("label.infield").inFieldLabels();
+
// hide log in button etc. when form fields not filled
$('#submit').hide();
$('#remember_login').hide();
@@ -301,14 +304,13 @@ $(document).ready(function(){
empty = true;
}
});
-
if(empty) {
$('#submit').fadeOut();
- $('#remember_login').fadeOut();
+ $('#remember_login').hide();
$('#remember_login+label').fadeOut();
} else {
$('#submit').fadeIn();
- $('#remember_login').fadeIn();
+ $('#remember_login').show();
$('#remember_login+label').fadeIn();
}
});
@@ -320,7 +322,7 @@ $(document).ready(function(){
});
$('#settings #expanddiv').click(function(event){
event.stopPropagation();
- })
+ });
$('#settings #expand').hover(function(){
$('#settings #expand+span').fadeToggle();
});
diff --git a/core/js/multiselect.js b/core/js/multiselect.js
index 559cdf9b167..26380824047 100644
--- a/core/js/multiselect.js
+++ b/core/js/multiselect.js
@@ -43,25 +43,25 @@
});
button.addClass('active');
event.stopPropagation();
- var options=$(this).parent().next().children().map(function(){return $(this).val()});
+ var options=$(this).parent().next().children().map(function(){return $(this).val();});
var list=$('<ul class="multiselectoptions"/>').hide().appendTo($(this).parent());
function createItem(item,checked){
var id='ms'+multiSelectId+'-option-'+item;
var input=$('<input id="'+id+'" type="checkbox"/>');
var label=$('<label for="'+id+'">'+item+'</label>');
if(settings.checked.indexOf(item)!=-1 || checked){
- input.attr('checked','checked');
+ input.attr('checked',true);
}
if(checked){
settings.checked.push(item);
}
input.change(function(){
var groupname=$(this).next().text();
- if($(this).attr('checked')){
+ if($(this).is(':checked')){
settings.checked.push(groupname);
if(settings.oncheck){
if(settings.oncheck(groupname)===false){
- $(this).removeAttr('checked');
+ $(this).attr('checked', false);
return;
}
}
@@ -70,7 +70,7 @@
settings.checked.splice(index,1);
if(settings.onuncheck){
if(settings.onuncheck(groupname)===false){
- $(this).attr('checked','checked');
+ $(this).attr('checked',true);
return;
}
}
@@ -81,7 +81,7 @@
}else{
button.children('span').first().text(settings.title);
}
- var newOuterWidth=Math.max((button.outerWidth()-2),settings.minOuterWidth)+'px'
+ var newOuterWidth=Math.max((button.outerWidth()-2),settings.minOuterWidth)+'px';
var newWidth=Math.max(button.width(),settings.minWidth);
button.css('height',button.height());
button.css('white-space','nowrap');
diff --git a/core/js/setup.js b/core/js/setup.js
index 0ed0ea69120..b765d41ba35 100644
--- a/core/js/setup.js
+++ b/core/js/setup.js
@@ -1,8 +1,8 @@
$(document).ready(function() {
$('#selectDbType').buttonset();
- $('#datadirField').hide(250);
+ $('#datadirContent').hide(250);
+ $('#databaseField').hide(250);
if($('#hasSQLite').val()=='true'){
- $('#databaseField').hide();
$('#use_other_db').hide();
$('#dbhost').hide();
$('#dbhostlabel').hide();
@@ -26,11 +26,11 @@ $(document).ready(function() {
$('#dbhostlabel').show(250);
});
+ $('input[checked]').trigger('click');
+
$('#showAdvanced').click(function() {
- $('#datadirField').slideToggle(250);
- if($('#hasSQLite').val()=='true'){
- $('#databaseField').slideToggle(250);
- }
+ $('#datadirContent').slideToggle(250);
+ $('#databaseField').slideToggle(250);
});
$("form").submit(function(){
// Save form parameters
diff --git a/core/lostpassword/index.php b/core/lostpassword/index.php
new file mode 100644
index 00000000000..de0d393ec78
--- /dev/null
+++ b/core/lostpassword/index.php
@@ -0,0 +1,32 @@
+<?php
+/**
+ * Copyright (c) 2010 Frank Karlitschek karlitschek@kde.org
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+*/
+
+$RUNTIME_NOAPPS = TRUE; //no apps
+require_once('../../lib/base.php');
+
+// Someone lost their password:
+if (isset($_POST['user'])) {
+ if (OC_User::userExists($_POST['user'])) {
+ $token = sha1($_POST['user']+uniqId());
+ OC_Preferences::setValue($_POST['user'], 'owncloud', 'lostpassword', $token);
+ $email = OC_Preferences::getValue($_POST['user'], 'lostpassword', 'email', '');
+ if (!empty($email)) {
+ $link = OC_Helper::linkTo('core/lostpassword', 'resetpassword.php', null, true).'?user='.$_POST['user'].'&token='.$token;
+ $tmpl = new OC_Template('core/lostpassword', 'email');
+ $tmpl->assign('link', $link);
+ $msg = $tmpl->fetchPage();
+ $l = new OC_L10N('core');
+ mail($email, $l->t('Owncloud password reset'), $msg);
+ }
+ OC_Template::printGuestPage('core/lostpassword', 'lostpassword', array('error' => false, 'requested' => true));
+ } else {
+ OC_Template::printGuestPage('core/lostpassword', 'lostpassword', array('error' => true, 'requested' => false));
+ }
+} else {
+ OC_Template::printGuestPage('core/lostpassword', 'lostpassword', array('error' => false, 'requested' => false));
+}
diff --git a/core/lostpassword/resetpassword.php b/core/lostpassword/resetpassword.php
new file mode 100644
index 00000000000..1c78d720947
--- /dev/null
+++ b/core/lostpassword/resetpassword.php
@@ -0,0 +1,27 @@
+<?php
+/**
+ * Copyright (c) 2010 Frank Karlitschek karlitschek@kde.org
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+*/
+
+$RUNTIME_NOAPPS = TRUE; //no apps
+require_once('../../lib/base.php');
+
+// Someone wants to reset their password:
+if(isset($_GET['token']) && isset($_GET['user']) && OC_Preferences::getValue($_GET['user'], 'owncloud', 'lostpassword') === $_GET['token']) {
+ if (isset($_POST['password'])) {
+ if (OC_User::setPassword($_GET['user'], $_POST['password'])) {
+ OC_Preferences::deleteKey($_GET['user'], 'owncloud', 'lostpassword');
+ OC_Template::printGuestPage('core/lostpassword', 'resetpassword', array('success' => true));
+ } else {
+ OC_Template::printGuestPage('core/lostpassword', 'resetpassword', array('success' => false));
+ }
+ } else {
+ OC_Template::printGuestPage('core/lostpassword', 'resetpassword', array('success' => false));
+ }
+} else {
+ // Someone lost their password
+ OC_Template::printGuestPage('core/lostpassword', 'lostpassword', array('error' => false, 'requested' => false));
+}
diff --git a/core/lostpassword/templates/email.php b/core/lostpassword/templates/email.php
new file mode 100644
index 00000000000..d146d8e4c37
--- /dev/null
+++ b/core/lostpassword/templates/email.php
@@ -0,0 +1 @@
+<?php echo str_replace('{link}', $_['link'], $l->t('Use the following link to reset your password: {link}')) ?>
diff --git a/core/templates/lostpassword.php b/core/lostpassword/templates/lostpassword.php
index 67e34164d08..4b871963b80 100644
--- a/core/templates/lostpassword.php
+++ b/core/lostpassword/templates/lostpassword.php
@@ -1,4 +1,4 @@
-<form action="index.php?lostpassword" method="post">
+<form action="index.php" method="post">
<fieldset>
<?php echo $l->t('You will receive a link to reset your password via Email.'); ?>
<?php if ($_['requested']): ?>
@@ -7,8 +7,11 @@
<?php if ($_['error']): ?>
<?php echo $l->t('Login failed!'); ?>
<?php endif; ?>
- <input type="text" name="user" id="user" placeholder="<?php echo $l->t('Username or Email'); ?>" value="" autocomplete="off" required autofocus />
+ <p class="infield">
+ <label for="user" class="infield"><?php echo $l->t( 'Username' ); ?></label>
+ <input type="text" name="user" id="user" value="" autocomplete="off" required autofocus />
+ </p>
<input type="submit" id="submit" value="<?php echo $l->t('Request reset'); ?>" />
<?php endif; ?>
</fieldset>
-</form> \ No newline at end of file
+</form>
diff --git a/core/lostpassword/templates/resetpassword.php b/core/lostpassword/templates/resetpassword.php
new file mode 100644
index 00000000000..56257de7f13
--- /dev/null
+++ b/core/lostpassword/templates/resetpassword.php
@@ -0,0 +1,14 @@
+<form action="<?php echo 'resetpassword.php?'.$_SERVER['QUERY_STRING']; ?>" method="post">
+ <fieldset>
+ <?php if($_['success']): ?>
+ <h1><?php echo $l->t('Your password was reset'); ?></h1>
+ <p><a href="<?php echo OC::$WEBROOT ?>/"><?php echo $l->t('To login page'); ?></a></p>
+ <?php else: ?>
+ <p class="infield">
+ <label for="password" class="infield"><?php echo $l->t( 'New password' ); ?></label>
+ <input type="password" name="password" id="password" value="" required />
+ </p>
+ <input type="submit" id="submit" value="<?php echo $l->t('Reset password'); ?>" />
+ <?php endif; ?>
+ </fieldset>
+</form>
diff --git a/core/templates/installation.php b/core/templates/installation.php
index 09f9ad8c359..70a545d66cf 100644
--- a/core/templates/installation.php
+++ b/core/templates/installation.php
@@ -18,21 +18,35 @@
<fieldset>
<legend><?php echo $l->t( 'Create an <strong>admin account</strong>' ); ?></legend>
- <input type="text" name="adminlogin" id="adminlogin" value="<?php print OC_Helper::init_var('adminlogin'); ?>" placeholder="<?php echo $l->t( 'Username' ); ?>" autocomplete="off" autofocus required />
- <input type="password" name="adminpass" id="adminpass" value="<?php print OC_Helper::init_var('adminpass'); ?>" placeholder="<?php echo $l->t( 'Password' ); ?>" required />
+ <p class="infield">
+ <label for="adminlogin" class="infield"><?php echo $l->t( 'Username' ); ?></label>
+ <input type="text" name="adminlogin" id="adminlogin" value="<?php print OC_Helper::init_var('adminlogin'); ?>" autocomplete="off" autofocus required />
+ </p>
+ <p class="infield">
+ <label for="adminpass" class="infield"><?php echo $l->t( 'Password' ); ?></label>
+ <input type="password" name="adminpass" id="adminpass" value="<?php print OC_Helper::init_var('adminpass'); ?>" required />
+ </p>
</fieldset>
-
+
+ <fieldset id="datadirField">
+ <legend><a id="showAdvanced"><?php echo $l->t( 'Advanced' ); ?> ▾</a></legend>
+ <div id="datadirContent">
+ <label for="directory"><?php echo $l->t( 'Data folder' ); ?>:</label><br/>
+ <input type="text" name="directory" id="directory" value="<?php print OC_Helper::init_var('directory', $_['directory']); ?>" />
+ </div>
+ </fieldset>
+
<fieldset id='databaseField'>
<?php if($_['hasMySQL'] or $_['hasPostgreSQL']) $hasOtherDB = true; //other than SQLite ?>
<legend><?php echo $l->t( 'Configure the database' ); ?></legend>
<div id="selectDbType">
<?php if($_['hasSQLite']): ?>
- <input type='hidden' id='hasSQLite' value='true' />
+ <input type='hidden' id='hasSQLite' value="true" />
<?php if(!$hasOtherDB): ?>
<p>SQLite <?php echo $l->t( 'will be used' ); ?>.</p>
<input type="hidden" id="dbtype" name="dbtype" value="sqlite" />
<?php else: ?>
- <input type="radio" name="dbtype" value='sqlite' id="sqlite" <?php OC_Helper::init_radio('dbtype', 'sqlite', 'sqlite'); ?>/>
+ <input type="radio" name="dbtype" value="sqlite" id="sqlite" <?php OC_Helper::init_radio('dbtype', 'sqlite', 'sqlite'); ?>/>
<label class="sqlite" for="sqlite">SQLite</label>
<?php endif; ?>
<?php endif; ?>
@@ -43,7 +57,7 @@
<p>MySQL <?php echo $l->t( 'will be used' ); ?>.</p>
<input type="hidden" id="dbtype" name="dbtype" value="mysql" />
<?php else: ?>
- <input type="radio" name="dbtype" value='mysql' id="mysql" <?php OC_Helper::init_radio('dbtype','pgsql', 'mysql', 'sqlite'); ?>/>
+ <input type="radio" name="dbtype" value="mysql" id="mysql" <?php OC_Helper::init_radio('dbtype','mysql', 'sqlite'); ?>/>
<label class="mysql" for="mysql">MySQL</label>
<?php endif; ?>
<?php endif; ?>
@@ -54,27 +68,32 @@
<input type="hidden" id="dbtype" name="dbtype" value="pgsql" />
<?php else: ?>
<label class="pgsql" for="pgsql">PostgreSQL</label>
- <input type="radio" name="dbtype" value='pgsql' id="pgsql" <?php OC_Helper::init_radio('dbtype','pgsql', 'mysql', 'sqlite'); ?>/>
+ <input type="radio" name="dbtype" value='pgsql' id="pgsql" <?php OC_Helper::init_radio('dbtype','pgsql', 'sqlite'); ?>/>
<?php endif; ?>
<?php endif; ?>
</div>
<?php if($hasOtherDB): ?>
<div id="use_other_db">
- <input type="text" name="dbuser" id="dbuser" value="<?php print OC_Helper::init_var('dbuser'); ?>" placeholder="<?php echo $l->t( 'Database user' ); ?>" autocomplete="off" />
- <input type="password" name="dbpass" id="dbpass" value="<?php print OC_Helper::init_var('dbpass'); ?>" placeholder="<?php echo $l->t( 'Database password' ); ?>" />
- <input type="text" name="dbname" id="dbname" value="<?php print OC_Helper::init_var('dbname'); ?>" placeholder="<?php echo $l->t( 'Database name' ); ?>" autocomplete="off" />
+ <p class="infield">
+ <label for="dbuser" class="infield"><?php echo $l->t( 'Database user' ); ?></label>
+ <input type="text" name="dbuser" id="dbuser" value="<?php print OC_Helper::init_var('dbuser'); ?>" autocomplete="off" />
+ </p>
+ <p class="infield">
+ <label for="dbpass" class="infield"><?php echo $l->t( 'Database password' ); ?></label>
+ <input type="password" name="dbpass" id="dbpass" value="<?php print OC_Helper::init_var('dbpass'); ?>" />
+ </p>
+ <p class="infield">
+ <label for="dbname" class="infield"><?php echo $l->t( 'Database name' ); ?></label>
+ <input type="text" name="dbname" id="dbname" value="<?php print OC_Helper::init_var('dbname'); ?>" autocomplete="off" />
+ </p>
</div>
<?php endif; ?>
-
- </fieldset>
-
- <a id='showAdvanced'><strong><?php echo $l->t( 'Advanced' ); ?> ▾</strong></a>
-
- <fieldset id='datadirField'>
- <label id="dbhostlabel" for="dbhost"><?php echo $l->t( 'Database host' ); ?></label><input type="text" name="dbhost" id="dbhost" value="<?php print OC_Helper::init_var('dbhost', 'localhost'); ?>" placeholder="<?php echo $l->t( 'Database host' ); ?>" />
- <label id="directorylabel" for="directory"><?php echo $l->t( 'Data folder' ); ?></label><input type="text" name="directory" id="directory" value="<?php print OC_Helper::init_var('directory', $_['directory']); ?>" placeholder="<?php echo $l->t( 'Data folder' ); ?>" />
+ <p class="infield">
+ <label for="dbhost" class="infield"><?php echo $l->t( 'Database host' ); ?></label>
+ <input type="text" name="dbhost" id="dbhost" value="<?php print OC_Helper::init_var('dbhost', 'localhost'); ?>" />
+ </p>
</fieldset>
- <input type="submit" value="<?php echo $l->t( 'Finish setup' ); ?>" />
+ <div class="buttons"><input type="submit" value="<?php echo $l->t( 'Finish setup' ); ?>" /></div>
</form>
diff --git a/core/templates/layout.guest.php b/core/templates/layout.guest.php
index 7e05fce0ecf..96f3d2662fb 100644
--- a/core/templates/layout.guest.php
+++ b/core/templates/layout.guest.php
@@ -32,6 +32,6 @@
</div></header>
<?php echo $_['content']; ?>
</div>
- <footer><p class="info"><a href="http://owncloud.org/">ownCloud</a> <?php echo $l->t( 'gives you freedom and control over your own data' ); ?></p></footer>
+ <footer><p class="info"><a href="http://owncloud.org/">ownCloud</a>: <?php echo $l->t( 'web services under your control' ); ?></p></footer>
</body>
</html>
diff --git a/core/templates/login.php b/core/templates/login.php
index 717f6bcabda..aff0afac203 100644
--- a/core/templates/login.php
+++ b/core/templates/login.php
@@ -1,17 +1,17 @@
<form action="index.php" method="post">
<fieldset>
<?php if($_['error']): ?>
- <a href="index.php?lostpassword"><?php echo $l->t('Lost your password?'); ?></a>
+ <a href="./core/lostpassword/"><?php echo $l->t('Lost your password?'); ?></a>
<?php endif; ?>
- <?php if(empty($_["username"])): ?>
- <input type="text" name="user" id="user" placeholder="Username" value="" autocomplete="off" required autofocus />
- <input type="password" name="password" id="password" placeholder="Password" value="" required />
- <input type="checkbox" name="remember_login" id="remember_login" /><label for="remember_login"><?php echo $l->t('remember'); ?></label>
- <?php else: ?>
- <input type="text" name="user" id="user" placeholder="Username" value="<?php echo $_['username']; ?>" autocomplete="off" required >
- <input type="password" name="password" id="password" placeholder="Password" value="" required autofocus />
- <input type="checkbox" name="remember_login" id="remember_login" checked /><label for="remember_login"><?php echo $l->t('remember'); ?></label>
- <?php endif; ?>
- <input type="submit" id="submit" value="Log in" />
+ <p class="infield">
+ <label for="user" class="infield"><?php echo $l->t( 'Username' ); ?></label>
+ <input type="text" name="user" id="user" value="<?php echo !empty($_POST['user'])?$_POST['user'].'"':'" autofocus'; ?> autocomplete="off" required />
+ </p>
+ <p class="infield">
+ <label for="password" class="infield"><?php echo $l->t( 'Password' ); ?></label>
+ <input type="password" name="password" id="password" value="" required <?php echo !empty($_POST['user'])?'autofocus':''; ?> />
+ </p>
+ <input type="checkbox" name="remember_login" value="1" id="remember_login" /><label for="remember_login"><?php echo $l->t('remember'); ?></label>
+ <input type="submit" id="submit" class="login" value="<?php echo $l->t( 'Log in' ); ?>" />
</fieldset>
</form>
diff --git a/core/templates/resetpassword.php b/core/templates/resetpassword.php
deleted file mode 100644
index 2f43a93cfb5..00000000000
--- a/core/templates/resetpassword.php
+++ /dev/null
@@ -1,10 +0,0 @@
-<form action="<?php echo 'index.php?'.$_SERVER['QUERY_STRING']; ?>" method="post">
- <fieldset>
- <?php if($_['success']): ?>
- <?php echo $l->t('Your password was reset'); ?>
- <?php else: ?>
- <input type="password" name="password" id="password" placeholder="<?php echo $l->t('New password'); ?>" value="" required />
- <input type="submit" id="submit" value="<?php echo $l->t('Reset password'); ?>" />
- <?php endif; ?>
- </fieldset>
-</form>