“Who ya gonna call?” “CODEBUSTERS”
No.
But the metaphor of Ghostbusters crossing the streams was inversely appropriate to a little bit of code action over the holidays (of which the actual action was nil).
But this was fun.
This nice tweet from John Johnston (who spawned the idea) reminded me of a WordPress plugin I had made
The WP Posted Today plugin is meant to offer a short code you can put on a site and it will list all previous posts on the current calendar day (this of course is useful if you actually still blog regularly) (cough) (cough).
Just for grins I checked the page where I use my own plugin. Yikes. Red Alert. It displayed all the ones for December 29 in years past, but the part where it should list how many there were was blank.
I dug into my own code… and found myself a bit lost. Crossed. I was not even sure where I got the sprintf functions (John’s original code?) that were aimed to be compatible if anyone every wanted a language translation (maybe, or it’s just that thing when people code things differently).
Taking the path of least resistance, I took out the code where I think the problem was occurring and did it a more simple, but brute force way.
And it worked.
So I updated the version on GitHub and felt at peace with the world. In the off chance someone stumbled into my little corner of code, they would find something that works (or should work).
And then (here comes a stream crossing) Michael Hanscom @djwudi — someone I don’t think I’ve ever communicated with — tweets that he had seen pretty much the same bug and offered a fix.
In looking at his post I saw the fix he made, and said– that’s better than mine! So I decided today to roll back my changes in place of Michael’s solution (but also keeping a modification I had made to remove extraneous calls when not needed for singular versus multiple results).
I noted the extra change he made in hos own version
Plus, I’ve made one other tweak to the plugin, so that it adds a link to the end of the excerpt to better handle “microblog” style entries that don’t have titles, so I still get to feel good about that part, as well. 🙂 My coding skills may be underdeveloped and rusty from lack of regular use, but they’re not entirely atrophied!
In this case, these microblog type entries (see Michael’s demo page) lack titles, so yes, a link is needed at the end of the post excerpt.
Yet I could see that regular posts (like on my site) did not need the extra link, and also, not everyone might want the arrow Michael likes.
I solved this cleverly by creating an additional shortcode parameter more which defaults to a blank string. In the shortcode function, we convert any attributes passed to variables with
extract(shortcode_atts( array( "month" => '', "day" => '', 'excerpt' => 1, 'more' => '' ), $atts ));
So on my site, where I just used the shortcode There are 23 posts previously published on February 23rd
- 2022
- True Stories of Openness for #OER22 (Reruns or a New Season?) Try this one. A friend, colleague contacts you and says, “Do you remember that ______ I shared at _______? The most amazing thing happened…” You do want to know what comes next, right? That’s the the opening “hook” of excitement, intrigue, a hint of a journey that makes up the best of stories. And experiencing […]
- 2020
- Glitch, Remix, a #NetNarr Exquisite Corpse There you go, try guess the nature of this blog post from a word heavy vague title. Better yet, just go first and try the thing I will be ‘splaining right here. Well, are you back? Did anything happen? Because one of our students in class (she too a teacher) asked as well as my […]
- 2018
- WordPress Plugin to Find Waldo in a Twitter TAGs Conversation Explorer I’m a huge fan and repeat user of Martin Hawksey’s Twitter TAGS. If you are doing a class or project with activity around a hashtag, and you are not using this tool, just stop everything and set one up. It’s rather brilliant, a Google Spreadsheet with some Hawksey-ian script genius underneath. It archives all tweets […]
- Can I Haz Embedded Giphy GIFS CogDog says I can. But WTF does he know? Okay, let’s try. I find a GIF on giphy. I put it’s web address as plain text on a blank like https://giphy.com/gifs/divorceonhbo-weird-hbo-3o7WIpvPm4G2ykbOxi Woah. The visual editor does not show me a preview like other embedded media, but the Preview buttons shows me the GIF. Oh... Continue Reading →
- 2017
- Calling in to the Hall in a Weird Town I debated about 10 minutes with myself (well I may have been frying eggs at the same time too) about writing a blog post about politics. I think I’ve done it once before or maybe tucked a few over on medium. But I get to make the rules around here. So I am using a […]
- The Feed WordPress Featured Image Not So Merry Go Round I’ve got my hands in two current connected course sites that rely on the Feed WordPress syndication approach— one is Open Learning 17 led by Gardner Campbell and the other is the Networked Narratives course I am co-teaching with Mia Zamora. We’ve had a bit of a circle around on a part that has little […]
- 2016
- Triple Troll Quoting and The Riffness of #ds106 That first heady phase of the first round of DS106, back to December 2010, before Jim Groom’s first class very started, set the stage for the creative riffing ethos that is part of this crazy space. Like free form music jamming, it is taking something someone else has played, not as a theft labeled copyright […]
- 2015
- On Multisiting These are some notes from my experience here at TRU running two different WordPress sites that are enabled as multisite, or more properly, networks of sites. Among the reasons for doing this include wanting to have a platform to offer […]
- 2013
- A Lesson on How the Open Web Works It’s more than a dream… The dream behind the Web is of a common information space in which we communicate by sharing information. Its universality is essential: the fact that a hypertext link can point to anything, be it personal, local or global, be it draft or highly polished. There was a second part of […]
- New Site, Look for True Stories of Open Sharing I was not happy with the way my site was working out to present the new collection of True Stories of Open Sharing. I found my categories were forcing me into artificial classification. And the nifty gizmo I had used previously, CoolIris, for the “wall of media”, works, but is annoyingly tedious to update (manually […]
- Pechaflickring about Pechaflickr from the vapid self horn tooting department… (cause thats what blogs are for) I just got wind of the edited videos from last month’s Scottsdale Community College’s TechTalks ’13. I love the format they came up with, an idea from Charles Pflanz, brilliantly organized and emceed by Lisa Young. Kudos to the SCC Film department […]
- 2012
- You Fooled Me at the Title: What Magicians Know cc licensed ( BY NC SD ) flickr photo shared by i k o I can’t write a blog post until I wrangle with the headline. I mull that over before I even sit down to write. or that is all I have and I hope an idea flows from there. The title is key […]
- CogDogCodeAcademy: A Random Freesound Generator Who needs a stinking academy to provide a code challenge? With some basics under the belt (which of course you cannot do without) and google (which usually lands you at Stack Overflow), you can tinker away. Well, I can. Here was a tool I whipped up in about 10 minutes, and then spent about another […]
- Walk in the Woods: a ds106 Sound Story cc licensed ( BY ) flickr photo shared by cogdogblog I made this demo for my students to show them Audacity and basic editing for the Sound Effects Story assignment: Tell a story using nothing but sound effects. There can be no verbal communication, only sound effects. Use at least five different sounds that you […]
- 2011
- Ambient Sounds Story This is a slight twist on the ds106 Sound Effects Story assignment– a short story done with only audio effects. Rather than use ones from a library, I mixed together a set of voice-less sounds I made or got from my surroundings. The story first.. http://cogdogblog.com/wp-content/audio/the-keys.mp3 All of the sounds were recorded on my iPhone […]
- Yee Ha! Wikispaces Rolling our Free Ones for Higher Education cc licensed ( BY NC ) flickr photo shared by Thomas Hawk Round up yer wiki-ing, pardner! I just got early word that wikispaces is expanding their program of ad-free fully featured wikis that was up to now offered only for K-12, and making it available for higher education too. We’re taking it to the […]
- Put Yer Mom on teh ds106 radio Here’s a new assignment for your ds10ers; put your Mom on the radio. I have an unfair advantage that my Mom is (a) alive and (b) a good sport. On her annual visits to Strawberry AZ for Thanksgiving, she has let herself be recorded on how to use her Twitter account or her previous amazement […]
- the d, the y, and the i Definitions of “purpose” center on reaching a goal, terminal end, desired result, perhaps a mythical castle in the sky. That does not seem right education, we should want always to go farther. And I wonder if we’re trapped too much, especially in citing what’s wrong, in too easily framing education as school. Maybe it was […]
- 2009
- Giving Up August 30th–It’s True. by Jessica DeWinter posted 7 Sep ’07, 2.22am MDT PST on flickr Freed from the shackles of corporate America. Hah, not what you think. Not that I *know* what you think. One of the interesting re-threads I heard at Northern Voice this year was the navel gazing equivalency of blogging about blogging, […]
- 2005
- Watch Out for Leon Look out fellow bloggers, Leon Lighips a.k.a Guru of the Obvious is going after your Technorati ratings and is planning on becoming king of the Long Tail, the A-List of all A-Lists…. Share this barking on social media
- Join Our Ocotillo Hybrid Courses Guest Discussions The week of February 28, 2005 through March 4 , our Ocotillo Hybrid Course Structures group is hosting an asynchronous discussion board activity. We are pleased and fortunate to have Bob Kaleta and staff from the University of Wisconsin-Milwaukee Learning Technology Center (LTC) as our guests, and they will be checking the board to ask/answer […]
- Helen is Coming To Town! This Friday, the self-proclaimed “Grandmother of Electronic Portfolios”, Helen Barrett is coming to town as our guest for our event “ePortfolio Dialogue Day: Digital Stories of Deep Learning for Students and Faculty”, where we are expecting an audience of 90+ faculty and staff. The day’s agenda is split-starting with a morning focus on student ePortfolios, […]
- 2004
- Amy Is Sadly Excoriated Alas, the blog go around. Apparently Amy is…. sniff….. sniff.. sad about our recent barking on her “Re-name RSS contest”. On her latest update (wow, “Elert” and “Newsfeed” have moved up on “Grapevine”) Amy sobs: Also, “Grapevine” was recently excoriated in the geek-oriented weblog CogDogBlog. Sadly, this is yet another example of how some software […]
and the default value, the link at the end is invisible.
On Michael’s site he might use There are 23 posts previously published on February 23rd
- 2022
- True Stories of Openness for #OER22 (Reruns or a New Season?) Try this one. A friend, colleague contacts you and says, “Do you remember that ______ I shared at _______? The most amazing thing happened…” You do want to know what comes next, right? That’s the the opening “hook” of excitement, intrigue, a hint of a journey that makes up the best of stories. And experiencing […] ➡
- 2020
- Glitch, Remix, a #NetNarr Exquisite Corpse There you go, try guess the nature of this blog post from a word heavy vague title. Better yet, just go first and try the thing I will be ‘splaining right here. Well, are you back? Did anything happen? Because one of our students in class (she too a teacher) asked as well as my […] ➡
- 2018
- WordPress Plugin to Find Waldo in a Twitter TAGs Conversation Explorer I’m a huge fan and repeat user of Martin Hawksey’s Twitter TAGS. If you are doing a class or project with activity around a hashtag, and you are not using this tool, just stop everything and set one up. It’s rather brilliant, a Google Spreadsheet with some Hawksey-ian script genius underneath. It archives all tweets […] ➡
- Can I Haz Embedded Giphy GIFS CogDog says I can. But WTF does he know? Okay, let’s try. I find a GIF on giphy. I put it’s web address as plain text on a blank like https://giphy.com/gifs/divorceonhbo-weird-hbo-3o7WIpvPm4G2ykbOxi Woah. The visual editor does not show me a preview like other embedded media, but the Preview buttons shows me the GIF. Oh... Continue Reading → ➡
- 2017
- Calling in to the Hall in a Weird Town I debated about 10 minutes with myself (well I may have been frying eggs at the same time too) about writing a blog post about politics. I think I’ve done it once before or maybe tucked a few over on medium. But I get to make the rules around here. So I am using a […] ➡
- The Feed WordPress Featured Image Not So Merry Go Round I’ve got my hands in two current connected course sites that rely on the Feed WordPress syndication approach— one is Open Learning 17 led by Gardner Campbell and the other is the Networked Narratives course I am co-teaching with Mia Zamora. We’ve had a bit of a circle around on a part that has little […] ➡
- 2016
- Triple Troll Quoting and The Riffness of #ds106 That first heady phase of the first round of DS106, back to December 2010, before Jim Groom’s first class very started, set the stage for the creative riffing ethos that is part of this crazy space. Like free form music jamming, it is taking something someone else has played, not as a theft labeled copyright […] ➡
- 2015
- On Multisiting These are some notes from my experience here at TRU running two different WordPress sites that are enabled as multisite, or more properly, networks of sites. Among the reasons for doing this include wanting to have a platform to offer […] ➡
- 2013
- A Lesson on How the Open Web Works It’s more than a dream… The dream behind the Web is of a common information space in which we communicate by sharing information. Its universality is essential: the fact that a hypertext link can point to anything, be it personal, local or global, be it draft or highly polished. There was a second part of […] ➡
- New Site, Look for True Stories of Open Sharing I was not happy with the way my site was working out to present the new collection of True Stories of Open Sharing. I found my categories were forcing me into artificial classification. And the nifty gizmo I had used previously, CoolIris, for the “wall of media”, works, but is annoyingly tedious to update (manually […] ➡
- Pechaflickring about Pechaflickr from the vapid self horn tooting department… (cause thats what blogs are for) I just got wind of the edited videos from last month’s Scottsdale Community College’s TechTalks ’13. I love the format they came up with, an idea from Charles Pflanz, brilliantly organized and emceed by Lisa Young. Kudos to the SCC Film department […] ➡
- 2012
- You Fooled Me at the Title: What Magicians Know cc licensed ( BY NC SD ) flickr photo shared by i k o I can’t write a blog post until I wrangle with the headline. I mull that over before I even sit down to write. or that is all I have and I hope an idea flows from there. The title is key […] ➡
- CogDogCodeAcademy: A Random Freesound Generator Who needs a stinking academy to provide a code challenge? With some basics under the belt (which of course you cannot do without) and google (which usually lands you at Stack Overflow), you can tinker away. Well, I can. Here was a tool I whipped up in about 10 minutes, and then spent about another […] ➡
- Walk in the Woods: a ds106 Sound Story cc licensed ( BY ) flickr photo shared by cogdogblog I made this demo for my students to show them Audacity and basic editing for the Sound Effects Story assignment: Tell a story using nothing but sound effects. There can be no verbal communication, only sound effects. Use at least five different sounds that you […] ➡
- 2011
- Ambient Sounds Story This is a slight twist on the ds106 Sound Effects Story assignment– a short story done with only audio effects. Rather than use ones from a library, I mixed together a set of voice-less sounds I made or got from my surroundings. The story first.. http://cogdogblog.com/wp-content/audio/the-keys.mp3 All of the sounds were recorded on my iPhone […] ➡
- Yee Ha! Wikispaces Rolling our Free Ones for Higher Education cc licensed ( BY NC ) flickr photo shared by Thomas Hawk Round up yer wiki-ing, pardner! I just got early word that wikispaces is expanding their program of ad-free fully featured wikis that was up to now offered only for K-12, and making it available for higher education too. We’re taking it to the […] ➡
- Put Yer Mom on teh ds106 radio Here’s a new assignment for your ds10ers; put your Mom on the radio. I have an unfair advantage that my Mom is (a) alive and (b) a good sport. On her annual visits to Strawberry AZ for Thanksgiving, she has let herself be recorded on how to use her Twitter account or her previous amazement […] ➡
- the d, the y, and the i Definitions of “purpose” center on reaching a goal, terminal end, desired result, perhaps a mythical castle in the sky. That does not seem right education, we should want always to go farther. And I wonder if we’re trapped too much, especially in citing what’s wrong, in too easily framing education as school. Maybe it was […] ➡
- 2009
- Giving Up August 30th–It’s True. by Jessica DeWinter posted 7 Sep ’07, 2.22am MDT PST on flickr Freed from the shackles of corporate America. Hah, not what you think. Not that I *know* what you think. One of the interesting re-threads I heard at Northern Voice this year was the navel gazing equivalency of blogging about blogging, […] ➡
- 2005
- Watch Out for Leon Look out fellow bloggers, Leon Lighips a.k.a Guru of the Obvious is going after your Technorati ratings and is planning on becoming king of the Long Tail, the A-List of all A-Lists…. Share this barking on social media ➡
- Join Our Ocotillo Hybrid Courses Guest Discussions The week of February 28, 2005 through March 4 , our Ocotillo Hybrid Course Structures group is hosting an asynchronous discussion board activity. We are pleased and fortunate to have Bob Kaleta and staff from the University of Wisconsin-Milwaukee Learning Technology Center (LTC) as our guests, and they will be checking the board to ask/answer […] ➡
- Helen is Coming To Town! This Friday, the self-proclaimed “Grandmother of Electronic Portfolios”, Helen Barrett is coming to town as our guest for our event “ePortfolio Dialogue Day: Digital Stories of Deep Learning for Students and Faculty”, where we are expecting an audience of 90+ faculty and staff. The day’s agenda is split-starting with a morning focus on student ePortfolios, […] ➡
- 2004
- Amy Is Sadly Excoriated Alas, the blog go around. Apparently Amy is…. sniff….. sniff.. sad about our recent barking on her “Re-name RSS contest”. On her latest update (wow, “Elert” and “Newsfeed” have moved up on “Grapevine”) Amy sobs: Also, “Grapevine” was recently excoriated in the geek-oriented weblog CogDogBlog. Sadly, this is yet another example of how some software […] ➡
to get the arrow codes he likes. This works because output for each found post looks like
// output post and link
$output .= '
' . get_the_title() . '';
// display excerpt if we want it
if ( $excerpt ) $output .= ' ' . get_the_excerpt();
// for microblog output where there might not be titles so add a link at end
// h/t https://www.michaelhanscom.com/eclecticism/2020/01/02/rss-feed-weirdness-and-php-debugging/
$output .= ' ' . $more . '';
So how is that for the odds of streams crossing on the same obscure bit of code? That’s the old fashioned kind of net serendipity that still happens.
Thanks Michael! Check out his 20 year old blog, he’s an “Enthusiastically Ambiverted Hopepunk” quite the tag line.
Featured Image: Edit of the Ghostbusters Cross Streams scene found in the Ghostbusters Fandom Wiki site which states “Community content is available under CC-BY-SA unless otherwise noted.” I replaced part of the background with a screenshot of the WP Posted Today PHP code.