“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 17 posts previously published on August 14th

  • 2017
    • Revisiting Another Deaddrop No one is going to try and connect to this damaged USB drive sticking out of a wall and a Toronto alley. But it’s been here more than five years: Like the one that I found again in a Vancouver alley (it always seems to be in an alley) (in Canada) this one was placed […]
  • 2016
    • Looking Back & Forward: What Bloghicans Do Martin Weller is on a blogging about blogging tear, both with speculating about what if blogging was part of OER and before that, revisiting one’s blog past. Martin, like Jim Groom, is among what we like to call The Last of The Bloghicans. The latter is what this post is setting out to do. Of […]
  • 2014
    • All You Need is Fix All After seeing Martin’s tweet, I thought “lt should be easy”… @bonstewart @wishcrys @iktmaria unfortunately education is still broken — Martin Weller – @Mweller (@mweller) August 14, 2014 Whereby distraction led me down the road of making It just seems so desirable for some stuff we could dab on anything and fix it. There’s all kinds […]
    • Remodeling the Future of Learning Site creative commons licensed ( BY ) flickr photo shared by Jeremy Levine Design Having done more than a handful of Feed WordPress powered syndication sites, I’ve had some interesting opportunities to handle difference scenarios when the course/event actually decides to run another year. I posted an extensive write up for The Harvard School of Graduate […]
  • 2013
    • Getting Closer to Headless #ds106 cc licensed ( BY NC ) flickr photo shared by Zoriah Step right up on August 26, the launch date for the Headless Open Digital Storytelling course from your freaks and friends at ds106. The idea is to create an experience for people who are interested in participating in a digital storytelling open course that […]
    • Building the Future of Learning Site Last June I was approached by Justin Reich from Harvard (and newly with EdX) about building a site for the Future of Learning Institute, that is part of Project Zero at the Harvard Graduate School of Education- he was looking for the syndication/aggregation features I had created for the ETMOOC site’s blog and twitter hubs. […]
  • 2012
    • Unplug’d Replug’d cc licensed ( BY ) flickr photo shared by cogdogblog I could not be more unplugged right now if I tried. Some of the decision for unplugging from my position at the University of Mary Washington last Thursday was my departure to participate in Unplug’d 2012. This is the conference event thing (?) where 40 […]
  • 2011
    • IdeaBox for StoryBox cc licensed ( BY ) flickr photo shared by cogdogblog The content inside the StoryBox is growing nicely- as of today I have: audio recordings: 55 documents: 7 drawings: 6 graphics: 4 music: 13 photos: 195 videos: 65 Much if it is mine- I am adding something almost every day, and where-ever possible doing audio […]
    • Career in the Rear View Window / Down the Road You wont get for down the road if you only look at the rear view window, but it is a good idea to glance at it every now and then. It is almost 5 months since writing about the odyssey I am on and my leaving my job after 5 years at the NMC. There […]
    • Roadcast: Road to Regina cc licensed ( BY ) flickr photo shared by cogdogblog Without some large foundation funding to pay my AT&T bill, here in Canada I am SOL for doing life ds106 radio broadcasts from the road. But on the drive yesterday to Regina from Saskatoon, I decided to record a short audio recording. Here are some […]
    • Road Stats Week 7 cc licensed ( BY ) flickr photo shared by cogdogblog Number of days on the road: 48 Miles Driven: 50905 5095 Number of States/Provinces driven in: 9 Number of US/Canadian Border Crossings: 1 Money spent on gas: $1132.56 Photos posted: 1247 (that is an average of 26.0 per day) Number of nights in hotels/B&B: 9 […]
  • 2009
    • What’s Truly Amazing My session yesterday at the Open Education Conference was absolutely the most fun thing I have put together for a conference. it was so fun I did not wait til the night before to finish it. The images above were totally not necessary, but I found myself up at 1:30am mocking up old covers from […]
  • 2008
    • My What a Big Screen You Have… I have yet to even explore all the features that clicky offers for web stats, but am still on a love plain after accidently discovering it. I am running the free version here on CogDogBlog, and just found that there are widgets you can use, so I have the daily stats now embedded on my […]
  • 2007
    • Slow Death of E-Mail I’ve been using email, I think since my undergrad days at University of Delaware, maybe 1981 or 1982.. I know for sure I had a BITNET email at Arizona State when I got there in ’87. E-mail, spam, the sheer volume of junk is a pain, but ot one I can yet say I am […]
  • 2006
    • Shout Out for “Learning in Real Time” A new book on synchronous learning strategies has just come out– Learning in Real Time by Jonathan Finkelstein, and there is a new web site companion for the book. Disclaimer: I got to read a preview of the book last Spring, and was asked to write a few remarks for the back cover… I write […]
  • 2004
    • To San Fran and Back: One Day for Horizon Project I was a commuter today- a one day trip fro Phoenix to San Francisco for the NMC Horizon Project meeting… I am rather humbled and honored to be a part of a group of heavy hitters in the instructional technology realm- Phil Long from MIT (we first crossed paths at the TLTGroup‘s mid 1990s summer […]
  • 2003
    • New RSS: Multimedia Authoring Building from the same path we have added RSS to 4 other resource web sites, we just added a feed to Multimedia Authoring Web. Get the feed (RSS 2.0) “AUTHORING” here refers to “programming by non-programmers.” This site is a resource collection of pointers to Internet sites for those that develop or “author” multimedia. This […]
and the default value, the link at the end is invisible.

On Michael’s site he might use

There are 17 posts previously published on August 14th

  • 2017
    • Revisiting Another Deaddrop No one is going to try and connect to this damaged USB drive sticking out of a wall and a Toronto alley. But it’s been here more than five years: Like the one that I found again in a Vancouver alley (it always seems to be in an alley) (in Canada) this one was placed […] &amp#x27A1;
  • 2016
    • Looking Back & Forward: What Bloghicans Do Martin Weller is on a blogging about blogging tear, both with speculating about what if blogging was part of OER and before that, revisiting one’s blog past. Martin, like Jim Groom, is among what we like to call The Last of The Bloghicans. The latter is what this post is setting out to do. Of […] &amp#x27A1;
  • 2014
    • All You Need is Fix All After seeing Martin’s tweet, I thought “lt should be easy”… @bonstewart @wishcrys @iktmaria unfortunately education is still broken — Martin Weller – @Mweller (@mweller) August 14, 2014 Whereby distraction led me down the road of making It just seems so desirable for some stuff we could dab on anything and fix it. There’s all kinds […] &amp#x27A1;
    • Remodeling the Future of Learning Site creative commons licensed ( BY ) flickr photo shared by Jeremy Levine Design Having done more than a handful of Feed WordPress powered syndication sites, I’ve had some interesting opportunities to handle difference scenarios when the course/event actually decides to run another year. I posted an extensive write up for The Harvard School of Graduate […] &amp#x27A1;
  • 2013
    • Getting Closer to Headless #ds106 cc licensed ( BY NC ) flickr photo shared by Zoriah Step right up on August 26, the launch date for the Headless Open Digital Storytelling course from your freaks and friends at ds106. The idea is to create an experience for people who are interested in participating in a digital storytelling open course that […] &amp#x27A1;
    • Building the Future of Learning Site Last June I was approached by Justin Reich from Harvard (and newly with EdX) about building a site for the Future of Learning Institute, that is part of Project Zero at the Harvard Graduate School of Education- he was looking for the syndication/aggregation features I had created for the ETMOOC site’s blog and twitter hubs. […] &amp#x27A1;
  • 2012
    • Unplug’d Replug’d cc licensed ( BY ) flickr photo shared by cogdogblog I could not be more unplugged right now if I tried. Some of the decision for unplugging from my position at the University of Mary Washington last Thursday was my departure to participate in Unplug’d 2012. This is the conference event thing (?) where 40 […] &amp#x27A1;
  • 2011
    • IdeaBox for StoryBox cc licensed ( BY ) flickr photo shared by cogdogblog The content inside the StoryBox is growing nicely- as of today I have: audio recordings: 55 documents: 7 drawings: 6 graphics: 4 music: 13 photos: 195 videos: 65 Much if it is mine- I am adding something almost every day, and where-ever possible doing audio […] &amp#x27A1;
    • Career in the Rear View Window / Down the Road You wont get for down the road if you only look at the rear view window, but it is a good idea to glance at it every now and then. It is almost 5 months since writing about the odyssey I am on and my leaving my job after 5 years at the NMC. There […] &amp#x27A1;
    • Roadcast: Road to Regina cc licensed ( BY ) flickr photo shared by cogdogblog Without some large foundation funding to pay my AT&T bill, here in Canada I am SOL for doing life ds106 radio broadcasts from the road. But on the drive yesterday to Regina from Saskatoon, I decided to record a short audio recording. Here are some […] &amp#x27A1;
    • Road Stats Week 7 cc licensed ( BY ) flickr photo shared by cogdogblog Number of days on the road: 48 Miles Driven: 50905 5095 Number of States/Provinces driven in: 9 Number of US/Canadian Border Crossings: 1 Money spent on gas: $1132.56 Photos posted: 1247 (that is an average of 26.0 per day) Number of nights in hotels/B&B: 9 […] &amp#x27A1;
  • 2009
    • What’s Truly Amazing My session yesterday at the Open Education Conference was absolutely the most fun thing I have put together for a conference. it was so fun I did not wait til the night before to finish it. The images above were totally not necessary, but I found myself up at 1:30am mocking up old covers from […] &amp#x27A1;
  • 2008
    • My What a Big Screen You Have… I have yet to even explore all the features that clicky offers for web stats, but am still on a love plain after accidently discovering it. I am running the free version here on CogDogBlog, and just found that there are widgets you can use, so I have the daily stats now embedded on my […] &amp#x27A1;
  • 2007
    • Slow Death of E-Mail I’ve been using email, I think since my undergrad days at University of Delaware, maybe 1981 or 1982.. I know for sure I had a BITNET email at Arizona State when I got there in ’87. E-mail, spam, the sheer volume of junk is a pain, but ot one I can yet say I am […] &amp#x27A1;
  • 2006
    • Shout Out for “Learning in Real Time” A new book on synchronous learning strategies has just come out– Learning in Real Time by Jonathan Finkelstein, and there is a new web site companion for the book. Disclaimer: I got to read a preview of the book last Spring, and was asked to write a few remarks for the back cover… I write […] &amp#x27A1;
  • 2004
    • To San Fran and Back: One Day for Horizon Project I was a commuter today- a one day trip fro Phoenix to San Francisco for the NMC Horizon Project meeting… I am rather humbled and honored to be a part of a group of heavy hitters in the instructional technology realm- Phil Long from MIT (we first crossed paths at the TLTGroup‘s mid 1990s summer […] &amp#x27A1;
  • 2003
    • New RSS: Multimedia Authoring Building from the same path we have added RSS to 4 other resource web sites, we just added a feed to Multimedia Authoring Web. Get the feed (RSS 2.0) “AUTHORING” here refers to “programming by non-programmers.” This site is a resource collection of pointers to Internet sites for those that develop or “author” multimedia. This […] &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 *