memo2html

28th May 2003
(last updated: 5th July 2003)


What is it?

memo2html is a perl script for users of a Palm Pilot. You add a few simple tags (like @file index.html) to some memopad files, hotsync, double-click the script and the tagged files are converted to interlinked html pages, which the script can (optionally) FTP to your website.

Here are my pages, as generated by memo2html.

Why?

I made a lot of notes on my Palm, and decided I needed something to convert some of them for the web. First I tried to use Eric Anderson's pilot2html, but after playing with it for a while, I decided to roll my own. A lot of credit is due to Eric, however, as he has provided the MemoPad.pm perl module that allows memo2html to read the memos - without that, none of this would be possible.

What could memo2html be used for?


More details

Non-tagged memo files will be ignored by memo2html.

Missing index files will be generated automatically.

memo2html generates the collection of html files from the memopad database file, stored on the desktop PC as memopad.dat when you hotsync. This means that any changes you make to the html files are overwritten each time you run memo2html. Work only from the Palm Pilot if you want to change your pages.

If you use the FTP option, directories are created as necessary, but old files and directories are not removed prior to upload. This means that old 'dead' files may sometimes linger - just empty the relevant FTP directories occasionally and you should be fine.

Download

Requirements:
Required files: Here is a handy ZIP archive of all the files above (except the perl interpreter) and a README.

Note: Some configuration of memo2html is absolutely necessary before use. Read on...

How to use memo2html

Now, assuming you have met all the requirements above, and that I haven't forgotten anything, this is what should happen next:
  1. Create some memos on your palm pilot. On the first line, write @file your-filename.html. On the second line, specify a category with @cat your-category-name (note: these do not have to match any memopad categories) Whatever you write on the third line will become the page title.
  2. Edit the memo2html.pl file in a normal text editor. In the 'Settings' section, ensure that the path to your Palm Pilot data directory is set. If you wish to use the FTP option, enter the details of your FTP account in the appropriate places. You will be prompted for your password when the script is run.
  3. Double-click the memo2html.pl script
  4. You should see some text output, describing the number of files converted. HTML files will appear in the directory specified as $output_dir in the script (relative to the script). You can specify "." as the output directory if you wish the new html files to appear in the same place as the script.

Layout of files on the Palm Pilot

Firstly, it doesn't matter what memopad category your files are in. It is the @cat line that defines which category the resulting html pages will be placed in. Memopad categories are entirely ignored.

A typical memopad file would look like:



After creating this file, memo2html will automatically create an index for the 'notes' category. However, if you create a file called 'index.html' in a category, then your index.html file will override this feature, and you'll have to manually update your index file whenever you create new files. If you don't do this, then noone will be able to find links to these pages. You might want to see the section 'Further Notes' to find out how to create hyperlinks.

Further notes

Useful hint: to insert the current date into a memo, draw a cursive 'l' with your stylus (like ), then the letters d s (more info).

Contact details

If you have any problems with the above, send an email to with the subject line 'memo2html'.

Author's website

http://www.duncanjauncey.com

Credits

A big thanks to Eric Anderson for writing the MemoPad.pm perl module, and to Debbie Peckenpaugh for contributing the zip file and associated README.