This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php $feat_image = wp_get_attachment_url( get_post_thumbnail_id($post->ID) ); ?> | |
| <div style="background-image: url(<?php echo $feat_image; ?>);"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // <h2 class="pagetitle">Search Results</h2> | |
| // search.php | |
| <h2 class="pagetitle">Search Result for <?php /* Search Count */ $allsearch = &new WP_Query("s=$s&showposts=-1"); $key = wp_specialchars($s, 1); $count = $allsearch->post_count; _e(''); _e('<span class="search-terms">'); echo $key; _e('</span>'); _e(' — '); echo $count . ' '; _e('articles'); wp_reset_query(); ?></h2> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <form role="search" method="get" id="searchform" action="<?php bloginfo('siteurl'); ?>"> | |
| <div> | |
| <label for="s">Search by:</label> | |
| <input type="text" value="" name="s" id="s" /> | |
| in <?php wp_dropdown_categories( 'show_option_all=All Categories' ); ?> | |
| <input type="submit" id="searchsubmit" value="Search" /> | |
| </div> | |
| </form> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $(document).click(function(e){ | |
| if ($(e.target).parents('.el').length === 0) { | |
| $('.el').fadeOut(); | |
| } | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php get_header(); ?> | |
| <?php | |
| query_posts('post_type=page'); | |
| while(have_posts() ) : the_post(); | |
| endwhile; | |
| ?> | |
| <?php | |
| $className = 'section1'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //add_filter( 'media_send_to_editor', 'inserted_image_titles', 15, 2 ); | |
| function featured_image_titles($attr, $attachment = null){ | |
| $attr['title'] = get_post($attachment->ID)->post_title; | |
| return $attr; | |
| } | |
| add_filter('wp_get_attachment_image_attributes', 'featured_image_titles', 10, 2); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $('.el').each(function() { | |
| var string = $(this).html(); | |
| $(this).html(string.replace(/,/g , ', ')); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*! normalize.css 2012-02-07T12:37 UTC - http://github.com/necolas/normalize.css */article,aside,details,figcaption,figure,footer,header,hgroup,nav,section,summary{display:block}audio,canvas,video{display:inline-block;*display:inline;*zoom:1}audio:not([controls]){display:none}[hidden]{display:none}html{font-size:100%;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}html,button,input,select,textarea{font-family:sans-serif}body{margin:0}a:focus{outline:thin dotted}a:hover,a:active{outline:0}h1{font-size:2em;margin:.67em 0}h2{font-size:1.5em;margin:.83em 0}h3{font-size:1.17em;margin:1em 0}h4{font-size:1em;margin:1.33em 0}h5{font-size:.83em;margin:1.67em 0}h6{font-size:.75em;margin:2.33em 0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:bold}blockquote{margin:1em 40px}dfn{font-style:italic}mark{background:#ff0;color:#000}p,pre{margin:1em 0}pre,code,kbd,samp{font-family:monospace,serif;_font-family:'courier new',monospace;font-size:1em}pre{white-space:pre;white-space:pre-wrap;word-wrap:break-word |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # The following will allow you to use URLs such as the following: | |
| # | |
| # example.com/link | |
| # example.com/link/ | |
| # | |
| # Which will actually serve files such as the following: | |
| # | |
| # example.com/link.html | |
| # example.com/link.php | |
| # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var zoomOri = document.documentElement.clientWidth / window.innerWidth; | |
| var zoomCurrent = zoomOri; | |
| $(window).resize(function() { | |
| var zoomNew = document.documentElement.clientWidth / window.innerWidth; | |
| if (zoomOri != zoomNew && zoomNew != zoomCurrent) { | |
| $('.yourclass').hide(); | |
| } else if (zoomOri == zoomNew && zoomNew != zoomCurrent) { | |
| $('.yourclass').show(); | |
| } | |
| zoomCurrent = zoomNew |