“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.

Red arrow points to missing number where the page output reads "There are posts previously published on December 29th"

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.

https://twitter.com/djwudi/status/1212871226953101313

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 14 posts previously published on September 11th

  • 2025
    • Federating Typos I love WordPress. And I love the Fediverse. So together, I love the ActivityPub WordPress plugin that is the magic pixie dust betwxit them. This is an experiment. I published a post here yesterday A[I]s We May Not Think (nor search, nor link), hence autopmatically sent out to the wide fedispace via @barking which was […]
    • Blabbing About Blogging for Reclaim Hosting’s “On Writing” What could be more traditional than the time honored blogging about blogging? Oh, oh, oh, Mr. Kotter call in me! What about blabbing live online about blogging? That’s the beauty oh what is just a part of Reclaim Hosting’s Blogging Community of Practice, notably the “On Writing” series on Reclaim.tv that Jim Groom et al […]
  • 2020
    • Old Time HTM&L Cue up the NCSA Silver Browser Band… Just take those old web sites off the shelf I’ll click and watch ’em by myself Today’s sites ain’t got the same soul I like that old-time HTM&L Don’t tell me about web standards What fun is there without a tag for a blink Or a marquee to […]
  • 2018
    • You Can’t Always Get The Features You Want… A call came in from Aaron Davis on the coding request line came through for my Export Posts to CSV WordPress plugin. https://twitter.com/mrkrndvs/status/1035770170046914560 He microblogged today a mention A plugin of mine he had a plan I knew he might need a correction An issue submitted may mean I can No, you can’t always get […]
  • 2015
    • Tuco No Ugly I do not even want to look to find out the last time I officially completed a ds106 assignment (probably last time I taught, Spring 2014). But I was so inspired by Bill Genereux’s new one, A Scene We Didn’t Get To See: Create a short video that shows a scene from your favorite TV […]
    • The Twitter Ramp Up Problem We are hearing a lot of feedback from our UDG Agora participants that many of their efforts to have their students use twitter fall short “They don’t like it”, “They won’t go there”, “they prefer Facebook”. I have zero surprise. If you send anyone to twitter for the first time telling them to “make and […]
    • If You Can Explain Twitter to Your Mom… I’ve used this suggestion a few times to participants in our UdGAgora Project who are trying to figure out what kinds of things they can have their students do, that also produce some artifact that documents their learning. Few things work better to me than having your students have to explain the concept themselves to […]
  • 2014
    • I am a Smart-Ass Published tonight on medium.com – am still finding my way around the writing space. I find it makes me actually go over my words like 4 or 5 times rather than my typo-ridden blurt here. But anyhow, the real truth behind the origin of the Internet I am a Smart-Ass (the Internet was built for […]
    • My God– It’s Full of CMOOCs! I thought this image was a clever idea, but it may not be quite apparent. I have replaced Dave from 2001 A Space Odyssey with a montage/collage/frommage of George Siemens (image source) and Stephen Downes (image source). Why? Of course, together they spawned the first cMOOC, CCK08, which really ought to be for Canadian Massive […]
  • 2013
    • On the Cover of a DS106 Book You should be able to get your pre-order in for Anya Kamenetz’s newest book! This is my submission for today’s ds106 daily create (TDC612) We predict the next book by @anya1anya is about #ds106. Design her some cover art. September 11, 2013 Anya Kamenetz is one of the organizers of the Reclaim Open Learning Contest, […]
  • 2011
    • Book Report: Microserfs My book report is on this really cool story… I just wanted to continue a log of books read on this trip; my reading volume will likely exceed the sum total for the last 4 years. When I was in Hope, BC, I found a great little book store that had 50% off of all […]
    • The ds106 Narrative Fence cc licensed ( BY NC SD ) flickr photo shared by cj berry Every other sentence in this post is going to be a disclaimer that I am NOT criticizing the newest efforts of the ds106 course being drawn out by Michael B Smith. Can I repeat– I am NOT criticizing the newest efforts of […]
  • 2007
    • Roll Your Own Flickr Notes For a long time I have continually raved about what I think is a severely under-used Cool Flickr Feature- the ability to add notes, or hypertext regions to images. For many long, winter nights, I have wondered.. Why Dont Teachers Jump All Over Such a Thing?, but alas, gave up on hearing an answer from […]
  • 2003
    • Way Cool Tool for Getting out of the Blog Style Box This looks rather useful for weblogers who are still mired in the out of the box templates: Firdamatic: the Design Tool for the Uninspired Webloggers “is an online tableless HTML layout generator that allows you to create and customise layouts easily only by completing forms, making creating skins for your Firdamatic-based layout a breeze.” Not […]
and the default value, the link at the end is invisible.

On Michael’s site he might use

There are 14 posts previously published on September 11th

  • 2025
    • Federating Typos I love WordPress. And I love the Fediverse. So together, I love the ActivityPub WordPress plugin that is the magic pixie dust betwxit them. This is an experiment. I published a post here yesterday A[I]s We May Not Think (nor search, nor link), hence autopmatically sent out to the wide fedispace via @barking which was […] &amp#x27A1;
    • Blabbing About Blogging for Reclaim Hosting’s “On Writing” What could be more traditional than the time honored blogging about blogging? Oh, oh, oh, Mr. Kotter call in me! What about blabbing live online about blogging? That’s the beauty oh what is just a part of Reclaim Hosting’s Blogging Community of Practice, notably the “On Writing” series on Reclaim.tv that Jim Groom et al […] &amp#x27A1;
  • 2020
    • Old Time HTM&L Cue up the NCSA Silver Browser Band… Just take those old web sites off the shelf I’ll click and watch ’em by myself Today’s sites ain’t got the same soul I like that old-time HTM&L Don’t tell me about web standards What fun is there without a tag for a blink Or a marquee to […] &amp#x27A1;
  • 2018
    • You Can’t Always Get The Features You Want… A call came in from Aaron Davis on the coding request line came through for my Export Posts to CSV WordPress plugin. https://twitter.com/mrkrndvs/status/1035770170046914560 He microblogged today a mention A plugin of mine he had a plan I knew he might need a correction An issue submitted may mean I can No, you can’t always get […] &amp#x27A1;
  • 2015
    • Tuco No Ugly I do not even want to look to find out the last time I officially completed a ds106 assignment (probably last time I taught, Spring 2014). But I was so inspired by Bill Genereux’s new one, A Scene We Didn’t Get To See: Create a short video that shows a scene from your favorite TV […] &amp#x27A1;
    • The Twitter Ramp Up Problem We are hearing a lot of feedback from our UDG Agora participants that many of their efforts to have their students use twitter fall short “They don’t like it”, “They won’t go there”, “they prefer Facebook”. I have zero surprise. If you send anyone to twitter for the first time telling them to “make and […] &amp#x27A1;
    • If You Can Explain Twitter to Your Mom… I’ve used this suggestion a few times to participants in our UdGAgora Project who are trying to figure out what kinds of things they can have their students do, that also produce some artifact that documents their learning. Few things work better to me than having your students have to explain the concept themselves to […] &amp#x27A1;
  • 2014
    • I am a Smart-Ass Published tonight on medium.com – am still finding my way around the writing space. I find it makes me actually go over my words like 4 or 5 times rather than my typo-ridden blurt here. But anyhow, the real truth behind the origin of the Internet I am a Smart-Ass (the Internet was built for […] &amp#x27A1;
    • My God– It’s Full of CMOOCs! I thought this image was a clever idea, but it may not be quite apparent. I have replaced Dave from 2001 A Space Odyssey with a montage/collage/frommage of George Siemens (image source) and Stephen Downes (image source). Why? Of course, together they spawned the first cMOOC, CCK08, which really ought to be for Canadian Massive […] &amp#x27A1;
  • 2013
    • On the Cover of a DS106 Book You should be able to get your pre-order in for Anya Kamenetz’s newest book! This is my submission for today’s ds106 daily create (TDC612) We predict the next book by @anya1anya is about #ds106. Design her some cover art. September 11, 2013 Anya Kamenetz is one of the organizers of the Reclaim Open Learning Contest, […] &amp#x27A1;
  • 2011
    • Book Report: Microserfs My book report is on this really cool story… I just wanted to continue a log of books read on this trip; my reading volume will likely exceed the sum total for the last 4 years. When I was in Hope, BC, I found a great little book store that had 50% off of all […] &amp#x27A1;
    • The ds106 Narrative Fence cc licensed ( BY NC SD ) flickr photo shared by cj berry Every other sentence in this post is going to be a disclaimer that I am NOT criticizing the newest efforts of the ds106 course being drawn out by Michael B Smith. Can I repeat– I am NOT criticizing the newest efforts of […] &amp#x27A1;
  • 2007
    • Roll Your Own Flickr Notes For a long time I have continually raved about what I think is a severely under-used Cool Flickr Feature- the ability to add notes, or hypertext regions to images. For many long, winter nights, I have wondered.. Why Dont Teachers Jump All Over Such a Thing?, but alas, gave up on hearing an answer from […] &amp#x27A1;
  • 2003
    • Way Cool Tool for Getting out of the Blog Style Box This looks rather useful for weblogers who are still mired in the out of the box templates: Firdamatic: the Design Tool for the Uninspired Webloggers “is an online tableless HTML layout generator that allows you to create and customise layouts easily only by completing forms, making creating skins for your Firdamatic-based layout a breeze.” Not […] &amp#x27A1;
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.

    Profile Picture for CogDog The Blog
    An early 90s builder of web stuff and blogging Alan Levine barks at CogDogBlog.com on web storytelling (#ds106 #4life), photography, bending WordPress, and serendipity in the infinite internet river. He thinks it's weird to write about himself in the third person. And he is 100% into the Fediverse (or tells himself so) Tooting as @cogdog@cosocial.ca

    Leave a Reply

    Your email address will not be published. Required fields are marked *