MainDoctor WhoMusicSoftware
Main Page

Alden Bates' Weblog

Movable Type Archives

Page 1 of 2

March 4, 2008

Paged Archives v1.31

Wow, I can't believe it's nearly nine months since the last PagedArchives update.

This version adds two parameters to the MTPASettings tag, and three new tags.

<MTPASettings numofentries="NN"> - PagedArchives does its best to work out how many entries there are on the archive page which it's splitting up. Sometimes it gets the count wrong, usually when the <MTEntries> tag has extra arguments to it. E.g., if you have <MTEntries limit="100">, you could specify <MTPASettings numofentries="100">. You can also use MT tags in the argument, such as <MTPASettings numofentries="<mt:EntriesCount />">

<MTPASettings pagelistlimit="NN"> - Normally <MTPAPageList> will just display a list of all the pages like "1 2 3 4 5 6 7 8 9 10", but if you specify a pagelistlimit of, for instance, 5, it will only display the current page number and two pages to either side (As in our example "... 3 4 5 6 7 ..."). Naturally if you're at the start of the list, you'll get the first five pages: "1 2 3 4 5 ...".

<MTPAFirstPage>, <MTPALastPage> - These work in the same way as <MTPANextPage> and <MTPAPreviousPage>, but create links to the first and last pages in the sequence, respectively.

<MTPAEntryExtra entrynumber="NN">Some HTML goes in here</MTPAEntryExtra> - When used within the <MTEntries> tag, this will limit the contained HTML to only appear on the NNth entry on each page. For instance, if you want your Google adverts to appear after the first entry on each page, you could slip in a <MTPAEntryExtra entrynumber="1">(Advert HTML)</MTPAEntryExtra> before the closing </MTEntries>. Note: this currently only works if there are no line breaks in the enclosed HTML.

I think that covers all the changes! As always, you can download PagedArchives on the Paged Archives page.

[Edit: as first published the first argulent was erroneously listed as "entrycount" which it should have been "numofentries". My apologies for any problems caused.]

Posted at 8:08 PM | Comments (3)

December 20, 2007

Movable Type commenting tweaks

After my post about Blogger supporting OpenID for commenting, I decided I should enable OpenID on here as well. This lead to me having to overhaul the comment form (bringing it into line with the comment form in the default MT4 templates) so that everything would actually work. Unfortunately doing this had the side effect that any comments I made appeared as "Anonymous"

Why? Because I don't have MT Native authentication turned on (I don't see the point in getting people to register on my site just to comment on my entries). However the comment form javascript happily detected my MT login cookies and assumed I was a registered commenter, which caused the "Anonymous" effect. The simple solution was to turn on MT Native authentication, or so I thought...

Continue reading "Movable Type commenting tweaks"

Posted at 11:32 PM | Comments (1)

December 4, 2007

Movable Type's OpenID server plugin

Last week Blogger announced they were adding OpenID to their commenting system, so I thought I'd try my hand at installing the OpenID server which comes with MT4.

In the "extras" directory of the MT4 install zip, there's openid-server-1.1.zip. Looking at the contents of that zip, 96% of the files appear to be useless Subversion cruft. WTF? Having installed it, I tried to use it to comment on the Blogger In Draft post, and discovered that Blogger was giving me the somewhat cryptic name of "www". Now, there are other comments from users apparently using OpenID on that entry who have names displayed which don't appear to be derived from their URL. This appears to be an extension of OpenID, which isn't supported in the MT server or, more specifically, the Net::OpenID::Server perl module. The good news is that this module is still under development (the last release was in September) so it's possible that the extensiony stuff will be implemented in it.

While the MT version of the OpenID server plugin hasn't been updated since August 2005, there's a newer version of the plugin on MT-Hacks. This also uses the Net::OpenID::Server module which, though it's a newer version, still doesn't seem to support the extension. After taking a good look myself, it's beyond me how to extend the perl module to use aforementioned extensions, so instead I'm going to take a look at implementing a FOAF file, as suggested on the MT-hacks site...

Posted at 8:33 PM | Comments (2)

August 16, 2007

OB Movable Type 4.0 upgrade post

Well, isn't this user interface spanky and new? I've upgraded this weblog to MT 4.0. Do I like it? Hmmm, I don't know.

