Advertisement
Guest User

Bill

a guest
May 28th, 2010
275
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.04 KB | None | 0 0
  1. //search box in navigation
  2.  
  3. //remove thesis navigation
  4.  
  5. remove_action('thesis_hook_before_header', 'thesis_nav_menu');
  6.  
  7. //custom Nav
  8.  
  9. function custom_nav() {
  10.  
  11. echo '<div id="nav">';
  12.  
  13. echo '<div class="nav_container">';
  14.  
  15. thesis_nav_menu(); //this is default navigation
  16.  
  17. echo '<div class="search">';
  18.  
  19. thesis_search_form(); // add thesis search box
  20.  
  21. echo '</div>';
  22.  
  23. echo '</div>';
  24.  
  25. echo '</div>';
  26.  
  27. }
  28.  
  29.  
  30. remove_action('thesis_hook_footer', 'thesis_attribution');
  31.  
  32.  
  33. ?>
  34. <div align="left">
  35. <?php if(function_exists('wp_pagenavi')) { wp_pagenavi(); } ?>
  36. <br />
  37. </div>
  38. <?php
  39. }
  40. add_action('thesis_hook_after_content','pagenavi');
  41.  
  42.  
  43.  
  44.  
  45. /* SAVE THIS IN CUSTOM_FUNCTIONS.PHP FILE */
  46. if ( function_exists('register_sidebar') )
  47. register_sidebar(array(
  48. 'name'=>'Media Box',
  49. 'before_widget' => '<li class="widget %2$s">',
  50. 'after_widget' => '</li>',
  51. 'before_title' => '<h3>',
  52. 'after_title' => '</h3>'));
  53.  
  54. function mediabox_widget() {
  55. echo '<ul class="sidebar_list">';
  56. if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Media Box') ) :
  57. echo '</ul>';
  58.  
  59. endif;
  60. }
  61. add_action('thesis_hook_multimedia_box', 'mediabox_widget');
  62.  
  63. remove_action('thesis_hook_archives_template', 'thesis_archives_template');
  64. add_action('thesis_hook_after_post', 'custom_sitemap');
  65.  
  66.  
  67. /* SITEMAP AND ARCHIVES PAGES */
  68. function custom_sitemap() {
  69. if (is_page('sitemap')) { ?>
  70. <div>
  71. <div class="sitemapl">
  72. <h3>Pages:</h3>
  73. <ul>
  74. <?php wp_list_pages('title_li='); ?>
  75. </ul>
  76. <h3>By Month:</h3>
  77. <ul>
  78. <?php wp_get_archives('type=monthly'); ?>
  79. </ul>
  80. <h3>By Category:</h3>
  81. <ul>
  82. <?php wp_list_categories('sort_column=name&title_li='); ?>
  83. </ul>
  84. </div>
  85. <div class="sitemapr">
  86. <h3>Last 50 posts:</h3>
  87. <ul>
  88. <?php wp_get_archives('type=postbypost&limit=50'); ?>
  89. </ul>
  90. </div>
  91. </div>
  92. <?php } }
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99. function archive_read_more() {
  100. if (is_archive()) { ?>
  101. <p><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title(); ?>">Read the full article...</a></p>
  102. <?php }
  103. }
  104.  
  105. add_action('thesis_hook_after_post', 'archive_read_more');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement