web/wp-content/themes/thematic/library/extensions/footer-extensions.php
changeset 1 0d28b7c10758
equal deleted inserted replaced
0:0d9a58d2c515 1:0d28b7c10758
       
     1 <?php
       
     2 
       
     3 
       
     4 // Located in footer.php
       
     5 // Just before the footer div
       
     6 function thematic_abovefooter() {
       
     7     do_action('thematic_abovefooter');
       
     8 } // end thematic_abovefooter
       
     9 
       
    10 // Located in footer.php
       
    11 // Just after the footer div
       
    12 function thematic_footer() {
       
    13     do_action('thematic_footer');
       
    14 } // end thematic_footer
       
    15 
       
    16 
       
    17 // located in footer.php
       
    18 // the footer text can now be filtered and controlled from your own functions.php
       
    19 function thematic_footertext($thm_footertext) {
       
    20     $thm_footertext = apply_filters('thematic_footertext', $thm_footertext);
       
    21     return $thm_footertext;
       
    22 } // end thematic_footertext
       
    23 
       
    24 
       
    25 // Located in footer.php
       
    26 // Just after the footer div
       
    27 function thematic_belowfooter() {
       
    28     do_action('thematic_belowfooter');
       
    29 } // end thematic_belowfooter
       
    30 
       
    31 
       
    32 // Located in footer.php 
       
    33 // Just before the closing body tag, after everything else.
       
    34 function thematic_after() {
       
    35     do_action('thematic_after');
       
    36 } // end thematic_after
       
    37 
       
    38 
       
    39 // Functions that hook into thematic_footer()
       
    40 
       
    41     function thematic_subsidiaries() {
       
    42         widget_area_subsidiaries();
       
    43     }
       
    44     add_action('thematic_footer', 'thematic_subsidiaries', 10);
       
    45     
       
    46     function thematic_siteinfoopen() { ?>
       
    47     
       
    48         <div id="siteinfo">        
       
    49 
       
    50     <?php
       
    51     }
       
    52     add_action('thematic_footer', 'thematic_siteinfoopen', 20);
       
    53     
       
    54     function thematic_siteinfo() {
       
    55         global $options;
       
    56         foreach ($options as $value) {
       
    57             if (get_option( $value['id'] ) === FALSE) { 
       
    58                 $$value['id'] = $value['std'];
       
    59             } else { 
       
    60                 $$value['id'] = get_option( $value['id'] );
       
    61             }
       
    62         }
       
    63         /* footer text set in theme options */
       
    64         echo do_shortcode(__(stripslashes(thematic_footertext($thm_footertext)), 'thematic'));    }
       
    65     add_action('thematic_footer', 'thematic_siteinfo', 30);
       
    66     
       
    67     function thematic_siteinfoclose() { ?>
       
    68     
       
    69 		</div><!-- #siteinfo -->
       
    70     
       
    71     <?php
       
    72     }
       
    73     add_action('thematic_footer', 'thematic_siteinfoclose', 40);