Usually when updating, I have to laboriously upload each file, because I keep them in different places to where they are in the zip file Sixapart gives me. This time I thought I'd be clever, so I rearranged them on my PC, made an archive file, uploaded it and extracted it on the server. Unfortunately I forgot that when I create a tar.gz on Window XP and unzip it on Linux, all the directories get created without their execute bits, and everything breaks. Ho hum.

The second hurdle was that the update wizard would not recognise my mt-static directory. It turned out that this was because it was trying to load mt.js by going through the web server, and it was using a libwww-perl user agent, which I have blocked in .htaccess (because a hacker uses it when he tries to hack my server), so I had to amend my .htaccess.

My only other problem was getting it to recognise one of my plugins (archivedateheader), which was fixed by changing the directory and filename of the plugin to all lower case (WTF?).

Now, what are the odds that when I hit the "Save" button, the whole thing will come crashing down in a heap?

Edit: It worked! But where has the list of categories gone from my index page? :P

Editedit: Fixed, I had to turn the MTSubCategories tags into MTTopLevelCategories tags. :P

Edit³: When I try to rebuild all categories, it says "An error occurred publishing category '1': Publish error in template 'Category Archive': Error in <mt:HasParentCategory> tag". I think I'm done with wrestling with it tonight though.

Posted at 8:35 PM | Comments (5)

June 16, 2007

Paged Archives v1.30

This release adds in a MTPAEntryLink tag, which is a paging-aware version of the standard MTEntryLink tag - you can use it to link to the Monthly or Category archive page which an entry appears on. It assumes you're not using the MTPASettings tag to alter the number of items per page, and that the items are in reverse chronological order. I might add an argument later to allow for forward ordering as well. This tag was requested by Blogosfere.

According to the MT wiki MT4 plugin compatability list, PagedArchives is compatible with Movable Type 4* - hopefully nothing in this release breaks that. I haven't downloaded the version 4 beta to look at yet.

You can download this plugin on the Paged Archives page.

* Though it would have been nice if it was listed in the "rendered obsolete" section.

Posted at 4:46 PM | Comments (49)

April 29, 2007

Collapsible archive listing

The list of months in the right-hand sidebar on my index page there was starting to get a bit long, and I noticed that Jamas and Paul had neat little collapsible lists on their blogs, so I decided to have a go at doing the same thing in Movable Type. It was easier than I expected, because I was able to adapt the javascript I use on the NZDWFC forums page which does something extremely similar.

The first step was to add the year headers using a slightly modified version of the ArchiveDateHeader plugin, the second was to add in the javascript (which consists of some initial javascript to show and hide the appropriate parts of the list, plus a function which is executed if you click on a plus or minus). The part which took the longest was tweaking the stylesheet to make it look goodnon-crap. :)

Continue reading "Collapsible archive listing"

Posted at 12:17 AM | Comments (1)

April 15, 2007

Paged Archives v1.24

This is a minor release to fix some problems a couple of people were having with the previous version. It seems that MT sometimes reports the main blog URL as having a filename on the end and sometimes it doesn't, so I'm using relative links instead now. Also I discovered that the plugin settings were available at both the system level and the blog level (PA was only using the blog level setting), so now it uses both.

Also I made a spiffy icon, which appears in the right-hand column on the main page here, but I don't know how to add it to the plugin itself. Eh.

There's a reported problem with it working with the MTEntriesWith SubCategories tag (According to the MT changelog this tag is depreciated in favour of using the include_subcategories on MTEntries) which I haven't had time to look into yet.

You can download this plugin on the Paged Archives page.

Edit: Despite me updating the plugin entry in the Six Apart plugin directory, the PA page there still says it's on v1.2. And it's still listed as "Paged Categories" on the Archiving categories page. Slack!

Posted at 11:33 AM | Comments (18)

February 25, 2007

Paged Archives v1.23

My original intention was to completely rewrite the PagedArchives plugin, test it over the course of the next week or so, and release it next weekend. However, having done 95% of the rewrite yesterday, I discovered that when I rebuilt all the category files, MT would only run P.A. on the last file built. Since it uses the same callback as version 1 which works fine, I can't fathom at all why that would be.

