Using Textile Markup with MediaWiki

“MediaWiki”:http://www.mediawiki.org/ is used extensively for documentation sites simply because it has so many features that make it ideal for this type of wiki application. The primary example is, of course “Wikipedia”:http://en.wikipedia.org

Naturally, I want to use MediaWiki for my own documentation sites. However, I use “Textile – a lightweight, humane web text generator”:http://thresholdstate.com/articles/4312/the-textile-reference-manual almost exclusively wherever HTML markup would otherwise be used. Also, I have to admit that I find the built-in MediaWiki markup verbose, ugly and counter-intuitive.

So, I was pleased to find a well written and documented MediaWiki extension which provides for alternative parsers, including textile. For some reason, the standard extension does not work on my sites. What I describe here is a simple mechanism to replace the TextilePHP parser with the Textile2 parser.

h3. Step One

Install the MediaWiki “AlternativeSyntaxParser extension”:http://jimbojw.com/wiki/index.php?title=AlternateSyntaxParser_Extension. Test it and if it works for you you’re done!

h3. Step 2

If the basic installation does not work, or if you want to try Textile2, add the following lines to @AlternativeSyntaxParser.php@ at about line #153

 case 'textile2':
    require_once('classTextile.php');
    $textile = new Textile();
    $text = $textile->TextileThis($parser->mSwappedOutText);
    break;

h3. Step Three

Download the Textile2 source from “here”:http://textile.thresholdstate.com/file_download/2/textile-2.0.0.tar.gz& and copy the file @classTextile.php@ to the same directory where the alternative parsers are.

h3. Step Four

Actually, you’re done! You now have another alternative parser ‘textile2’ available.

Once you have installed this, the editor buttons are no longer useful… maybe I’ll integrate “TheEditorHelper”:http://slateinfo.blogs.wvu.edu/plugins/textile_editor_helper/demo unless someone else gets it done first.

White Pages Insanity

The White Pages in Australia are being updated now. The publisher, Sensis, appears to think that the Internet can make them insanely rich — the cost of a listing including an email address and web site address is over $600 per year! That’s 10 times the cost of a phone number listing, and I didn’t even ask how much extra it would cost to have the listing printed in bold print.

Bear in mind that the person who looks up your phone number in the directory is already committed to contacting you. Therefore, the added value of the additional contact information has to be very close to *zero*.

The profit margin on these listing must be approaching infinity. It would be interesting to know how many small businesses are suckered into this rip-off. Unfortunately the White Pages web site doesn’t even have details of the cost of listings, let alone any statistics.

To put this in context, a small business can buy 200,000 targeted visitors to its web site for about $600

Gadgets and more

Did you know that I also publish a site called “Best PC Tools”:http://bestpctools.com? On that site I try to share information about tools (software, hardware and knowledge) which will help you get the best from your Linux or Windows PC.

Most of you will know that I believe that *He who dies with the most toys WINS* … Why not take a look at my “latest toy”:http://bestpctools.com/articles/2007/07/19/blueant-x5-bluetooth-headset.

It’s good to be a Kiwi!

For the last couple decades the America’s Cup competition has (generally) made good to be a Kiwi.

Even though I haven’t lived in NZ since I was a young boy, I have resolutely held on to my Kiwi citizenship (and passport). During the cold war I argued that this was actually a measure of self preservation as I figured that if WW3 did break out, NZ would be close to the bottom of the list of targets and I could therefore return home to comparative safety.

I also thought that, in the days when I did a lot of travelling, the NZ passport would be close to the Swiss in terms of insignificance. This proved to be wishful thinking as NZ proceeded to ignore the rest of the world opinion and play sport with South Africa, as well as antagonise the USA with an anti-nuclear policy.

Well, *we* are now within the proverbial cat’s whisker of challenging for the Cup again.

And it looks like, for the third time in a row, I will be in Auckland when the races are held. The amazing euphoria of winning. The universal, palpable, despondency of loosing, And the general feeling of pride that a nation of about 5 million souls can take on the world in a high budget contest and win will hopefully be there to be experienced when I am in Auckland later this month.

And, of course, the continued success of the All Blacks helps too!

New Hosted Service – MyEasyLinks.com

For a few years now I have used an Open Source software product called “SiteBar”:http://sitebar.org to store all of my bookmarks. Last week I set up a new hosted service based on SiteBar called “MyEasyLinks”:http://myeasylinks.com

New accounts on MyEasyLinks are *FREE* and an account will let you store all of your bookmarks on the MyEasyLinks server so that you can…

* have access to your bookmarks from any browser
* have access to your bookmarks from any computer
* share your bookmarks with friends, family or colleagues

If you use a computer in your office, and another at home, you’ll never experience that “What was that site” feeling!

Sign up now, while it’s still free.

Image editing on-line

Working with another new client last week lead, once again to a request for an easy way to edit photos ready for use in a shopping application.

One solution is to us Picnik an online photo editor which is quick, easy to use and with just enough features to do the job without the mass confusion that the desktop applications cause.

It’s definitely worth a look.

PHP 4.4.5 segfault fix

Quick tip for those of us unfortunate enough to have to deal with “legacy” php code (Ruby is Sooo much easier!).

One of my ISPs recently upgraded the PHP installation to 4.4.5 and suddenly my php application stopped. Nothing in the error log, no output to the browser.

I discovered that an attempt to @session_register@ an unitialised variable causes that build of PHP to segfault.

For example…

Will cause a segfault

<?php
session_start();
session_register("logon");
?>

No segfault

<?php
session_start();
$logon = "fred";
session_register("logon");
?>

I do not know if this is a generic issue or a consequence of the particular ISP’s build. But, I hope that this will help anyone else whose PHP application mysteriously stops!

I’m in MySpace

Earlier this month I took a look at MySpace and created my own “MySpace”:http://myspace.com/19seven

Tonight, I was taking a look at what was there and discovered that I can post to a “blog in myspace”:http://blog.myspace.com/19seven

I’ve posted a couple of thoughts sparked by that browsing including one that concludes…

bq. I am still at a loss to understand how most of the grown up world has completely forgotten that they were themselves mere portends of the End of The World when they were young themselves!

“Take a look”:http://blog.myspace.com/19seven