diff --git a/front-page.php b/front-page.php index a11e353..d618f58 100755 --- a/front-page.php +++ b/front-page.php @@ -61,8 +61,11 @@ foreach($items as $item) if($query) { $id = strtolower(preg_replace('#[^\w]+#', '', $item->title)); + echo "
"; + if($pre) echo $pre; + query_posts($query); get_template_part( 'loop', $loop); diff --git a/header.php b/header.php index 3a8f4d3..e4cf8fa 100755 --- a/header.php +++ b/header.php @@ -109,20 +109,27 @@ $j(function() var modal_not_match = Array(/wp-admin/); -$j(".content .post [href],#header [href]").live('click',function(e) +$j(".content .post,#header [href]").live('click',function(e) { preModal = window.location.href; + e.preventDefault(); + + if($j(this).attr('href')) + href = this.href; + else + href = $j(this).find("[href]").attr('href'); + for(var i = 0; i < modal_match.length; i++) - if(this.href.match(modal_match[i])) + if(href.match(modal_match[i])) break; if(i == modal_match.length) return; for(var i = 0; i < modal_not_match.length; i++) - if(this.href.match(modal_not_match[i])) + if(href.match(modal_not_match[i])) return; - showUrlModal(this.href); - e.preventDefault(); + showUrlModal(href); + var href = this.href.substr(); window.location = window.location.href.split("#")[0] + "#" + href; });