Paging in a sidebar mini loop
Try doing global $paged before using the variable in the widget function.
Try doing global $paged before using the variable in the widget function.
No further help is needed. unset($the_team[‘_multiwidget’]); worked, and was the element in the array that was showing up at the end of the call. Will have to research what that part is exactly for future reference.
It should be possible to read the global $post variable in your widget function. This will contain all information about the post (or page) displayed on the current page.
Mm, they’re not slashed, if that’s what your meaning. However, they’re definitely not xss-sanitized. Use kses before saving, or esc_attr() on display, if you’re dealing with untrusted data.
But I see no way to add a title unless using legacy widgets. Correct, legacy old style widgets have titles, normal blocks do not because they are not widgets. Note that old style widgets are actually blocks of type core/legacy-widget. Everything is a block. Has this field been removed? No, it was never there to … Read more
Use three sidebars an let them float. Anything else will break depending on the widgets your users insert.
Now, you can use the bbPress Plugin, which is currently in beta-release.
Hi @user2816: It would seem you are using that code in more than one widget? Try changing part of that code from these: function filter_whene($whene=””) { $whene .= ” AND post_date >= ‘” . date(‘Y-m-d’) . “‘ “; return $whene; } add_filter(‘posts_whene’, ‘filter_whene’); To this: if (!function_exists(‘filter_whene’)) { function filter_whene($whene=””) { $whene .= ” AND … Read more
Figured out how (Thanks to WordPress Codex): /** @see WP_Widget::widget */ function widget($args, $instance) { extract( $args ); $title = apply_filters(‘widget_title’, $instance[‘title’]); ?> <?php echo $before_widget; ?> <?php if ( $title ) echo $before_title . $title . $after_title; ?> <?php // Create and run custom loop $custom_posts = new WP_Query(); $custom_posts->query(‘post_type=page_content’); while ($custom_posts->have_posts()) : $custom_posts->the_post(); … Read more
When adding a plugin to WordPress.org plugin repository you need to host the plugin somewhere (anywhere) and that is the “Plugin URL” so the good guys at WordPress could download it, test it and approve it to be listed. so just upload it to your host and enter the url to the zip file. Once … Read more