Skip to content

Commit

Permalink
Fixing
Browse files Browse the repository at this point in the history
  • Loading branch information
beamercola committed Jan 17, 2012
1 parent b7a8d86 commit 26d3c99
Show file tree
Hide file tree
Showing 3 changed files with 138 additions and 28 deletions.
43 changes: 42 additions & 1 deletion css/style.scss
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -416,6 +416,46 @@ ul.leaderboard {
} }
} }


ul.category-leaderboard {
@include no-list;
li {
@include grid($grid_3);
margin-bottom: 1em;
width: 200px;
a.image {
display: block;
height: 150px;
overflow: hidden;
width: 200px;


background-color: #fff;
margin: .5em 0 .75em 0;
@include rounded(5px);
@include glow(#EFE9D8, 5px, 0);
&:hover {
@include glow(#ccc, 5px, 0);
}
img {
width: 200px;
}
}
h2 {
font-size: 12px;
}
h3 {
color: #B0AEA7;
font-size: 12px;
}
&:nth-child(3n) {
clear: right;
}
&:nth-child(3n+1) {
clear: left;
}
}
}



@mixin box { @mixin box {
@include rounded(5px); @include rounded(5px);
Expand Down Expand Up @@ -646,7 +686,8 @@ div#content {
} }
} }


.leaderboard { div.leaderboard {
width: 450px;
.reviews { .reviews {
.bc_review { .bc_review {
border-top: 1px solid #ddd; border-top: 1px solid #ddd;
Expand Down
96 changes: 69 additions & 27 deletions style.css
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -816,6 +816,46 @@ ul.leaderboard {
list-style-type: none !important; list-style-type: none !important;
list-style-image: none !important; } list-style-image: none !important; }


ul.category-leaderboard {
list-style-type: none;
margin: 0;
padding: 0; }
ul.category-leaderboard li {
width: 235px;
display: inline;
float: left;
position: relative;
margin-left: 10px;
margin-right: 10px;
margin-bottom: 1em;
width: 200px; }
ul.category-leaderboard li a.image {
display: block;
height: 150px;
overflow: hidden;
width: 200px;
background-color: #fff;
margin: .5em 0 .75em 0;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
-o-border-radius: 5px;
box-shadow: 0px 0 5px #efe9d8;
-webkit-box-shadow: 0px 0 5px #efe9d8; }
ul.category-leaderboard li a.image:hover {
box-shadow: 0px 0 5px #cccccc;
-webkit-box-shadow: 0px 0 5px #cccccc; }
ul.category-leaderboard li a.image img {
width: 200px; }
ul.category-leaderboard li h2 {
font-size: 12px; }
ul.category-leaderboard li h3 {
color: #B0AEA7;
font-size: 12px; }
ul.category-leaderboard li:nth-child(3n) {
clear: right; }
ul.category-leaderboard li:nth-child(3n+1) {
clear: left; }

.box { .box {
-webkit-border-radius: 5px; -webkit-border-radius: 5px;
-moz-border-radius: 5px; -moz-border-radius: 5px;
Expand Down Expand Up @@ -1014,33 +1054,35 @@ div#content .side {
.specs strong { .specs strong {
display: block; } display: block; }


.leaderboard .reviews .bc_review { div.leaderboard {
border-top: 1px solid #ddd; width: 450px; }
border-bottom: 1px solid #fff; div.leaderboard .reviews .bc_review {
padding: 1.5em 0; } border-top: 1px solid #ddd;
.leaderboard .reviews .bc_review a:hover { border-bottom: 1px solid #fff;
color: #df5341; } padding: 1.5em 0; }
.leaderboard .reviews .bc_review h2 { div.leaderboard .reviews .bc_review a:hover {
margin: 0; } color: #df5341; }
.leaderboard .reviews .bc_review h3 { div.leaderboard .reviews .bc_review h2 {
color: #df5341; margin: 0; }
font-size: 14px; div.leaderboard .reviews .bc_review h3 {
margin: 0; color: #df5341;
padding: 0; } font-size: 14px;
.leaderboard .reviews .bc_review img { margin: 0;
background-color: #fff; padding: 0; }
margin-top: 1em; div.leaderboard .reviews .bc_review img {
-webkit-border-radius: 5px; background-color: #fff;
-moz-border-radius: 5px; margin-top: 1em;
-o-border-radius: 5px; -webkit-border-radius: 5px;
box-shadow: 0px 0 5px #cccccc; -moz-border-radius: 5px;
-webkit-box-shadow: 0px 0 5px #cccccc; -o-border-radius: 5px;
width: 450px; } box-shadow: 0px 0 5px #cccccc;
.leaderboard .reviews .bc_review:first-child { -webkit-box-shadow: 0px 0 5px #cccccc;
border-top-width: 0; width: 450px; }
padding-top: 0; } div.leaderboard .reviews .bc_review:first-child {
.leaderboard .reviews .bc_review:last-of-type { border-top-width: 0;
border-bottom-width: 0 !important; } padding-top: 0; }
div.leaderboard .reviews .bc_review:last-of-type {
border-bottom-width: 0 !important; }


ul.categories { ul.categories {
list-style-type: none; list-style-type: none;
Expand Down
27 changes: 27 additions & 0 deletions taxonomy-bc_leaderboard.php
Original file line number Original file line Diff line number Diff line change
@@ -1,5 +1,32 @@
<?php get_header(); ?> <?php get_header(); ?>


<h1 class="page-title">Leaderboard: <?php single_tag_title() ?></h1>

<ul class="category-leaderboard">
<?php while ( have_posts() ): the_post(); ?>
<li <?php post_class(); ?>>
<?php
$attachments = get_posts(array( 'post_type' => 'attachment', 'numberposts' => -1, 'orderby' => 'menu_order', 'order' => 'asc', 'post_status' => null, 'post_parent' => $post->ID ));
if(count($attachments) > 0) {
$image_attributes = wp_get_attachment_image_src( $attachments[0]->ID, array(450,450)); ?>
<a href="<?php echo the_permalink(); ?>" class="image"><img src="<?php echo $image_attributes[0]; ?>" width="200" /></a>
<?php } else {
echo '<a href="#" class="image"><img src="http://placehold.it/200x150" /></a>';
}
?>
<a href="<?php echo the_permalink(); ?>">
<h2 class="entry-title"><a href="<?php echo the_permalink(); ?>"><?php the_title(); ?></a></h2>
<h3><?php echo get_post_meta($post->ID, $prefix.'sub_title', true);?></h3>
</a>
<div class="entry-content">
<?php echo substr(preg_replace("/Last Updated: .* \d{4}/i", "", get_the_excerpt()), 0, 80) . '...'; ?>
<a href="<?php echo the_permalink(); ?>">more</a>
</div><!-- .entry-content -->
</li><!-- #post -->
<?php endwhile; // end of the loop. ?>
</ul>


<div class="grid_6 leaderboard article alpha"> <div class="grid_6 leaderboard article alpha">
<h1 class="page-title">Leaderboard: <?php single_tag_title() ?></h1> <h1 class="page-title">Leaderboard: <?php single_tag_title() ?></h1>


Expand Down

0 comments on commit 26d3c99

Please sign in to comment.