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
| http://img.youtube.com/vi/<insert-youtube-video-id-here>/0.jpg | |
| http://img.youtube.com/vi/<insert-youtube-video-id-here>/1.jpg | |
| http://img.youtube.com/vi/<insert-youtube-video-id-here>/2.jpg | |
| http://img.youtube.com/vi/<insert-youtube-video-id-here>/3.jpg | |
| The first one in the list is a full size image and others are thumbnail images. The default thumbnail image (ie. one of 1.jpg, 2.jpg, 3.jpg) is: | |
| http://img.youtube.com/vi/<insert-youtube-video-id-here>/default.jpg | |
| For the high quality version of the thumbnail use a url similar to this: |
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
| jQuery(document).ready(function($){ | |
| $(".post_thumb").click(function(){ | |
| window.location=$(this).find("a").attr("href"); | |
| return false; | |
| }); | |
| }); |
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
| jQuery(document).ready(function($){ | |
| $(window).load(function(){ | |
| var outerHeightTotal = 0; | |
| $('.homeside_1').each(function(){ | |
| outerHeightTotal += $(this).outerHeight(); | |
| }); | |
| var totalH = outerHeightTotal ; | |
| $('.home_wrapper').css('min-height', totalH+'px'); |
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
| /**Next & previous project links**/ | |
| function add_next_project() { | |
| // Next two lines link to project custom post types in same category | |
| ?><div class ="half"><?php echo previous_post_link('%link', '« View the Previous Project', TRUE);?></div><?php | |
| ?><div class="half_right"><?php echo next_post_link('%link', 'View the Next Project »', TRUE);?></div><?php | |
| // Next two lines link to next/previous project CPT without category filter |
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
| /**Infinite next & previous project links**/ | |
| function add_next_project() { | |
| if( get_adjacent_post(false, '', true) ) { | |
| ?><div class ="half"><?php echo previous_post_link('%link', '« View Previous Project');?></div><?php | |
| } | |
| else { |
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
| /**Next & previous post link**/ | |
| function add_next_post() { | |
| ?><div class ="half"><?php echo previous_post_link('%link', '« View the Previous News Item');?></div><?php | |
| ?><div class="half_right"><?php echo next_post_link('%link', 'View the Next News Item »');?></div><?php | |
| } | |
| add_action('hook_bottom_next_post', 'add_next_post'); |
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
| /**Back to Blog page **/ | |
| function add_back_to_blog() { | |
| //get the page id for the page used for blog posts | |
| $index_id = ( int ) get_option( 'page_for_posts', 0 ); | |
| //set a constant with this page's permalink | |
| $blogpage = get_permalink( $index_id ); | |
| //set a constant with this page's title | |
| $blogtitle = get_the_title( $index_id); |
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
| /**Put video embeds in this div for responsive behaviour**/ | |
| .video_wrapper { | |
| position: relative; | |
| padding-bottom: 74.25%; /* for a 4:3 aspect ratio */ | |
| /* change padding-bottom to : 56.25% for 16:9 ratio, 50% for 16:10 ratio */ | |
| padding-top: 30px; | |
| height: 0; | |
| overflow: hidden; | |
| margin-bottom: $MainPad; | |
| } |
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
| jQuery(document).ready(function($) { | |
| // Responsive Menu | |
| // prepend menu icon | |
| $('#nav_wrap').prepend('<div id="menu_icon">Menu</div>'); | |
| // toggle nav | |
| $("#menu_icon").on("click", function(){ | |
| $('#menu-main-menu').fadeToggle(700); |
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 | |
| // Enable following line temporarily after migration | |
| update_option('siteurl','http://www.thenewsiteurl.com/sub');update_option('home','http://www.thenewsiteurl.com/sub'); | |
| ?> |