Smarter navigation

Richard Gaskin ambassador at fourthworld.com
Wed Sep 3 16:47:01 EDT 2003


FlexibleLearning at aol.com wrote:

> I know about recentNames, go back/forth etc etc. The task is to script
> Browser-like navigation logic and implementation, both for the 'Back' and
> 'Fwd' buttons, along with a 'BackList' and 'ForwardList' whilst maintaining
> the ability to add to the 'BackList' with new cards as required.
> 
> Perhaps I am overlooking the blindingly obvious, but I don't think so. The
> built-in backList is not intelligent enough, hence the subject line of
> 'Smarter Navigation'.

Something like this might do the trick in a frontscript, or if you always
pass messages it can reside in a backscript or library:

on preOpenCard
  global gMyBackList, gMyTrackedStacks
  get the short name of this stack
  if (it is among the lines of gMyTrackedStacks) then
     put the long id of this cd &cr before gMyBackList
  end if
  pass preOpenCard
end preOpenCard


Put this one anywhere in the message path, and call it from any controls
that need it:

on MyGoBack
  global gMyBackList
  go (line 1 of gMyBackList)
  delete line 1 of gMyBackList
end MyGoBack


-- 
 Richard Gaskin 
 Fourth World Media Corporation
 Developer of WebMerge: Publish any database on any Web site
 ___________________________________________________________
 Ambassador at FourthWorld.com       http://www.FourthWorld.com
 Tel: 323-225-3717                       AIM: FourthWorldInc




More information about the metacard mailing list