space Baylys
Just practicing to pass the Turing test.
space
space
space
space
Developer for Hire!
space
addedValues Plugin
space

Home

What's new

Bayly.Root

space

Bounce suite.

commentit

fingerServer Suite.

hierMenus Plugin

ManilaFixer Plug-in

space
space

Access Control

Attached Documents

Controlpanel Interface

Hourly Hits Chart

Import Functions

manilaExtras Macros

space
space

accessTimestampString Macro

allhourlyHIts Macro

alternateTemplateLink

areaTag Macro

attachedDocuments

bodyTag Macro

breadcrumbs Macro

csActionDict Macro

editorialMenu

getnamedLink Macro

hourlyHits Macro

includenews Macro

insertBaseTag Macro

loginForm

marknonCachable Macros

memberAttribute

messageAttribute Macro

messageCohorts Macro

messageExpiryDate Macro

messageReleaseDate Macro

messageViewers

metaRefresh Macro

pathAtt Macro

pathAttToIncludeMessage Macro

pathDirectiveValue Macro

pathPictureURL Macros

pictureRef Macro

renderOutline Macro

renderScript Macro

SCNSCall Macro

shortCutToMsgNum Macro

shortCutToPictureMsgNum Macro

shortCutURL Macro

siteCrossLink Macro

siteMenu Macro

siteStructureMap Macro

spacepixels Macro

storyAuthor Macro

statsGifPage Macro

embed Macro

space

Obscure Preferences

OPMl undo

TurboCache

Versioning

space

mrdebugger

Navigator Ticker Plugin

Sendmail Suite

TranslateAid plugin

Whois Macro

Cornershop Plugin

Career

edutools Root

Enhancements

Interests

linguist Plugin

Manila

Patches

Patches by Group

Papers

Sales

Sign My Guestbook

User(land) Relations.

Contact Address

Search Baylys

urlchains

space
Join Now
Login
space space space

renderScript Macro

This macro renders a Frontier script to HTML, with an emphasis on showing changes labelled with " by DAB" and displaying only that part of the script which is needed to locate the changes.

Parameters

  • adr - the name of a script anywhere in your Frontier roots(address)
  • flShowAll (optional, default false) - if true lists the whole script, rather than changed areas

Example

{ManilaExtras.renderScript("ManilaExtras.renderScript")}

Displays

on renderScript (adr=nil, flShowAll=false, flShowFrontierVersion=true) «this is a macro that gets a script listing
  «01/04/24, 12:06:36 by DAB
  «based upon user.html.macros.renderscript
  «02/04/13, 19:25:14 by DAB
  «add flShowAll parameter to list a complete script.
  local (htmlText)
  on add(s)
 unaltered lines omitted
 
  if adr == nil
 unaltered lines omitted
  if not ({scriptType, outlineType} contains typeof (adr^)) «01/07/10, 09:22:10 by DAB
  return ""
 
  local (oldTarg = target.set (adr))
  op.setDisplay (false)
  op.firstsummit ()
  op.fullexpand ()
 
  local (level = 0)
  on visit (inComment, flUpLevlIsPatched)
  local (htmlText = "")
  on add(s)
 unaltered lines omitted
 
  local (flPatchSeen = flUpLevlIsPatched)
  loop
  local (hassubs = op.countSubs (1) > 0)
  local (flComment = inComment or script.isComment())
  add("\r<table class = 'renderScript' width = '100%' vspace='0'>\r\t<tr>")
  if level > 0 «add a dummy cell to do the indentation
 unaltered lines omitted
  local (linetext = op.getlinetext ())
  local (flisBundle = (string.lower(linetext) beginswith "bundle"))
  linetext = string.replaceAll (linetext, "<", "<")
  linetext = string.replaceAll (linetext, "!=", "!=")
  linetext = string.replaceAll (linetext, "\"", """) «03/03/02, 16:56:19 by DAB
  linetext = string.replaceAll (linetext, "\\", "\") «03/05/25, 16:44:59 by DAB
  linetext = string.replaceAll (linetext, "@", "@") «06/05/06, 15:13:53 by DAB
  if hassubs
 unaltered lines omitted
  «add("\r\t\t<td><code")
  «add("\r\t\t<td><span")
  add("\r\t\t<td")
  local (flLineIsPatched = (linetext contains " by DAB" ))
  if flLineIsPatched
 unaltered lines omitted
  «if flLineIsPatched or flUpLevlIsPatched
 unaltered lines omitted
  if (flLineIsPatched or flUpLevlIsPatched) and not flShowAll «02/04/13, 19:29:18 by DAB
  add(" class = patchedText")
  add(">")
  if flComment
 unaltered lines omitted
  «add(linetext + "</code></td>\r\t</tr>\r</table>")
  «add(linetext + "</span></td>\r\t</tr>\r</table>")
  add(linetext + "</td>\r\t</tr>\r</table>")
  if hassubs
 unaltered lines omitted
  if not op.go (down, 1)
 unaltered lines omitted
  if level > 1 and not flPatchSeen
 unaltered lines omitted
  return htmlText
 
  add("\r<div class = 'renderscript'>")
  «add("\r<blockquote>")
  add(visit (false, flShowAll)) «02/04/13, 19:25:55 by DAB
  «add(visit (false, false))
  «add("\r</blockquote>")
  if flShowFrontierVersion
 unaltered lines omitted
  add("\r</div>")
 
  op.setDisplay (true)
  try {target.set(oldTarg)}
 
  return manilaSuite.unTaint(htmltext)
bundle
  wp.newTextObject(renderscript(@manilaSuite.rpcHandlers.message.listPictures), @temp.renderScript)
  edit(@temp.renderScript)

Relative to Frontier version 9.7b10