Monday, November 08, 2010 at 12:05 AM.

on writeRsdFile (f, adrblog=radio.weblog.init ()) {
		<<12/18/02; 7:23:05 AM by DW
			<<Update to bring into compliance with 1.0 format.
		<<12/13/02; 8:56:02 AM by DW
	local (xmltext = "", indentlevel = 0);
	on add (s) {
		xmltext = xmltext + string.filledstring ("\t", indentlevel) + s + "\r\n"};
	on encode (s) {
		if system.environment.isMac { //02/22/2001 JES: convert to Latin text
			return (xml.entityEncode (latinToMac.macToLatin (s), true))}
		else {
			return (xml.entityEncode (s, true))}};
	add ("<?xml version=\"1.0\"?>");
	add ("<rsd version=\"1.0\" xmlns=\"\" >");
	add ("<service>"); indentlevel++;
	add ("<engineName>" + frontier.getprogramname () + "</engineName>");
	add ("<engineLink></engineLink>");
	add ("<homePageLink>" + radio.weblog.getUrl (adrblog) + "</homePageLink>");
	add ("<apis>"); indentlevel++;
	add ("<api name=\"MetaWeblog\" preferred=\"true\" apiLink=\"\" blogID=\"home\"/>");
	add ("<api name=\"Blogger\" preferred=\"false\" apiLink=\"\" blogID=\"home\"/>");
	add ("</apis>"); indentlevel--;
	add ("</service>"); indentlevel--;
	add ("</rsd>"); indentlevel--;
	file.writewholefile (f, xmltext)} //write out the XML file
<<bundle //test code
	<<writeRsdFile (radio.file.getAbsolutePath (

This listing is for code that runs in the OPML Editor environment. I created these listings because I wanted the search engines to index it, so that when I want to look up something in my codebase I don't have to use the much slower search functionality in my object database. Dave Winer.