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


on deletePost (username, urlstory) {
		<<7/12/10; 8:13:37 AM by DW
	local (adrdata = scripting2suite.inituser (username), startticks = clock.ticks (), type, adrstory);
	scripting2Suite.server.urlToStory (username, urlstory, @type, @adrstory);
	if type == "stories" {
		adrstory^.flDeleted = true;
		scripting2suite.server.buildAfterDelete (username, adrstory);
		bundle { //logging, 7/2/10 by DW
			local (htmltext = "User \"" + username + "\" deleted <a href=\"" + adrstory^.url + "\">" + adrstory^.title + "</a>.");
			scripting2Suite.server.addToLog (, "Delete post", htmltext, startticks)}}};
bundle { //test code
	deletePost ("davewiner", "")}

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.