mirror of https://github.com/BOINC/boinc.git
- Replace nasty javascript generated HTML <input> buttons with normal links and CSS buttons.
- Fix CSS compatibility issues towards IE6-series of browsers - Buttons will now light up when hovering over them with the mouse svn path=/trunk/boinc/; revision=16047
This commit is contained in:
parent
a9d346b20e
commit
ff29445385
|
@ -529,7 +529,7 @@ function show_post(
|
|||
|
||||
$url = "pm.php?action=new&userid=".$user->id;
|
||||
$name = $user->name;
|
||||
show_button($url, "Send message", "Send $name a private message");
|
||||
show_button($url, "Send message", "Send $name a private message");
|
||||
echo "Joined: ", gmdate('M j y', $user->create_time), "<br>";
|
||||
|
||||
if (!isset($user->nposts)) {
|
||||
|
|
|
@ -685,17 +685,8 @@ function current_url() {
|
|||
return $url;
|
||||
}
|
||||
|
||||
function show_button($url, $text, $desc) {
|
||||
$text_esc = addslashes($text); // for javascript
|
||||
$desc_esc = addslashes($desc);
|
||||
echo "
|
||||
<script>
|
||||
document.write('<input onClick=\"document.location.href=\'$url\'\" class=\"btn\" type=\"button\" value=\"$text_esc\" title=\"$desc_esc\">')
|
||||
</script>
|
||||
<noscript>
|
||||
<a href=\"$url\" title=\"$desc\">$text</a>
|
||||
</noscript>
|
||||
";
|
||||
function show_button($url, $text, $desc, $class="button") {
|
||||
echo "<a href=\"".$url."\" title=\"".addslashes($desc)."\" class=\"".$class."\">".$text."</a>";
|
||||
}
|
||||
|
||||
function show_image($src, $title, $alt, $height=null) {
|
||||
|
|
|
@ -121,23 +121,45 @@ td.friend {
|
|||
|
||||
tr.message { background-color: #e0e0e0; }
|
||||
|
||||
input, select, textarea{
|
||||
input, select, textarea, .button {
|
||||
border: 1px solid #d8d8d8;
|
||||
-moz-border-radius: 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
padding: 2px;
|
||||
padding: 2px 4px;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
input[type="button"], input[type="submit"], input.btn {
|
||||
padding: 2px 4px;
|
||||
margin: 2px 0px;
|
||||
background: #d4d0c8;
|
||||
margin-right: 0.5em;
|
||||
color: #203C66;
|
||||
border: 1px solid #a8a8a8;
|
||||
font-size: 12px;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
/* IE6 doesn't understand [type=XXXX] so we factor this out into its own */
|
||||
.button {
|
||||
margin: 2px 0px;
|
||||
background: #d4d0c8;
|
||||
margin-right: 0.5em;
|
||||
color: #203C66;
|
||||
border: 1px solid #a8a8a8;
|
||||
font-size: 0.9em;
|
||||
font-weight: normal;
|
||||
line-height: 2em;
|
||||
}
|
||||
|
||||
.button:hover {
|
||||
background: #edece8;
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
input[type="button"]:hover, input[type="submit"]:hover, input.btn:hover, .forum_toplinks a:hover {
|
||||
background: #edece8;
|
||||
}
|
||||
|
||||
img { border: 0px; }
|
||||
|
||||
img.userimg { border: 0px; }
|
||||
|
@ -285,6 +307,10 @@ blockquote.postbody {
|
|||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.forum_toplinks td {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
span.page_title {
|
||||
font-size: 24px;
|
||||
margin: 20px;
|
||||
|
|
Loading…
Reference in New Issue