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

	<<3/29/02; 3:25:06 AM by JES
		<<Ask if we should subscribe to this outline, if we're not already. If the user clicks OK, the subscribe, and go ahead an expand the node. If the user clicks Cancel, don't do anything.
	<<3/27/02; 1:59:51 AM by JES
		<<If the openUrl cache contains a cloud table, copy it to the cloudInfo sub-table of this node's subscription table.
	<<3/23/02; 12:13:44 AM by JES
		<<Implemented and then backed out high-level caching code.
	<<3/13/02; 10:28:08 AM by DW
		<<Created. Expand exactly as the "link" nodetype does, with one exception, if the headline is bold, unbolden it.
<<op.deleteSubs ()
local (atts); op.attributes.getAll (@atts);
bundle { //ask if we should subscribe to this outline, if we're not already
	local (adrdata = radio.outliner.init ());
	local (adrsub = @adrdata^.subscriptions.[atts.url]);
	if not defined (adrsub^) {
		local (flSubscribe = false);
		local (adrwin = window.frontmost ());
		if adrwin == @adrdata^.buddies {
			local (oldDisplay = op.getDisplay ());
			op.setDisplay (false);
			if not op.go (left, 1) {
				flSubscribe = true}
			else {
				op.go (right, 1)};
			op.setDisplay (oldDisplay)};
		if not flSubscribe {
			if dialog.confirm ("You are not currently subscribed to " + op.getLineText () + "'s outline. Subscribe now?") {
				flSubscribe = true}};
		if flSubscribe {
			radio.outliner.subscribeUrl (atts.url, flOpenBuddies:true)}
		else {
local (olddisplay = op.getdisplay ());
op.setdisplay (false); ();
bundle { //get cloud info
	local (adrcloud);
	if radio.outliner.getCloudInfoFromCache (atts.url, @adrcloud) {
		local (adrdata = radio.outliner.init ());
		adrdata^.subscriptions.[atts.url].cloudInfo = adrcloud^}};
<<bundle //high-level cache code -- not in use
	<<local (adrdata = radio.outliner.init ())
	<<local (adrsub = @adrdata^.subscriptions.[atts.url])
	<<if atts.bold
		<<radio.outliner.initSubscription (adrsub)
		<< (atts.url, @adrsub^.outline)
	<<op.insertOutline (@adrsub^.outline, right)
if atts.bold {
	local (lt = op.getlinetext ());
	lt = string.replace (lt, "<b>", "");
	lt = string.replace (lt, "</b>", "");
	op.setlinetext (lt);
	atts.bold = false;
	op.attributes.addgroup (@atts)};
op.setdisplay (olddisplay)

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.