Monday, November 08, 2010 at 12:03 AM.
system.verbs.builtins.html.addToChangedPages
on addToChangedPages (adrPage) { //4.2
<<Return true if we added the page to the Changed Pages list.
<<Pages that are exempt:
<<anything that's not contained within root.websites
<<any item whose name begins with #
<<any item contained in a table named glossary, tools or images
<<tables
<<Fri, Dec 20, 1996 at 7:35:24 AM by DW
<<Revised 12/6/98 by PBS:
<<Now works with guest databases.
local (flFoundFtpSite = false);
if typeOf (adrPage^) == tableType {
return (false)};
bundle { //shoot out to top of db, looking for reasons not to build the page
local (nomad = adrPage);
loop {
if html.traversalSkip (nomad) {
return (false)};
nomad = parentOf (nomad^);
<<Is there an #ftpSite table? PBS 12/6/98
case true {
defined (nomad^.["#ftpSite"]);
defined (nomad^.["#prefs"].["#ftpSite"]);
defined (nomad^.["#prefs"].["ftpSite"]) {
flFoundFtpSite = true}};
if nomad == "" {
break}}};
if not flFoundFtpSite { //no #ftpSite found, it's not a page: PBS 12/6/98
return (false)};
if not defined (user.html.changedPages) { //make sure the changed pages outline exists
new (outlinetype, @user.html.changedPages)};
local (oldTarget = target.set (@user.html.changedPages));
op.firstSummit ();
if not op.FindNext (adrPage) {
if op.getLineText () == "" {
op.setLineText (adrPage)}
else {
op.insert (adrPage, up)}};
try {target.set (oldtarget)};
return (true)}
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.