/** * Set up shortcodes and call the main function for output * * @since 1.0 */ function wprss_shortcode($atts = array()) { //Enqueue scripts / styles wp_enqueue_script('jquery.colorbox-min', WPRSS_JS . 'jquery.colorbox-min.js', array('jquery')); wp_enqueue_script('wprss_custom', WPRSS_JS . 'custom.js', array('jquery', 'jquery.colorbox-min')); $general_settings = get_option('wprss_settings_general'); if (!$general_settings['styles_disable'] == 1) { wp_enqueue_style('colorbox', WPRSS_CSS . 'colorbox.css', array(), '1.4.33'); wp_enqueue_style('styles', WPRSS_CSS . 'styles.css', array(), ''); } if (!empty($atts)) { foreach ($atts as $key => &$val) { $val = html_entity_decode($val); } } ob_start(); // start an output buffer to output of the following function wprss_display_feed_items($atts); $feed_items = ob_get_clean(); // save the current buffer and clear it return apply_filters('wprss_shortcode_output', $feed_items); }
</div><!--end col s8 --> <div class="col l4 m12" id="sideNav"> <?php get_sidebar(); ?> <!-- Here is the code to pull in the Library Leadership Notes items on the current Staff website home page - Starrie --> <div class="widget widget_leadershipBlog"> <h2 class="widgettitle"><a href="http://leadership.library.virginia.edu">Library Leadership Blog</a></h2> <?php wprss_display_feed_items($args = array('links_before' => '<ul class="collection">', 'links_after' => '</ul>', 'link_before' => '<li class="collection-item">', 'link_after' => '</li>', 'limit' => '3', 'source' => '8170')); ?> <a class="btn-large waves-effect waves-light orange darken-1" href="http://leadership.library.virginia.edu">Read More</a> </div> <?php the_widget('WP_Widget_Categories', $instance, $args); ?>
/** * Redirects to wprss_display_feed_items * It is used for backwards compatibility to versions < 2.0 * * @since 2.1 */ function wp_rss_aggregator($args = array()) { wprss_display_feed_items($args); }
<div class="widget-area"> <?php if (is_front_page()) { ?> <?php dynamic_sidebar('sidebar-2'); ?> <div class="new_feed" > SFA News </div> <?php wprss_display_feed_items(); ?> <?php } ?> <?php if (!is_front_page() and !is_home()) { ?> <?php dynamic_sidebar('sidebar-2'); ?> <?php if (function_exists(simple_breadcrumb)) {