cogdog
Forum Replies Created
-
Thanks – that was a block from my host because of hacking incident a few months back, looks like we are clear. I know now to check this.
Sure thing http://splot.ca/collector/
Thanks as always for quick responses.
I have a site with a front end form where non Admins can upload, from this note http://wordpress.stackexchange.com/a/116489/14945, I set things up with:
add_action('wp_enqueue_scripts', 'add_truwriter_scripts'); function add_truwriter_scripts() { if ( is_page('write') ) { // use on just our special writing page // add media scripts if we are on our wriing page and not an admin // after http://wordpress.stackexchange.com/a/116489/14945 if (! is_admin() ) wp_enqueue_media(); } }Forum: Hacks
In reply to: get_terms Multiple order_by optionsthanks, I love wordpress people.
Forum: Hacks
In reply to: get_terms Multiple order_by optionsThat is awesome, thanks, it works! I have a shortcode that generates the rankings based on a custom taxonomy and tags (I use twitter names as markers, so I filter for ones that start with “@”).
Here it is sorted the way I want
http://udg.theagoraonline.net/daily/leaders/
Here’s my code:
/* ----- shortcode to generate lists of top contributors -------- */ add_shortcode("dailyleaders", "dailyblank_leaders"); function dailyblank_leaders ( $atts ) { // return a list of the top responders to dailies // get the value of any passed attributes to our function // we want a number of results we should return (0=all) // and an indicator if we are looking for responders (hashtag taxonony) or contributors (tag tax) // Allow for exclusion based on ID of the hashtag taxonony extract( shortcode_atts( array( "number" => 0, "type" => 'responders' , "exclude" => "" ), $atts ) ); // temp filter to use name as secondary sort (first by tag count, then by name) add_filter( 'terms_clauses', 'dailyblank_second_orderby', 10, 3 ); // Arguments to search hashtag terms // search for @ in order of highest frequency $args = array( 'number' => $number, 'exclude' => $exclude, 'name__like' => '@' ); if ( $type == 'contributors') { // search for terms in the custom taxonomy for regular tags $terms = get_tags( $args ); $taxpath = 'tag'; } else { // search for terms in the custom taxonomy for response tags $terms = get_terms('hashtags', $args ); $taxpath = 'hashtags'; } // clean up after ourselves remove_filter( 'terms_clauses', 'dailyblank_second_orderby', 10, 3 ); $out = '<ol>'; // here come the leaders! foreach ( $terms as $term) { $out .= '<li><a href="' . site_url() . "/$taxpath/" . $term->slug . '">' . $term->name . ' (' . $term->count . ')</a></li>'; } $out .= '</ol>'; // here ya go! return ($out); } // adds name as secondary order by term for get terms // h/t https://wordpress.org/support/topic/get_terms-multiple-order_by-options?replies=2#post-7396104 // & https://wordpress.org/support/topic/get_terms-multiple-order_by-options?replies=5#post-7401630 function dailyblank_second_orderby( $pieces, $taxonomies, $args ) { $pieces['orderby'] = 'ORDER BY tt.count DESC,t.name'; return $pieces; }Forum: Hacks
In reply to: get_terms Multiple order_by optionsThanks, I got it working by adding filter before my call and removing after, but the sort order is not right. I now get the lowest count at the top (count=1) and alpha sorted within. Tried changing the ‘order’ = > ‘ASC’ but no effect.
Tried adding sort to function, which broke it completely
$pieces['orderby'] = 'ORDER BY tt.count ASC,t.name ASC';Add me to the list. I have gotten one report for every blog on a multisite, even every DESELECTING the option to email reports.
The plugin has been great at helping us get out of a hack, but the annoyance factor by email right now is set to MAX.
Forum: Themes and Templates
In reply to: [Baskerville] Audio Player Needs to be Class Not IDYou are welcome; you have to also edit
content-audio.phpandsingle.php(I used c child theme, so I make copies and edit them) so the audio tag uses a class rather than an id (I did not write that very clearly above).Thanks. He did have one project posted
http://lab.merelearning.ca/portfolio/
No show in the menu editor
Forum: Reviews
In reply to: [Arconix Shortcodes] Excellent and beautiful, hard to find documentationMy bad. I had tried 3 browsers, but it seems to be showing up fine. Must have been some local network issue reaching the gist files. I should know better and have tried later.
Thanks for the great shortcodes, its saving me a ton of style coding.
Forum: Reviews
In reply to: [Arconix Shortcodes] Excellent and beautiful, hard to find documentationThe documentation link stalls every time I look. It never goes beyond accordians
Forum: Plugins
In reply to: [AM Events] Widget Not Filtering By Event CategoryAwesome, works like a charm. Thanks for the quick fix.
Forum: Networking WordPress
In reply to: Random Post Link Everywhere WordPress but MultisiteOh, I bet it’s because my multi-site is via directory, not sub-domain? So it perhaps needs some htaccess magic?
Forum: Plugins
In reply to: [Paid Memberships Pro - Mailchimp Add On] Custom Field IntegrationI have the same question. And not encouraged to see 0 responses….
Forum: Plugins
In reply to: [WP Job Manager] Admin Interface Not Available for Editor RoleAhh, my mistake I missed those short codes, that works. Thanks for such a great plugin.