Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
our_own_cloud_project
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
die_coolen_jungs
our_own_cloud_project
Commits
c7d5e671
Commit
c7d5e671
authored
14 years ago
by
Jan-Christoph Borchardt
Browse files
Options
Downloads
Patches
Plain Diff
jQuery-value-hide-foo for the installation form as well
parent
ecd68e0c
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
js/js.js
+19
-15
19 additions, 15 deletions
js/js.js
templates/installation.php
+15
-15
15 additions, 15 deletions
templates/installation.php
with
34 additions
and
30 deletions
js/js.js
+
19
−
15
View file @
c7d5e671
...
...
@@ -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
);
});
});
This diff is collapsed.
Click to expand it.
templates/installation.php
+
15
−
15
View file @
c7d5e671
<div
id=
"login"
>
<img
src=
"
<?php
echo
image_path
(
""
,
"
owncloud-logo-medium-white.png
"
);
?>
"
alt=
"ownCloud"
/>
<img
src=
"
<?php
echo
image_path
(
''
,
'
owncloud-logo-medium-white.png
'
);
?>
"
alt=
"ownCloud"
/>
<form
action=
"#"
method=
"post"
>
<input
type=
'hidden'
name=
'install'
value=
'true'
/>
<fieldset>
<input
type=
"text"
name=
"login"
value=
"admin username"
/>
<input
type=
"password"
name=
"pass"
value=
"password"
/>
<input
type=
"text"
name=
"login"
id=
"admin"
value=
"admin username"
/>
<input
type=
"password"
name=
"pass"
id=
"password"
value=
"password"
/>
</fieldset>
<fieldset>
<?php
if
(
!
$_
[
'hasSQLite'
])
:
?>
<legend><abbr
title=
"to use SQLite instead, install it on your server"
>
MySQL
</abbr>
Database
</legend>
<input
type=
"text"
name=
"dbuser"
value=
"MySQL user"
/>
<input
type=
"password"
name=
"dbpass"
value=
"password"
/>
<input
type=
"text"
name=
"dbname"
value=
"database name"
/>
<input
type=
"text"
name=
"dbuser"
id=
"dbuser"
value=
"MySQL user"
/>
<input
type=
"password"
name=
"dbpass"
id=
"dbpass"
value=
"password"
/>
<input
type=
"text"
name=
"dbname"
id=
"dbname"
value=
"database name"
/>
<?php
endif
;
?>
</fieldset>
<fieldset
id=
"advanced"
>
...
...
@@ -22,24 +22,24 @@
<input
type=
"radio"
name=
"dbtype"
value=
'sqlite'
id=
"sqlite"
checked=
"checked"
/><label
class=
"sqlite"
for=
"sqlite"
>
SQLite
</label>
<input
type=
"radio"
name=
"dbtype"
value=
'mysql'
id=
"mysql"
><label
class=
"mysql"
for=
"mysql"
>
MySQL
</label>
<div
id=
"use_mysql"
>
<input
type=
"text"
name=
"dbuser"
value=
"MySQL user"
/>
<input
type=
"password"
name=
"dbpass"
value=
"password"
/>
<input
type=
"text"
name=
"dbname"
value=
"database name"
/>
<input
type=
"text"
name=
"dbuser"
id=
"dbuser"
value=
"MySQL user"
/>
<input
type=
"password"
name=
"dbpass"
id=
"dbpass"
value=
"password"
/>
<input
type=
"text"
name=
"dbname"
id=
"dbname"
value=
"database name"
/>
<?php
endif
;
?>
<?php
if
(
$_
[
'hasMySQL'
]
and
!
$_
[
'hasSQLite'
])
:
?>
<input
type=
'
hidden
'
name=
'
dbtype
'
value=
'
mysql
'
/>
<input
type=
"
hidden
"
name=
"
dbtype
"
value=
"
mysql
"
/>
<?php
endif
;
?>
<?php
if
(
!
$_
[
'hasMySQL'
]
and
$_
[
'hasSQLite'
])
:
?>
<input
type=
'
hidden
'
name=
'
dbtype
'
value=
'
sqlite
'
/>
<input
type=
"
hidden
"
name=
"
dbtype
"
value=
"
sqlite
"
/>
<?php
endif
;
?>
<?php
if
(
$_
[
'hasMySQL'
]
and
$_
[
'hasSQLite'
])
:
?>
<label
class=
"left"
>
Database host
</label><input
type=
"text"
name=
"dbhost"
value=
"localhost"
/>
<label
class=
"left"
>
Table prefix
</label><input
type=
"text"
name=
"dbtableprefix"
value=
"oc_"
/>
<label
class=
"left"
>
Database host
</label><input
type=
"text"
name=
"dbhost"
id=
"dbhost"
value=
"localhost"
/>
<label
class=
"left"
>
Table prefix
</label><input
type=
"text"
name=
"dbtableprefix"
id=
"dbtableprefix"
value=
"oc_"
/>
</div>
<?php
endif
;
?>
<?php
if
(
$_
[
'hasMySQL'
]
and
!
$_
[
'hasSQLite'
])
:
?>
<label
class=
"left"
>
H
ost
</label><input
type=
"text"
name=
"dbhost"
value=
"localhost"
/>
<label
class=
"left"
>
Table prefix
</label><input
type=
"text"
name=
"dbtableprefix"
value=
"oc_"
/>
<label
class=
"left"
>
Database h
ost
</label><input
type=
"text"
name=
"dbhost"
id=
"dbhost"
value=
"localhost"
/>
<label
class=
"left"
>
Table prefix
</label><input
type=
"text"
name=
"dbtableprefix"
id=
"dbtableprefix"
value=
"oc_"
/>
<?php
endif
;
?>
</div>
</fieldset>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment