|
From: creedon <icr...@us...> - 2006-02-10 03:12:35
|
Update of /cvsroot/frontierkernel/odbs/prefsRoot/prefsSuite In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30855 Modified Files: drawNavigator Log Message: added separator parameter Index: drawNavigator =================================================================== RCS file: /cvsroot/frontierkernel/odbs/prefsRoot/prefsSuite/drawNavigator,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** drawNavigator 2 Apr 2005 23:09:51 -0000 1.1.1.1 --- drawNavigator 10 Feb 2006 03:12:27 -0000 1.2 *************** *** 1,3 **** FrontierVcsFile:1:scpt:prefsSuite.drawNavigator ! on drawNavigator (flbolditems = true) { Ç10/21/99; 2:13:03 PM by DW Çadded optional param, flbolditems, determines if the items are drawn in bold local (htmltext = "", indentlevel = 0); on add (s) { htmltext = htmltext + string.filledString ("\t", indentlevel) + s + "\r"}; local (pta = html.getpagetableaddress ()); Çscratchpad.params = pta^; edit (@scratchpad.params) local (thispagename = nameof (pta^.adrobject^)); local (baseurl = pta^.ftpsite^.url); local (adrnavigator = pta^.navigator); with adrnavigator^ { //compile the xml text if it's been modified local (flcompile = true); if defined (structure) { if timemodified (@outline) <= timemodified (@structure) { flcompile = false}}; if flcompile { xml.compile (string (adrnavigator^.outline), @adrnavigator^.structure)}}; local (itemlist = xml.getaddresslist (@adrnavigator^.structure [1], "item")); local (ct = sizeof (itemlist), i, adritem, name, pagename, linetext); for i = 1 to ct { adritem = itemlist [i]; name = xml.getattribute (adritem, "name")^; try { pagename = xml.getattribute (adritem, "pagename")^; local (strippedPageName = string.lower (pagename)); if strippedPageName endsWith "/default" { strippedPageName = string.mid (strippedPageName, 1, sizeOf (strippedPageName) - 7)}; local (strippedUri = string.lower (pta^.uri)); if defined (pta^.pathArgs) { if pta^.pathArgs != "" { strippedUri = strippedUri + "$" + pta^.pathArgs}}; if strippedUri endsWith "/default" { strippedUri = string.mid (strippedUri, 1, sizeOf (strippedUri) - 7)}; if flbolditems { linetext = "<b>" + name + "</b>"} else { linetext = name}; if strippedUri == strippedPageName { // was: if pta^.uri == pagename: PBS 5/21/99 add (linetext + "<p>")} else { add ("<a href=\"" + pagename + "\">" + linetext + "</a><p>")}} else { //instead of a pagename there may be a msgNum: PBS 5/21/99 local (msgNum = xml.getAttribute (adritem, "msgNum")^); if pta^.pathArgs == msgNum { add (linetext + "<p>")} else { local (msgUrl = pta^.responderAttributes.urls^.storyReader + msgNum); add ("<a href=\"" + msgUrl + "\">" + linetext + "</a><p>")}}}; return (htmltext)} \ No newline at end of file --- 1,3 ---- FrontierVcsFile:1:scpt:prefsSuite.drawNavigator ! on drawNavigator (flBoldItems = true, separator = "<p />") { ÇChanges Ç7/27/05; 1:56:14 PM by TAC Çadded separator parameter Ç10/21/99; 2:13:03 PM by DW Çadded optional param, flBoldItems, determines if the items are drawn in bold local (htmlText = "", indentLevel = 0); on add (s) { htmlText = htmlText + (string.filledString ('\t', indentLevel) + s + "\r\n");}; local (pta = html.getpagetableaddress ()); Çscratchpad.params = pta^; edit (@scratchpad.params) local (thisPageName = nameof (pta^.adrObject^)); local (baseUrl = pta^.ftpSite^.url); local (adrNavigator = pta^.navigator); with adrNavigator^ { //compile the xml text if it's been modified local (flcompile = true); if defined (structure) { if timeModified (@outline) <= timeModified (@structure) { flcompile = false}}; if flcompile { xml.compile (string (adrNavigator^.outline), @adrNavigator^.structure)}}; local (itemList = xml.getAddressList (@adrNavigator^.structure [1], "item")); local (ct = sizeof (itemList), i, adrItem, name, pageName, lineText); for i = 1 to ct { adrItem = itemList [i]; name = xml.getattribute (adrItem, "name")^; try { pageName = xml.getattribute (adrItem, "pageName")^; local (strippedPageName = string.lower (pageName)); if strippedPageName endsWith "/default" { strippedPageName = string.mid (strippedPageName, 1, sizeOf (strippedPageName) - 7)}; local (strippedUri = string.lower (pta^.uri)); if defined (pta^.pathArgs) { if pta^.pathArgs != "" { strippedUri = strippedUri + "$" + pta^.pathArgs}}; if strippedUri endsWith "/default" { strippedUri = string.mid (strippedUri, 1, sizeOf (strippedUri) - 7)}; if flBoldItems { lineText = "<b>" + name + "</b>"} else { lineText = name}; if strippedUri == strippedPageName { // was: if pta^.uri == pageName: PBS 5/21/99 add (lineText + separator)} else { add ("<a href=\"" + pageName + "\">" + lineText + "</a>" + separator)}} else { //instead of a pageName there may be a msgNum: PBS 5/21/99 local (msgNum = xml.getAttribute (adrItem, "msgNum")^); if pta^.pathArgs == msgNum { add (lineText + separator)} else { local (msgUrl = pta^.responderAttributes.urls^.storyReader + msgNum); add ("<a href=\"" + msgUrl + "\">" + lineText + "</a>" + separator)}}}; return (htmlText)} \ No newline at end of file |