So instead I'm releasing a revised version of version 1 with some of the more pending issues raised in the comments on the P.A. v1.2 entry. The main issue which should now be fixed is the construction of navigation URLs (rather than the crappy method I was using to construct them before, I'm now using either the URL MT gives me, or constructing one using the same method used by MT).

Not fixed in this version (but hopefully should be in version 2) is the problem zero had of running out of memory.

You can get version 1.23 on the PagedArchives plugin page. If you're using this plugin, please report bugs in the comments here.

Posted at 4:57 PM | Comments (17)

November 16, 2006

Paged Archive bug request

My Paged Archives plugin has been pretty popular. Of course, with the amount of use it's getting, there's bound to be a few bugs cropping up, but so far they've been relatively minor.

I've been trying to help people with one bug which has cropped up, and which seems to be related to the way that the software constructs URLs when Movable Type is run on someone's own system rather than a separate site. Unfortunately neither of the people who reported the bug have replied to the last email I sent them, so I'm not sure if the question I asked helped them solve the problem or not.

If you're encountering the same problem when running PagedArchives on localhost and are willing to help me track down the problem, please comment here.

Posted at 6:33 PM | Comments (1)

October 27, 2006

Paged Archives v1.22

And, in short order, another bug fix to a bug (caused by the previous bugfix), which Chris at Digital Voodoo reported. It appears I overdid the slash removal and ended up with one missing! It should be fixed now...

Actual real entry to come.

P.S. Dear Boing Boing, please quit editing the Borat entry. Every time I open up Bloglines, I'm hit with an eyeful of Borat in that insanely small swim suit. MY EYES! THE GOGGLES DO NOTHING!

Posted at 7:12 PM | Comments (3)

October 25, 2006

Paged Archives v1.21

Minor bugfix to Paged Archives - there was a minor bug which on some configurations would cause page links to be constructed with double-slashes after the domain. A thank you goes out to Brendon Krueger who not only reported the problem but rendered assistance in establishing what was causing it. :)

Posted at 6:09 PM | Comments (2)

October 4, 2006

Paged Archives v1.2!

It's time, I guess, for my monthly Paged Archives plugin release! This will probably be the last one, barring any bugs... The main changes this time are some tags to handle date headers, which I'd neglected in previous versions, and a new way of constructing the URLs used in the page links (because it kept randomly using the Doctor Who archive URL for the Website Management pages. Weird).

You can read read about it and download it from the Paged Archives plugin page.

Edit: Please mote that the plugin will only work if you are statically publishing your blog with MT. It will not work if you are dynamically publishing using PHP files.

Posted at 6:40 PM | Comments (24)

September 3, 2006

Paged Archive Plugin v1.1

The Paged Archives Plugin is done! This superceeds the Paged Categories plugin - upgrading from one to the other is a simple matter of taking the old .pl file out, putting pagedarchives.pl in, and doing a search and replace on the tags in your category template. I'm using Paged Archives on my weblog now - only the categories and main index support though. My monthly archives don't tend to get all that large.

I've addressed pretty much everything raised in the previous discussion...

Posted at 11:46 AM | Comments (7)

September 2, 2006

Paged Archives Plugin

It took me a bit, but I've done some work on the Paged Categories plugin, and now it supports date archive types, and the main index as well. So I changed the name to Paged Archives. I think I've addressed everything in the comments section of the previous post! I even tried running it with Smart Rebuild, and I didn't run into any problems. I'll make up a page for it and make it available tomorrow.

One strange but related matter - I've noticed a number of people following the link from the SixApart plugin page seem to be converting the link URL to all-caps. I had to put in a redirect so they wouldn't get a 404 error. I can't see why this is happening, since the link on SixApart's site is all in lower case.

Posted at 9:29 PM | Comments (0)

August 6, 2006

Paged Categories plugin is go!

The paged categories plugin I mentioned here is all done and I've put it up for people to download and use. I've also added a Paged Categories plugin page from which it can be downloaded.

Next I'll submit it to the MT plugin directory, and then I promised someone I'd make some more Greg the Bunny Livejournal icons...

Posted at 3:44 PM | Comments (6)

<< 1 2
Search


Categories

Tetrap.com Site Map