summaryrefslogtreecommitdiffstats
path: root/js
diff options
context:
space:
mode:
authorJan-Christoph Borchardt <JanCBorchardt@fsfe.org>2011-04-19 01:17:35 +0200
committerJan-Christoph Borchardt <JanCBorchardt@fsfe.org>2011-04-19 01:18:57 +0200
commitc7d5e671acdcc73a9740a09249634be051c2968c (patch)
treec9769a66022a976d9b48c21454ebcb20bdc98e98 /js
parentecd68e0c6e9a1ef4f77f117c9a564f4c99630bab (diff)
downloadnextcloud-server-c7d5e671acdcc73a9740a09249634be051c2968c.tar.gz
nextcloud-server-c7d5e671acdcc73a9740a09249634be051c2968c.zip
jQuery-value-hide-foo for the installation form as well
Diffstat (limited to 'js')
-rw-r--r--js/js.js34
1 files changed, 19 insertions, 15 deletions
diff --git a/js/js.js b/js/js.js
index b7d94b5eb6a..948c3417381 100644
--- a/js/js.js
+++ b/js/js.js
@@ -23,19 +23,23 @@ $(document).ready(function() {
$('label.mysql').css('background-color', '#fff');
});
- // Hide and show input field values for login form
- var textuser = "username";
- var textpassword = "password";
- $("#user").focus(function() {
- if($(this).attr("value") == textuser) $(this).attr("value", "");
- });
- $("#user").blur(function() {
- if($(this).attr("value") == "") $(this).attr("value", textuser);
- });
- $("#password").focus(function() {
- if($(this).attr("value") == textpassword) $(this).attr("value", "");
- });
- $("#password").blur(function() {
- if($(this).attr("value") == "") $(this).attr("value", textpassword);
- });
+ // Hide and show input field values for login and installation form
+ var textuser = 'username';
+ var textpassword = 'password';
+ var textadmin = 'admin username';
+ var textdbuser = 'MySQL user';
+ var textdbpass = 'password';
+ var textdbname = 'database name';
+ $('#user').focus(function() { if($(this).attr('value') == textuser) $(this).attr('value', ''); });
+ $('#user').blur(function() { if($(this).attr('value') == '') $(this).attr('value', textuser); });
+ $('#password').focus(function() { if($(this).attr('value') == textpassword) $(this).attr('value', ''); });
+ $('#password').blur(function() { if($(this).attr('value') == '') $(this).attr('value', textpassword); });
+ $('#admin').focus(function() { if($(this).attr('value') == textadmin) $(this).attr('value', ''); });
+ $('#admin').blur(function() { if($(this).attr('value') == '') $(this).attr('value', textadmin); });
+ $('#dbuser').focus(function() { if($(this).attr('value') == textdbuser) $(this).attr('value', ''); });
+ $('#dbuser').blur(function() { if($(this).attr('value') == '') $(this).attr('value', textdbuser); });
+ $('#dbpass').focus(function() { if($(this).attr('value') == textdbpass) $(this).attr('value', ''); });
+ $('#dbpass').blur(function() { if($(this).attr('value') == '') $(this).attr('value', textdbpass); });
+ $('#dbname').focus(function() { if($(this).attr('value') == textdbname) $(this).attr('value', ''); });
+ $('#dbname').blur(function() { if($(this).attr('value') == '') $(this).attr('value', textdbname); });
});