You’re reading all articles tagged 'movabletype'

Move away from MovableType?

15 May 2004

To put it mildly, there has been a little brou ha ha over SixApart’s announcement to charge for MT 3.0 (for a more level headed opinion, go read Jason Santa Maria’s thoughts, which echo my own exactly).

However, I’ve been considering moving away from MT for a while, as it has always irked me having to rebuild so much. Now that my journal is starting to get a healthy amount of entries, I can easily fix myself an omelette sandwich while it chugs away. It makes MT feel quite clunky for me.

One of the options I’ve been fiddling with for a few months is Textpattern, and its impressed me with the speed at which it allows me to work. One of its many nifty features is a preference to automatically close comments on entries after a cetain length of time. This is the best way to defeat comment spam, and I’m not clever enough to know how to set up a cron job to do it for me.

There’s a lot to overcome with TP though – it has its own idiosyncratic names for things – e.g ‘forms’ are not actually ‘forms’ but ‘reusable chunks of content’. Another drawback is that you’ll have a hard time getting to run in ‘clean URL mode’ on certain servers. If you’re using server where you have access to the config files all well and good, but many may find it a bit torturous to get it working on their shared server hosting account. Nevertheless, its an attractive possibility.

The other option that I’m starting to consider is Wordpress, which has been Eric Meyers choice of CMS. I’m trying this out now, and I’ll let you know what I think. My initial run with it was very encouraging.

There are still many advantages for me to stay with MT. Its very flexible, and lends itself to content management outside the world of blogging. For instance, a single installation of MT can be used to power multiple blogs easily – thats how this site works, a blog for every section. With tools like Wordpress, you have to create a new installation every time, and if using the same database, create a new table prefix to avoid wiping over other data. MT also give you more options, other than the standard ‘Title, Body & Excerpt’ fields. This was vital when I created my portfolio site.

So no decisions yet. If MT 3.0 is the right tool, I will pay for it, but I’m feeling led away from the chugging…


Flip Flop

01 Dec 2003

A few folks have asked me how I created the alternating background colours in the comments sections. I use a Movable Type plug-in called ‘Flip Flop’, written by a chap called Gavin Estey. I’d been wanting to use this for a while, and finally got around to implementing it.

All you need to do is create the 2 alternating styles (an odd and an even) in your css, and then put the following code into your MT template. In this simplified example, I’ve used ‘green’ and ‘white’ as my 2 options.

CSS:

/* MT Flip Flop styles */
.green {
	padding: 8px;
	background: #EEF7DD;
}
.white {
	padding: 8px;
	background: #fff;
}

Movable Type:


<MTComments>
<div class="<$MTFlipFlop odd="green" even="white"$>">
<$MTCommentBody$>
</div>
</MTComments>

The Flip Flop plug-in then decides which style it needs to use. Thanks Gavin!


comment spam

23 Oct 2003

So I finally got targeted with some comment spam, I suppose it had to happen at some point. What I really hate is if I hadn’t been around to delete and IP ban them immediately, it would be just be sitting there, giving the site bad karma. Little buggers.

So, I’ve installed Jay Allen’s MT Blacklist plug-in, and I’m giving it a whirl. If you use a similar system, help yourself to my blacklist.


MT author comment notification

17 Oct 2003

If you’ve ever left a comment-reply to users who’ve left comments on your site – you’ll get a email notification the same as you do for every commenter. This can prevented however.

Go to lib/MT/App/Comments.pm in your MT folder and find the line that reads:

MT::Mail->send(\%head, <<BODY); 

This is on line 152 if you’re using MT 2.64. Change it to:

MT::Mail->send(\%head, $body) unless $author->email eq $comment->email;

And you’re done. However, if you’re using Jay Allens MT Blacklist plug in, you’ll need to change the code in the Blacklist.pm file instead. ScriptyGoddess shows you how.


I know what I said!

02 Oct 2003

Quick Movable Type hack. If you ever reply to users who’ve left comments on your site – you’ll get a email notification the same as you do for every commenter. Via the Movable Type support forum, I found a way of stopping it. Go to lib/MT/App/Comments.pm in your MT folder. Find the line that reads:

MT::Mail->send(\%head, <<BODY); 

This is on line 152 if you’re using MT 2.6. Change it to:

MT::Mail->send(\%head, $body) unless $author->email eq $comment->email;

And you’re done.


a links database with MT

04 Sep 2003

Inspired by recent articles on how to use Movable Type for more than just blogs, I’ve been trying this out on more areas of the site. The news, articles and album cover playlist sections are MT powered, and now the links database is too. This means I can now add content to the site from either the web or from my weblog editor in NetNewsWire.

The technique has been well documented on many blogs, (wholelottanothing’s is very well written) so I’ll skimp a bit. First I created a new blog called ‘links’ and removed templates I wouldn’t need (such as the stylesheets and individual entry archives). I also set archiving to ‘category’ and turned comments and convert line breaks off. Then I decided which MT tags to use for which piece of data:

I inserted these tags into the main MT Template:


<MTCategories>
<h3><$MTCategoryLabel$> (<$MTCategoryCount$>)</h3>
  <MTEntries lastn="100" sort_by="title" sort_order="ascend">
	<p><a href="<$MTEntryKeywords$>" title="visit <$MTEntryTitle$>">
	  <$MTEntryTitle$></a> // <$MTEntryBody$></p> 
  </MTEntries>
</MTCategories>

This then creates a page, listing all the links within their categories. The tags in the category archives page (where just one category of links is shown) needs to be slightly different:

<h3><$MTArchiveTitle$> (<$MTArchiveCount$>)</h3>
  <MTEntries lastn="100" sort_by="title" sort_order="ascend">
	<p><a href="<$MTEntryKeywords$>" title="visit <$MTEntryTitle$>">
	<$MTEntryTitle$></a> // <$MTEntryBody$></p> 
</MTEntries>

To get the links to display in alphabetical order, add sort_by=“title” sort_order=“ascend” to the MTEntries tag. I used

tags to list each link – you may prefer an unordered list. ‘MTCategoryCount’ shows the number of entries in that category. To make adding links easier, you can customise the ‘new entry’ form in MT, so that it only shows the fields you want to use – Title, Category, Entry Body and Keywords. The last thing I needed to do was create the list of link categories for the main menu. I created a new index template called ‘droplinks.php’ in the links blog, which just contained the following:


<MTCategories>
<li>
<a href="<$MTCategoryArchiveLink$>" title="<$MTCategoryLabel$> links">
<$MTCategoryLabel$> (<$MTCategoryCount$>)</a>
</li>
</MTCategories> 

This is then called up an include in the main navigation under ‘destinations’. Job done.


Next – how to build your own house and landscaped garden using MT…


Instagram Hickstagram

  • 17 Jun 2018

    There’s something I love about this bit of road coming into Leafield

  • 09 Jun 2018

    Ride out to Kelmscott to test the new frame! Nice 40 mile loop in the sunshine ☺️

  • 09 Jun 2018

    The things you find on Freecycle. Tempted to reply that the council might want it back?

  • 09 Jun 2018

    Lovely morning dog walk at North Leigh Common

  • 07 Jun 2018

    Signs of wife

  • 30 May 2018

    O triptych

  • 28 May 2018

    Today’s working view

  • 24 May 2018

    Waiting…

  • 23 May 2018

    Dozing off

  • 23 May 2018

    Positivity

Contact us

Call Jon on +44 (0)7917 391536, email or tweet @hicksdesign.

Alternatively, pop in for tea and cake at the studio…

Hicks
Wenrisc House
Meadow Court
Witney, OX28 6ER
United Kingdom