“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 12 posts previously published on March 24th
- 2025
- Blog There it is. Simple. That’s my “secret” for the topic of getting one’s “blog mojo back”. I salute the Reclaim Hosting efforts of Maren Deepwell and “Blog or Die” Jim Groom in their growing of a Blogging in Higher Education Community of Practice including last week’s Community Chat on Reclaim (I was impressed how well […]
- 2019
- Springtime Answers! A question or even several of them, surreptitiously, slyly sent my way via a blog post. Even cleverly using my own photo as a featured image. “Well played, my friend.” was my comment in response. Alas, the algorithm remains #NotMyFriend. Some answers… Yes, the frequency needs an increase from very infrequent, to something more quasi-frequent. […]
- 2016
- Help Me Yoda-Kin, Can The JED-API Power a Certification? So many valuable things happened (and are happening) out of last week’s Indie Ed-Tech gathering in Davidson, and one of the biggest payoffs was the session Kin Lane, the API Evangelist, evangelized for us, Indie EdTech and The Personal API. The acronym helps it none, but the way Kin explained an API as something that […]
- 2008
- News, Lack of Location, Maps, Sleuthing The travel route for where I live now in Strawberry to Phoenix is a lovely drive down highway 87, the “Beeline Highway”, that romps up and down some fabulous jumbled up geology, connecting the Sonoran desert to the forest plateau. Ir cab be idyllic… until something happens to close the highway, as the alternative routes […]
- 2007
- How Long is a “Moment?” This “moment” on twitter has lasted at least a week: The ‘moment’ might be, “How long until out über cool technology is bought by Google/Rupert/Yahoo/Microsoft/….”? Pity the poor start up that cannot be munched for 1.65 billion. And pour me another ’57 Chevy. Share this barking on social media
- Weekend Activity For expanding my metabolic horizons, I am working on a 57 Chevy. Share this barking on social media
- Online Conference Conundrums I’ve had a few days rest from the 2 day marathon of our NMC Online Conference on Convergence of Web Culture and Video — which had some phenomenal moments but also are leading me to some un-answered ponderings about these kids of events. Participation. First of all, I attended every session, but that’s because I […]
- Tubing For Teachers Will 2007 be the year noted for the explosion of use for web video? Was it 2006? We just completed a 2 day conference on this at NMC, and I have this dreadful pile of great content I feel like I should get into and start discovering on my own. As soon as I can […]
- 2006
- Dr Coop and “What Can You Do With a Wiki?” I had fun this afternoon helping in a wiki workshop at South Mountain Community College. “Dr Coop” is Alisa Cooper, a gem of an English teacher who pretty much tries and finds almost every new technology- in a thoughtful and effective manner. She got turned onto PBWiki last year and has been using it extensively […]
- Spam For Breakfast Nutrition experts tell us breakfast is the most important meal of the day. As dedicated cereal-aholic, after munching my bowl, there is just no room for the heaping piles of fatty, fetid, rotten spam that I empty out of my SpamKarma 2 traps on a daily basis (bless you 1,000,00 times, Dr. Dave). The portions […]
- 2005
- The Upside of Being Hacked… Well, There is None Last weekend I discovered the web server that hosts our Ocotillo Blogs+Wikis+boards had been compromised and some nefarious person had been able to change the root password for the server. As I was 90 miles from the machine, I had no way to seize back my root account, no way to shut it down remotely. […]
- Amazing Amazon Amaztpye This is just plain cool, perhaps not essentially useful but plainly cool. Amaztype Amaztype is using Amazon web services. Created by Keita Kitamura & Yugo Nakamura for Tha Ltd. Well that does not exactly explain it. You type in a keyword search for Amazon (US, Japan, UK, Canada) for books or music by either title […]
and the default value, the link at the end is invisible.
On Michael’s site he might use There are 12 posts previously published on March 24th
- 2025
- Blog There it is. Simple. That’s my “secret” for the topic of getting one’s “blog mojo back”. I salute the Reclaim Hosting efforts of Maren Deepwell and “Blog or Die” Jim Groom in their growing of a Blogging in Higher Education Community of Practice including last week’s Community Chat on Reclaim (I was impressed how well […] ➡
- 2019
- Springtime Answers! A question or even several of them, surreptitiously, slyly sent my way via a blog post. Even cleverly using my own photo as a featured image. “Well played, my friend.” was my comment in response. Alas, the algorithm remains #NotMyFriend. Some answers… Yes, the frequency needs an increase from very infrequent, to something more quasi-frequent. […] ➡
- 2016
- Help Me Yoda-Kin, Can The JED-API Power a Certification? So many valuable things happened (and are happening) out of last week’s Indie Ed-Tech gathering in Davidson, and one of the biggest payoffs was the session Kin Lane, the API Evangelist, evangelized for us, Indie EdTech and The Personal API. The acronym helps it none, but the way Kin explained an API as something that […] ➡
- 2008
- News, Lack of Location, Maps, Sleuthing The travel route for where I live now in Strawberry to Phoenix is a lovely drive down highway 87, the “Beeline Highway”, that romps up and down some fabulous jumbled up geology, connecting the Sonoran desert to the forest plateau. Ir cab be idyllic… until something happens to close the highway, as the alternative routes […] ➡
- 2007
- How Long is a “Moment?” This “moment” on twitter has lasted at least a week: The ‘moment’ might be, “How long until out über cool technology is bought by Google/Rupert/Yahoo/Microsoft/….”? Pity the poor start up that cannot be munched for 1.65 billion. And pour me another ’57 Chevy. Share this barking on social media ➡
- Weekend Activity For expanding my metabolic horizons, I am working on a 57 Chevy. Share this barking on social media ➡
- Online Conference Conundrums I’ve had a few days rest from the 2 day marathon of our NMC Online Conference on Convergence of Web Culture and Video — which had some phenomenal moments but also are leading me to some un-answered ponderings about these kids of events. Participation. First of all, I attended every session, but that’s because I […] ➡
- Tubing For Teachers Will 2007 be the year noted for the explosion of use for web video? Was it 2006? We just completed a 2 day conference on this at NMC, and I have this dreadful pile of great content I feel like I should get into and start discovering on my own. As soon as I can […] ➡
- 2006
- Dr Coop and “What Can You Do With a Wiki?” I had fun this afternoon helping in a wiki workshop at South Mountain Community College. “Dr Coop” is Alisa Cooper, a gem of an English teacher who pretty much tries and finds almost every new technology- in a thoughtful and effective manner. She got turned onto PBWiki last year and has been using it extensively […] ➡
- Spam For Breakfast Nutrition experts tell us breakfast is the most important meal of the day. As dedicated cereal-aholic, after munching my bowl, there is just no room for the heaping piles of fatty, fetid, rotten spam that I empty out of my SpamKarma 2 traps on a daily basis (bless you 1,000,00 times, Dr. Dave). The portions […] ➡
- 2005
- The Upside of Being Hacked… Well, There is None Last weekend I discovered the web server that hosts our Ocotillo Blogs+Wikis+boards had been compromised and some nefarious person had been able to change the root password for the server. As I was 90 miles from the machine, I had no way to seize back my root account, no way to shut it down remotely. […] ➡
- Amazing Amazon Amaztpye This is just plain cool, perhaps not essentially useful but plainly cool. Amaztype Amaztype is using Amazon web services. Created by Keita Kitamura & Yugo Nakamura for Tha Ltd. Well that does not exactly explain it. You type in a keyword search for Amazon (US, Japan, UK, Canada) for books or music by either title […] ➡
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.