Last week I added a new archive page to Micro.blog-hosted sites. It includes dates and the first part of each post, marked up with Microformats. Jonathan LaCour used this to write a script that parses the HTML looking for posts on today’s date in previous years, then pulls the full content for each post it finds and assembles them together.
But it gets better. After Jonathan mentioned that it took quite a while to parse the large HTML file, I added a JSON Feed version of the archive page. If you’ve posted to Micro.blog since yesterday, this has been created for you at your-domain.com/archive/index.json
. Jonathan updated the script to use the JSON Feed and it can now return the “on this day” posts very quickly, with no configuration needed because it’s all driven from a JavaScript include on your blog.
You can see this in action on my own blog’s on this day page. It works for any Micro.blog-hosted blog by pasting in a few lines of HTML from the Micro Memories project on GitHub.
This is the potential for indie blogging and simple formats. Adding a feature to Micro.blog-hosted blogs enabled a new tool I hadn’t even thought of. There was some discussion in the IndieWeb chat, but it took very little coordination because all of this is built with web stuff, not proprietary APIs.
Timothy Smith
Timothy Smith
Matthew Lang A fantastic feature! At long last I can dig into my archives for posts I may have forgotten about.
Sylari Fantastic implementation!
James R. Hull I must be completely dense. When I go to your “on this day” page I get today’s post, along with seemingly random ones from 2015...this sounds cool, but I’m not sure what I’m missing!
Manton Reece @jhull Oh, I should have explained that better. All the posts were written on July 31st in the years it found. Tomorrow if you reload the page it will show posts from August 1st from 2015, 2016, etc. (Going back to 2002 if it finds any. Of course I didn't post every day back then.)
Khaled Abou Alfa Really love this. Based on your recent discussion about timezone malarkey, I'm hitting a bit of a 'Invalid Date' being posted - the rest of the page loads exactly as intended. Didn't matter what time zone I used (the default US/Pacific, or the one that I'd like to use Asia/Dubai). Any ideas?
James R. Hull 🤦🏻♂️ ohhh, of course...that is awesome!
jonathan simcoe This is fantastic! Thanks so much and @cleverdevil. 👏
Jonathan LaCour @jdsimcoe you're welcome! It was fun to build, and its gratifying to help people re-discover their best memories 😊
The Micro Blog @cleverdevil Cool! Thank you for doing this!
Frank McPherson Oh, then this isn't going to be useful for me until next year given that I just started using micro.blog hosting less than a year ago.
Manton Reece @frankm Yep. Only useful right now for people who used Micro.blog very early or who imported posts from a previous blog.
Jonathan LaCour @the you're so very welcome!
Jamie Thingelstad I love this but sure wish I could import my 10 years of Tweets. Any plans in fixing up the Twitter importer more? When I tried it a LONG time ago it got confused on dates. I’d like to try again.
Manton Reece @jthingelstad I'm not aware of any current import problems, but I still discourage people from using it because it can slow some things down (like the new archive page). I'd like to rethink how imported tweets are handled.
Jamie Thingelstad against your recommendation I did import my Twitter archive again. There is a problem where the imported timestamp doesn't get the time right, only the date. It starts midway through the import. There must be a timestamp format change early in Twitter? If you look at my posts from 2007 you will see they all show 6:00pm, which I think is midnight with timezone offset.
Manton Reece @jthingelstad Can you email me your Twitter archive? Just the .csv file (zipped) in the archive is fine. Sounds like a data problem since Micro.blog should be able to parse most date formats.
💬 John Philpin @frankm since you are/were a 1999 dude ... Know that I imported all my 1999 posts in. Needed a little tweaking by at the time ... But pretty seamless and nice to see those entries along with my few (so far) Instagrams appearing ... On the "on this day" page.
Frank McPherson @JohnPhilpin How did you do the import?
💬 John Philpin @frankm it was a while back - but I THINK I used the import xml format under wordpress in micro blog admin - if that doesn’t work - let me look back and see the detail
Frank McPherson @JohnPhilpin Did you use the chatlog.json file from your 1999 site or the RSS?
💬 John Philpin @frankm that could have been it ... Any harm in trying it?
💬 John Philpin @frankm just checked my archives …and yes json file was what we used …. the conversation started in slack - and I tried - and failed … and eventually sent the file as a zip to who actually did the import. i think it was a 2999 corruption tat caused my problem - but cant quite recall now. Hope that helps.
Manton Reece @JohnPhilpin @frankm I built a 1999 import feature, but it's not exposed in the web UI. I can manually import it if you email me the JSON file.
Frank McPherson Thanks, to where shall I send or put the file?
Roberto Mateu any plans for a micro.blog JSON format or (gasp) CSV template for importing non-wordpress blogs? I'm on blot.im, and the lack of a simple import really makes me procrastinate a move.
Frank McPherson I sent my JSON file to the help at micro.blog address. Not a rush, and I appreciate you doing this for me.