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

scripting2Suite.editor.deletePost

on deletePost () {
	<<Changes
		<<7/12/10; 8:59:35 AM by DW
			<<Created. 
	local (adrdata = scripting2suite.init (), lo = address (window.frontmost ())^);
	local (oldtarget = target.set (@lo));
	op.firstsummit ();
	local (title = op.getlinetext (), urlstory);
	op.attributes.getone ("url", @urlstory);
	if dialog.confirm ("Deleting " + title + ". There is no Undo!") {
		local (username = adrdata^.editor.prefs.username);
		local (password = string (adrdata^.editor.prefs.password));
		local (server = string (adrdata^.editor.prefs.server));
		[server].scripting2.deletePost (username, password, urlstory)};
	target.set (oldtarget);
	op.firstsummit ();
	op.deleteline ()};
bundle { //test code
	deletePost ()}



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.