Nick the Geek
Forum Replies Created
-
Forum: Plugins
In reply to: [Genesis Featured Widget Amplified] Genesis Featured Widget AmplifiedWhat are your current settings for the widget? Specifically the taxonomy selection and the contents of the exclude term field.
Forum: Plugins
In reply to: [Genesis Featured Widget Amplified] Genesis Featured Widget AmplifiedOK, I’ll probably be putting this into the 0.8 roadmap, 0.7 is scheduled for release this week. Then I’ll start development on 0.8
Forum: Plugins
In reply to: [Genesis Featured Widget Amplified] Genesis Featured Widget AmplifiedNick,
Just to be clear, you have selected a “tag” term but are attempting to exclude a category term?
Because of the way the query args are built the plugin doesn’t support this option at this time. You have to exclude the same type of term you selected. I’m looking into options for how to extend the exclusion to other taxonomies.
Tell me, would you find it better to be able to select a single taxonomy to exclude terms from or would you be willing to use a pattern in the exclude field like
category: x, y, z; tag: a, b, c; other-tax: m, n, o
With that kind of pattern I could easily breakup the terms into their respective taxonomies, and even provide an include field for complex taxonomy queries like that.
You’re welcome. Sorry it took a while to find.
you’re welcom
This is actually a pretty dangerous things to change. The tags are stripped because otherwise you will get open tags. Lets say you have something like this
<p>This is a paragraph, it has enough characters to end in the middle of the paragraph</p>
Now that wouldn’t actually get truncated by the_excerpt, so imagine a bunch of other words. Now lets say the <p> tags are left alone, you would get this
<p>This is a paragraph, it has enough characters to end...
Now you have an open <p> tag.
A much safer solution, if you need to keep formatting, would be to use the manual excerpt. You can add your text with all html formatting to the manual excerpt field, then it will return exactly what you have added including all formatting.
Sorry for the delay on this. I had to go through several tests to figure out why the exclude isn’t working, turns out that it is as simple as a space after post__not_in.
This will be fixed in the 0.7 update, which I hope to have out next week, but you can apply the patch pretty easily. Search for “post__not_in” in the widget.php file and remove the space after the arg.
$term_args['post__not_in '] = $IDs;
becomes
$term_args['post__not_in'] = $IDs;
The Exclude Terms by ID lets you skip specific terms. For example, if you wanted to pull in posts by tag but skip a specific tag you could select All Tags from the list and put the tag ID in the exclude terms field. This will skip any posts that have been assigned that tag. The default taxonomy is Category, so if you have “All Terms and Taxonomies” selected then the exclude terms field is for categories.
The Post ID lets you skip specific posts.
The meta key is used in the query to search for specific metakeys (custom field names). It can be used with the sorting options, so if you want to sort your posts into a specific order you can assign them a custom field “order” and assign a number to the field to sort them. Then select to sort (orderby) the posts by numeric metakey.
As for the exclude not working. Are these sticky posts?
Forum: Plugins
In reply to: [Genesis Featured Widget Amplified] Genesis Featured Widget AmplifiedCan you test with the 0.6.6 update. I made some changes for the category ID to work when options other than All Taxonomies is selected.
The All Category selection will be fixed in the next update, I repaired the code and it is testing correctly if you would like to update your copy to be ahead of the update.
Find this line (line 386)
<option style="margin-left: 5px; padding-right:10px;" value="<?php echo esc_attr( $query_label ); ?>" <?php selected( esc_attr( $query_label ) ); ?>><?php echo $taxonomy->labels->all_items; ?></option><?php
replace it with
<option style="margin-left: 5px; padding-right:10px;" value="<?php echo esc_attr( $query_label ); ?>" <?php selected( esc_attr( $query_label ), $instance['posts_term'] ); ?>><?php echo $taxonomy->labels->all_items; ?></option><?php
Thanks for bringing this to my attention so I can make this plugin better.
NP, ok, so the pagination or post info would be the easiest to test against at this time.
// Add Social Buttons to Featured Widget add_action('gfwa_after_post_content', 'include_featured_social'); function include_featured_social($instance) { if ( !empty( $instance['show_byline'] ) ) require(CHILD_DIR.'/featured-social.php'); }
This will cause the file to only load on that hook when the post info is selected, which it isn’t for your sidebar. You can drop the conditional in the featured-social.php file.
Also, like I said I’m going to add a field just for this type of thing. I have filters in place to make it possible to add options to the widget form, but having a text field to test against will make it even easier.
The code you will need to test again is part of the $instance value. You can either add a new value to the options, or use an existing value. To make this easier I think I’ll add a field for setting a value to test against in another version.
For now, is there anything different about the settings between the widgets right now?