Browse Source

Added Styles for comments and working on Dropdowns.

Comments still need some fine tuning, Dropdowns are still a problem :c
Also added execution time to index.php for testing purposes.
master
Kondou 8 years ago
parent
commit
47043cd17e
3 changed files with 88 additions and 30 deletions
  1. +2
    -2
      comments.php
  2. +13
    -0
      index.php
  3. +73
    -28
      style.css

+ 2
- 2
comments.php View File

@ -2,7 +2,7 @@
<div id="comments">
<?php if (have_comments()) : ?>
<h3>Comments</h3>
<ol class="commentlist"><?php wp_list_comments(array('style' => 'ol')); ?></ol>
<ol class="commentlist"><?php wp_list_comments(array('avatar_size' => 48, 'style' => 'ol')); ?></ol>
<?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : ?>
<nav id="comments">
<h3>Comment navigation</h1>
@ -12,5 +12,5 @@
<?php
endif;
endif;
comment_form(); ?>
comment_form(array('comment_notes_after' => '',)); ?>
</div>

+ 13
- 0
index.php View File

@ -1,6 +1,12 @@
<?php
$mtime = explode(" ", microtime());
$mtime = $mtime[1] + $mtime[0];
$starttime = $mtime;
?>
<?php
get_header();
?>
<?php if(preg_match('/(?i)msie [4-8]/',$_SERVER['HTTP_USER_AGENT'])) echo '<h1 style="color: #070; text-align:center; font-size: 90px;">&gt;Internet Explorer</h1>';?>
<div id="primary">
<?php if (have_posts()) : ?>
<?php while (have_posts()) : ?>
@ -26,3 +32,10 @@ endif;
get_sidebar();
get_footer();
?>
<?php
$mtime = explode(" ", microtime());
$mtime = $mtime[1] + $mtime[0];
$endtime = $mtime;
$totaltime = ($endtime - $starttime);
echo "This page was created in " . $totaltime . " seconds.";
?>

+ 73
- 28
style.css View File

@ -138,6 +138,7 @@ nav {
text-transform: uppercase;
text-shadow: #000 1px 1px;
display: block;
position: relative;
}
#main-nav {
@ -158,6 +159,7 @@ nav {
border-top-left-radius: 10px;
border-top-right-radius: 10px;
height: 45px;
z-index: 8;
}
#sub-nav {
@ -186,32 +188,35 @@ nav {
padding: 9px 10px 8px;
}
/*nav ul li > ul {
display: block;
visibility: hidden;
nav ul li > ul {
/*display: block;*/
opacity: 0;
-webkit-transition: height 2s;
-moz-transition: height 2s;
-o-transition: height 2s;
-webkit-transition-delay: 0.2s;
-moz-transition-delay: 0.2s;
-o-transition-delay: 0.2s;
}*/
background: #f5f5f5;
margin: 0;
padding: 0;
visibility: hidden;
-webkit-transition: opacity .25s;
-moz-transition: opacity .25s;
-o-transition: opacity .25s;
}
nav ul li:hover > ul {
opacity: 1;
visibility: visible;
}
nav ul {
list-style: none;
/*display: inline-table;*/
margin: 0 0 0 10px;
padding: 0 0 0 0;
}
nav ul li {
float: left;
display: block;
position: relative;
}
nav ul li a:hover {
/*opcaity: 1;*/
background: #eee;
color: #333;
text-shadow: none;
@ -222,16 +227,6 @@ nav ul li a {
padding: 13px 22px 12px 20px;
color: #fff;
text-decoration: none;
/*-webkit-transition: opacity 1s;
-moz-transition: opacity 1s;
-o-transition: opacity 1s;*/
}
nav ul ul {
background: #f5f5f5;
margin: 0;
padding: 0;
display: block;
}
nav ul ul li {
@ -248,15 +243,11 @@ nav ul ul li a {
padding: 6px 50px 6px 15px;
}
nav ul ul li a:hover {
background: #fff;
}
/*
nav ul ul ul {
position: absolute;
left: 100%;
top:0;
}*/
}
#secondary {
display: inline;
@ -334,3 +325,57 @@ footer {
.sub-menu {
z-index: 9;
}
#comments, #respond {
font-size: 13px;
line-height: 20px;
margin: 0 0 15px;
overflow: hidden;
}
.commentlist, .children{
list-style-type: none;
padding: 0;
}
.commentlist li, .ping-list li {
font-weight: bold;
margin: 15px 0 5px;
padding: 10px 5px 10px 10px;
}
.commentlist li .avatar {
border: 4px solid #e5e5e5;
float: right;
margin: 0 5px 0 10px;
}
.commentlist li ol li {
margin-left: 10px;
margin-right: -6px;
}
.thread-alt, .thread-even {
background-color: #f5f5f5;
}
#comment, #author, #email, #url {
font-size: 12px;
margin: 10px 5px 0 0;
padding: 5px;
width: 250px;
}
#comment {
margin: 10px 0;
height: 150px;
width: 98%;
}
.alt, .depth-1, .even {
-khtml-border-radius: 3px;
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
border-radius: 3px;
border: 1px solid #ddd;
}