Language Elements Open in a window of its own Home

Choose the application scope to display
Name or part of the name of function to search:

The language structures

1 - A statement

replace all CUST_NAME with "Inactive" for CASH_BAL < 1 .and. LAST_OP < ctod("01/01/2015") 

2 - A chunk (containing a single statement)

<% store 0 to CASH_BAL, INIT_VAL, MIN_AMNT %> 
3 - A chunk (more consistent) and that do the same things of previous one but with 3 short statements

4 - A large chunk (written in classic CGI style)

cPath := setDb("customers")
use (cPath + "usr_accounts.dbf") alias MASTER
print( [<table class="table">] )
do while not eof()
   print( [<tr>] )
   print( [<td>] + master->CASH_BAL + [</td>] )
   if master->CUST_STATUS="active"
      print( [<td>] + master->INIT_VAL + [</td><td>] + master->MIN_MANT + [</td>] )
   print( [</tr>] )
print( [</table>] )

5 - Same chunk (written in ASP style)

cPath := setDb("customers")
use (cPath + "usr_accounts.dbf") alias MASTER 
<table class="table">
<% do while not eof() %>
   <td> <%=master->CASH_BAL%> </td>
   <% if master->CUST_STATUS="active" %>
      <td> <%=master->INIT_VAL%> </td><td> <%=master->MIN_MANT%> </td>
   <% endif %>
   <% skip

6 - Javascript injection

<%=cTxt := fileread("c:\dbfree\configuration.txt") %>
<script type="text/javascript">
alert('Current configuration is: <%=cTxt %>'); 

7 - A construct (control structure)

if nAccountBalance < 30
   alarm("Your account is under minimum terms.")
elseif (nAccountBalance > 30 .and. nAccountBalance < 100)
   box("You can proceed but your credit is very low!")
   print( button("/apps/hb/start.msp","Access on-line accounting") )

8 - Another construct for control structure (doing the same job, but more flexible)

do case
case nAccountBalance < 30
   alarm("Your account is under minimum terms.")
case (nAccountBalance > 30 .and. nAccountBalance < 100)
   box("You can proceed but your credit is very low!")
case (nAccountBalance > 100 .and. nAccountBalance < 500)
   box("You can proceed but your should renew your credit!")
   print( button("/apps/buy/start.msp","Buy more credits") )
   print( button("/apps/trade/start.msp","Go to Trading") )
   print( button("/apps/hb/start.msp","Access on-line accounting") )

9 - Simple comparison (numbers/dates)

if nnn >= 2
   ? "The number is greater or equal to two"
elseif nnn <= 1
   ? "The number is smaller or equal to one"

Practical Examples

10 - A confrontation (strings)

cProposedKey := getPassword()
cCorrectKey  := users->PASSW_STR
if upper(cProposedKey) == upper(cCorrectKey)
   print( button("/login/ok.msp","Enter site") )
   alarm("Sorry! Password is wrong.")
   print( button(cSelf,"Retry") )
   print( button("/home.msp","Discard") )

11 - A substitution (strings)

cOldFile := "myfilename.htm"
cNewFile := subs(cOldFile,".htm",".bak")

12 - A verification (file)

cNewFile := "myFileName.bak"
if not file(cNewFile)
   copy file (cOldFile) to (cNewFile)

13 - Another verification (strings)

if contains(cNewFile,".htm")
   //-- do something

14 - Another verification (variables)

xVar := "cNewFile")
if vtype(cNewFile)="U"
   ? "Variable cNewFile not declared!"

15 - A chunk of statements (databases)

cDir := setDb3("demo")
cTable := cDir + "customers.dbf"
if file(cTable)
   use (cTable) in 0 alias MASTER
   alarm("Table " + cTable + " does not exist!")

List of language elements

aadd P#:_2017-0--009

aadd(aArray, xVal)
Class arrays
 Grows an existing array of one element (add at the end)

adimens P#:_2017-0--011

adimens( aaa)
Class arrays

aGrow P#:_2017-0--008

Class arrays
 Grows an existing array to the desired number of elements
 returns the number of new element added 

amfind P#:_2017-0--013

Class arrays
 Array multi finder
 Accepts a single-dimension array and returns a string
 with all elements matching the given key.
 The returned string contains elements position separated by square bracket:
 ? ccc := amfind(test,"b")

amprint P#:_2017-0--017

Class arrays
-- prints out the content of a 2D array (matrix)
   If used with a single dimension returns nothing.
 second parameter is numeric: if passed determines the type of putput
 none or 0=elements seprated by blanks,1=separated by a paragraph sign,2=using a
 format compatible with parsestr(),3=a format for ini file
 This function can be used to store matrixes directly into an ini.file (3) or 
 into a table memo field (2)
 Feb 13,2016

amSize P#:_2017-0--015

Class arrays

aprint P#:_2017-0--010

aprint(aaa, cSep)
Class arrays
 Prints out the content of an array (vector) separated by a sseparator
 The second parameter defines the char to use as separator (default is :).
 ? aprint(test)

areverse P#:_2017-0--018

Class arrays
 Reverse the order of the elements of an array
 WARNING: The original array gets modified irreparably!
 Also returns a string with the array elements reordered

aseek P#:_2017-0--012

Class arrays

aSize P#:_2017-0--001

aSize( MyArray )
Class arrays
-- return the dimension of a matrix (a 2D array) as string

atos P#:_2017-0--005

Class arrays
-- array to string  (IMPROVED NOV 2014))

matrix P#:_2017-0--016

matrix(aName, nRows, nCols)
Class arrays
-- creates a rectangular (bi-dimensional) 2D matrix
   filled with strings that represent the cell address
   in form row-column

newarray P#:_2017-0--014

Class arrays

square2str P#:_2017-0--007

square2str(aArr, cSep, cDiv)
Class arrays
-- trasforma un array (matrice quadra) in stringa
   parametro: tipo di separatore

str2arr P#:_2017-0--003

str2arr(cStr, cSep, aaa)
Class arrays
 wrapper for StrToArr()

StrToArr P#:_2017-0--004

StrToArr(cStr, cSep, aaa)
Class arrays
 cString := "mia&martini&grande&cantante"
 accepts a string with words separated by a separator and returns 
 an array with as many elements as where the words

StrToNumArr P#:_2017-0--002

StrToNumArr(cStr, cSep, aaa)
Class arrays
 Converts a string to a numeric array:
 cString := "100&12&5&24"

vector2str P#:_2017-0--006

vector2str(aArr, cSep)
Class arrays
-- accapts a single-dimension array (a vector) and returns a string
   second (optiona) parameter is the char to use as separator

listWebs P#:_2017-0--019

Class beta

alarm P#:_2017-0--024

Class bootstrap
-- opens a dismissable alert box from inside a chunk
   (to be used for alarm messages in the headers and the like)
   Dec 18,2015

alert P#:_2017-0--025

Class bootstrap
 builds a dismissable box with a message
 Parameters:  Title, message, a number for the color;
 1=warning, 2=info, 3=success, 4=danger
 0=expects a 4th parameter with a string for the style to use
 defaults to 1  
 if cStyle is passed will be used instead of defaults
 WARNING: if is to be passed to javascript just use box()
          while if used in retro-style programming use
          the wrapper alarm()
 Dec 18,2015

alertBox P#:_2017-0--073

Class bootstrap
-- opens and closes an alert box
   nOpt= empty or 1 -- opens, 0 -- closes
   Nov 22,2015

badge P#:_2017-0--031

badge(cStr, cPos, cStyle, cId)
Class bootstrap
-- generating a badge
   p1 -- text to show inside the badge
   p2 -- position of the badge, "L"=Left, "R" or 1=right, empty=none
   p3 -- optonal style string
   p4 -- optional DOM ID (name will be identical but in uppercase))
 Dec 15,2015 - Aug 27,2015 - Sep 7,2016

bottomline P#:_2017-0--076

Class bootstrap
 Returns a fixed DIV for a bottom line
 Parameters are: Text to show, text color, background
 Dec 1,2015

box P#:_2017-0--022

box(cMsg, nVal, cType)
Class bootstrap
 Similar to alert but opens and closes the box
 cMsg -- if empty just opens the box (then pass box(0) to close it)
 nVal -- none or 1 = open the DIV, accepts an optional text to display
 0 = closes the DIV 
 2 = info, 3=succes, 4=warning, 5=danger
 Third parameter: if passed causes to return a string suitable to be passed 
 to javascript (no CR_LF) 
 Passing a TEXT as first parameters returns a white box with text

btn2str P#:_2017-0--082

Class bootstrap
-- reserved for internal use

btnHide P#:_2017-0--080

btnHide( cLabel, nType, cDomID, cStyle, cImage, cPull, nExcl)
Class bootstrap
 Creates a button and a hidden DIV:
 p1 -- Text to show in the button body -- passing a zero (N) closes the div
 p2 -- type of button from 1 to 20 (default 2)
 1-5=small, 5-10=medium, 10-15=large, 15-20=block
 add 1=primary, 2=success,3=info,4=warning,5=danger
 over 20=btn-default then must provide p5 with style string
 p3 -- Dom ID (and DOM name converted in uppercase) of the element  
 p4 -- style string
 p5 -- image to show in the button body
 p6 -- position: R or L 
 p7 -- mutual exclusive -- 1=using ToggleOne() - else or none=using toggleDiv()
 Usage: p( btnHide("Show or Hide",3)+"This is hidden"+btnHide(0) )
 Usage: p( btnHide("Show or Hide",1,"myId") )

 Oct 31,2015 - Nov 5,2015 - Aug 3,2016 - Aug 14,2016  - Aug 27,2016

btnPopUp P#:_2017-0--069

btnPopUp(cLink, cLabel, nType, cTarget, cStyle, cImage, cPull, nPopType, cDomId
Class bootstrap
 Creates a button for a PopUp window:
 p1 -- URL
 p2 -- Text to show in the button body
 p3 -- type of button from 1 to 20 (default 2)
 1-5=small, 5-10=medium, 10-15=large, 15-20=block
 add 1=primary, 2=success,3=info,4=warning,5=danger
 over 20=btn-default then must provide p5 with style string
 p4 -- target frame (defaults to _self)
 p5 -- style string
 p6 -- image to show in the button body
 p7 -- position: R or L 
 p8 -- pop type 0 to 4  
 p9 -- DOM idientifier id for the button (name is same but uppercase))
 Oct 31,2015 - Nov 5,2015 - Aug 8,2016 - Mar 17,2017

buildMenu P#:_2017-0--044

Class bootstrap
 Display an example of usage
 Call this function, expose the HTML code in browser then copy and paste in your code
 if passed shows an example in *classic mode*
 default is *standard mode*           

buildForm P#:_2017-0--059

Class bootstrap
 Display an example of usage for the form
 Call this function, expose the HTML code in browser then copy and paste in your code

button P#:_2017-0--085

button(cLink, cLabel, nType, cTarget, cStyle, cImage, cPull, cDomId, cToolTip,
Class bootstrap
 Creates a button:
 p1 -- URL
 p2 -- Text to show in the button body
 p3 -- type of button from 1 to 20 (default 2)
       0=xsmall, 1-5=small, 5-10=medium, 10-15=large, 15-20=block
 add 1=primary, 2=success,3=info,4=warning,5=danger
 over 20=btn-default then must provide p5 with style string
 p4 -- target frame (defaults to _self)
 p5 -- style string
 p6 -- image to show in the button body
 p7 -- position: R or L
 p8 -- DOM identifier (name is the same but uppercase)
 p9 -- title for tooltip 
 p10 - suppress printout and return all in a string
 Oct 31,2015 - Nov 5,2015 - Aug 10,2016 - Sep 13,2016

CalendarMonth P#:_2017-0--074

Class bootstrap
 This procedure accepts a calendar date and display a grid of buttons
 each one representing a day of the month.
 Parameters are:
 1 - a calendar date around which to build the full month display
 2 - the target page to call when clicking on day (this page will receive some
     of the parameters taken from current values of this page
 3 - a number representing the mode of displaying the target page: 0 means
     full page, while 1 cause the page to display into a modal window
 4 - A target page to call while clicking on large button on top (usually
     a report showing the full month or an equivalent page)
 Example (opens the month into a modal window):
 The button on top has a default text that can be changed modifiyng pb_calend_title
 jchange("pb_calend_title","Click for a report")
 Nov 29,2015 - Dec 23,2015

calendar P#:_2017-0--081

Class bootstrap
  Show a calendar of a month, read only. Retruns a string with all the HTML code.
  Accepts a number (for the month) or a date: if missing defaults to current month.
  Optionally accepts the two-letter string for the language
  Optionally you can specify the year (overrides dDateOrNum)
  Jun 21,2016

caption P#:_2017-0--032

Class bootstrap

carousel P#:_2017-0--068

Class bootstrap
 Builds a fully working carousel, taking images from given folder
 (default is \images\show) - if not exists will be created

cell P#:_2017-0--089

Class bootstrap
-- accepts a value a return a box in non-editable input style
   p1 - X -- the content to insert in the entryfield (will be converted into text)
   p2 - X -- if passed the function won't output but etrun the HTML code  
   Feb 24,2017

checkbox P#:_2017-0--088

Class bootstrap
 create a checkbox
 p1 -- name to assign 
 p2 -- description (shown on right of button)
 p3 --  the value to return if checked - if omitted returns the string N/A
 p4 -- 1 or 0 (checked or unchecked)
 p5 -- DOM identificator to apply (must be unique for each button)
 Feb 12,2017

confirm P#:_2017-0--091

Class bootstrap
-- button for confirmation
 Mar 1,2017

container P#:_2017-0--033

Class bootstrap
 Makes the  container; no parameters or nOpt=1 opens a standard 
 container, with nOpt=2 the container is fluid
 nOpt=0 closes the container.
 Nov 5,2015

content P#:_2017-0--075

Class bootstrap
-- Start or close a DIV with cMargin allover and text of given color
   cMargin is the string for the margin (using px/em)
   if 0 (number) is passed closes the DIV (returning the tag)
   cColor -- is the string with name or number for the text color
   Nov 30,2015

cpanel P#:_2017-0--027

Class bootstrap

curDisk P#:_2017-0--060

Class bootstrap
 returns the current disk drive (as a string of 2 chars)

divider P#:_2017-0--071

Class bootstrap
 return the tag for a horizontal rule
 Nov 4,2015

drawer P#:_2017-0--066

Class bootstrap
 Starts or ends a Bootstrap COL
 p1 -- no parameters = starts the DIV, passing 0 = ends the DIV
      ANY other number up to 12 defines the WIDTH of the drawer
     (default is 12 that means 12/12 = a full row is taken)
 p2 - two chars string for column: xs/sm/md/lg -- default is md
 p3 - DOM identifier to assign (default is none)
      can be any value (will be converted to string)-useful for cycling
 p4 - is a string for the style
 Dec 2014, Sep 10,2016

endRadio P#:_2017-0--057

Class bootstrap
 closes a radio button group

endRow P#:_2017-0--064

Class bootstrap
-- closes a DIV row (i.e. returns )

formEnd P#:_2017-0--046

Class bootstrap
 end (close) the webform

formField P#:_2017-0--072

formField(cName, cLabel, cValue, cType, nFocus, cClass, cStyle, cJcode)
Class bootstrap
-- returns a form field
   1 cName  = name of the entryfield
   2 cLabel = a string with the text to display before field
   3 cValue = default value to assign
   4 cType  = T/H/S/P/D/E/N/R/K/O/U/W/C (HTML5)
   5 nFocus = none/0/1 (1=get focus)
   6 cClass = CSS Class
   7 cStyle = string for the style
   8 cJcode = string for the javascript code (method and values)
   Legenda for types:
   T=text  H=hidden  S=submit  P=password  D=date  E=email
   N=number  R=range  K=search  O=time  U=url  W=week  C=color

formStart P#:_2017-0--045

formStart(cURL, cTarget, cId, cXY, cVA, cURLparms, cComment)
Class bootstrap
 starts the webform - parameters:
 p1 -C- the string with the URL where to submit the form (default is #)
 p2 -C- target frame for the form (default is _self
 p3 -C- the DOM id and name to assign to form(default=automatic))
 p4 -C- the seed value to write in field XY (default none)) - if it is
        passed an asterisk then the two fields are omitted from form
 p5 -C- the action code to write in field VA (default none))
 p6 -C- a string with URL parameters to be passed along the form
 p7 -C- comment to insert (visible only in the HTML source)

formSubmit P#:_2017-0--050

Class bootstrap
-- create an input field for email
 cSubmit = text for submit button
 cReset  = text for abort button - if a zero (char) is passed then is not displayed
 cId     = the DOM id and name to assign to the form
 cButtAttr = string: xs,sm,md,lg

formTitle P#:_2017-0--047

Class bootstrap
 gives a title and image to form legend

framebox P#:_2017-0--090

framebox(cBorderColor, cInnercolor, cFontcolor, nOutput)
Class bootstrap
--- similar to well, but accepts directly style colors
 p1 - C -- border color string
 p2 - C -- background color string
 p3 - C -- font color string
 p4 - N -- if 0 closes the box
 Feb 24, 2017

fullscreen P#:_2017-0--086

Class bootstrap
-- starts a container full screen
   passing zero (or any other parameter) will close the container
   Feb 8,2017

getDate P#:_2017-0--055

Class bootstrap
 Mar 1,2017

getEmail P#:_2017-0--048

Class bootstrap
 create an input field for email
 cId   = the DOM id and name to assign to form

getNum P#:_2017-0--054

Class bootstrap
  p1 - name for the entryfield
  p2 - text to show aside the field
  p3 - focus -- 1 to get focus0
  p4 - initial value
  p5 - tootltip message
  p6 - DOM id
  p7 - range value - min
  p8 - range value - max
 Sep 10,2016

getOption P#:_2017-0--051

Class bootstrap
 create a select group field with single choice
 cId   = the DOM id and name to assign to select

getOptions P#:_2017-0--052

Class bootstrap
 create a select group field with multiple choice
 cId   = the DOM id and name to assign to select

getStr P#:_2017-0--053

Class bootstrap
 Places a pseudo@get in a form for getting a string
 Notice that the FORM must be declared before (and closed after)
 1 cName -- name to assign to entryfield (i.e. EF_MYFIELD)
 2 cLabel -- text to show aside the field (if any)
 3 nFocus -- none, 0 or 1. If 1 then this field will get focus
 4 cText -- the value to assign to entryfield (text up to 128 chars)
 5 cMsg -- an optional help message to display below the field
 6 cID -- an optional DOM ID to assign to entryfield for furthrt manipulation
 7 cType -- the HTML5 type for the field, overriding default one (i.e. password,mail,ecc)

getText P#:_2017-0--049

Class bootstrap
 generate a web form text area
 cName = name of the entryfield
 cContent = text to insert in the textarea 
 cLabel = Text to show above the textarea 
 cMsg = TExt to display below the area
 cId   = the DOM id and name to assign to form

hdiv P#:_2017-0--083

Class bootstrap
-- hidden DIV shortcut: 
 p1 -- none or 1 open the hidden div,0 close it. If a string then is taken as DOM id
 p2 -- DOM id identifier for the DIV (name is forced to uppercase) default 'hdiv'
 p3 -- class for the closeAll javascript function (default is hdiv)
 p4 -- additional style instructions (except display)
 Aug 8,2016

jencode P#:_2017-0--021

Class bootstrap
 accepts a string and returns a  string suitable to be passed
 as parameters to javascript functions (double the slashes and so on)

jLinkModal P#:_2017-0--023

jLinkModal(cDiv, cLink, cStr, cType, cClass)
Class bootstrap
 inserts a button for callin a modal
  cStr (opt) is the text in the button
  cType (opt) is the style 0-1-2-3-4
  cClass (opt) to specify a custom class

jumbo P#:_2017-0--035

Class bootstrap
 Returns the tags for a jumbotron large box
 p1 -- None or (N) 1 opens the jumbo, 0 closes
 if a string is passed it is inserted in the jumbo box then closed
 p2 -- DOM id to use
 Aug 16,2016

jurl P#:_2017-0--020

Class bootstrap
 accepts an URL in DOS/WEB format and return a 
   string encoded in the HTML format

listApps P#:_2017-0--034

Class bootstrap
-- returns a list of applications found in the given folder
  p1 - N -- 1=buttons 2=panels 3=table 4=list 5=list with CRLF  (default 1)
  p2 - C -- string with pah for the starting folder (default is /APPS)
  p3 - N -- number for minimum security level user must have to see this 
            app appear in listings (default is 12)
  Jul 2015 -- Feb 27,2016 -- Mar 06,2017

menu P#:_2017-0--039

menu(nVal,nPos, cStyle)
Class bootstrap
 MENU SYSTEM - step 3
 p1 - empty == starts the collapsible section of the menu
      passing 0 = ends the collapsible section
 p2 - if passed the menu is placed at bottom of page
 p3 - optional style string
 Notice: the menu items (drop downs or not) must be placed
         inside this section
 Dec 2013 -- Sep 7,2016

menuadd P#:_2017-0--043

Class bootstrap
 MENU SYSTEM - step  4
 Adds an optional menu on the right of menubar
 It works exactly as menu() function except that the
 whole section is aligned on the right of the menubar
 Notice: section is also collapsible
 JAN 7,2017

menuBar P#:_2017-0--037

Class bootstrap
 MENU SYSTEM - step 1
 No parameters = start the menu bar structure
 0 = close the structure   
 1 = bar standard fixed on top
 2 = bar inverse fixed on top
 3 = bar inverse at the bottom
 4 = bar standard at the bottom
 second parameter (optional) is a string for style

menuDivider P#:_2017-0--042

Class bootstrap
 MENU SYSTEM- an item divider - accepts a string
              if omitted display an horizontal line

menuItem P#:_2017-0--041

Class bootstrap
 MENU SYSTEM - menu item
 p1 -- the URL to open when clicked
 p2 -- the text to display in the button
 p3 -- target frame or window
 p4 -- style text
 p5 -- DOM Id to use
 Aug 15,2016

menuTitle P#:_2017-0--038

Class bootstrap
 MENU SYSTEM - step 2
 cBrand = a string to use as title
 cLogo  = the filename and path of the image to display
          before the title (optional)

off P#:_2017-0--067

Class bootstrap
 returns a 
 sometime is useful to avoid cluttering the code

panel P#:_2017-0--026

Class bootstrap
 Builds a panel
 nVal -- empty=open it, 0=close it, 1=heading, 2=body, 3=footer, other=default
 Dec 18,2015

panelbody P#:_2017-0--028

Class bootstrap
 returns a panel body

panelheader P#:_2017-0--029

Class bootstrap

panelfooter P#:_2017-0--030

Class bootstrap

popMsg P#:_2017-0--079

popMsg(cStr, cLabel, cClass)
Class bootstrap
 shows a brief screen-centered message that disappears when clicking anywhere on screen
 p1 -- the message to show
 p2 -- the text for the link
 p3 -- the class to use (default a standard link)
 IMPORTANT! it requires POPMSG.H to be included in the page with: include("/common/popmsg.h")
 Mar 07,2016 - Feb 8,2017

poster P#:_2017-0--036

Class bootstrap
 Returns the tags for a jumbo box with a background image
 p1 -- No parameters= opens the jumbo DIV without background.
       String= name and path of the image to use as background
       Number (zero) closes the DIV
 p2 -- number of pixel for minimum image height (default: full height)
 p3 -- a string for the style
 p4 -- if empty using poster size (huge) else a simple well 
 Nov 5,2015 -- Feb 27,2016 -- Mar 12,2017

printh P#:_2017-0--070

Class bootstrap
 Prints out the string surrounded by HTML  tags
 Parameters are:
 the string to print out inthe web page
 the font size form 1 (larger) to 6(smaller)
 the color (default is black)
 Nov 4,2015

pullR P#:_2017-0--078

Class bootstrap
-- returns the HTML code for a span right section
   p1 -- nothing=opens the span, 0=closes the span, 
         passing a string will be returned inside the section
   p2 - N -- 1=returns the text into a variable, otherwise ptints it to page
   Feb 27,2016 -- Mar 2,2017

radioButton P#:_2017-0--058

Class bootstrap
 create a group of radio buttons
 cName..: name to assign (all radio buttons must have same name)
 cDescr.: description (shown on right of button)
 cVal...: the value to return if checked - if omitted returns the string N/A
 nVal...: 1 or 0 (checked or unchecked)
 cID....: DOM identificator to apply (must be unique for each button)
 Nov 2015 --Feb 12,2017

rowEnd P#:_2017-0--063

Class bootstrap
-- closes a DIV row (i.e. returns )

rowStart P#:_2017-0--062

Class bootstrap
-- starting a DIV row

screen P#:_2017-0--087

Class bootstrap
-- starts a container screen centered on page - max size determined by current CSS
   passing zero (or any other parameter) will close the container
   Feb 8,2017

shelf P#:_2017-0--065

Class bootstrap
 starts or ends a Bootstrap row (to be loaded with drawers)
 p1 -- (N) - none or 1 = starts the DIV, 0 = ends the DIV
 p2 -- (C) - string for the style - default none
 Oct 2015, Aug 9,2016

sourcebox P#:_2017-0--077

Class bootstrap
-- show a box with text preformatted (i.e. honouring Line Feeds)

startRadio P#:_2017-0--056

Class bootstrap
 opens a radio button group
 cName -- DOM name and ID of the group
 cLabel -- text to display on the left of buttons
 nVal -- options (actually not used)
 If cName is omitted default is div_butt_grp
 If cLabel is omitted default is Select an option
 Nov 2015 -- Feb 12,2017

startRow P#:_2017-0--061

Class bootstrap
-- starting a DIV row

submenu P#:_2017-0--040

Class bootstrap
 MENU SYSTEM: places a button and starts a dropdown list
 If a string is passed the dropdown group of items is opened
 and the string is used as title of the button.
 Notice: the menu items that will be part of the dropdown
         must be placed inside this section
 If 0 (or any number) is passed as parameter the dropdown
 section is then closed
 cStyle is the style to apply (optional)
 JAN 8,2017

well P#:_2017-0--084

well(nVal,cStyle,cContent, cId)
Class bootstrap
 Opens and close a well
 p1 -C- no parameters or nVal=1 opens the well
 p2 -N- 0=closes the well
 p3 -C- a string for the style attribute
 p4 -X- optionale content to show in the well
 p5 -C- DOM identifier id and name
 Alternative usage:
 well("Hello there")

dbOpen P#:_2017-0--092

dbOpen(aDbList, cOpenList)
Class compat
 riceve una matrice 2D di 3 colonne con nome DBF, nome MTX e ALIAS
 il secondo parametro Ŕ una stringa di numeri separati da virgole
 per determinare quali tabelle aprire (numero elemento dell'array)
 se si passa zero come primo numero della lista visualizza tutto il contenuto

getDbSet P#:_2017-0--093

Class compat
-- extracts the DBSET vaue from a fully qualified path and filename
   Jun 2007

recPointers P#:_2017-0--094

recPointers(nStyle, cAliasM, cAliasS)
Class compat
-- Returns a string representing the record pointers of MASTER and SLAVE
   Jul 2007

session P#:_2017-0--095

Class compat
-- inizializza un file di memoria partendo dal seme e salvando tutte le
   variabili esistenti al momento
   se si passa una maschera (del tipo *c) salva solo quelle in maschera
   se si passa un qualsiasi terzo parametro (0/1 ecc) ritorna il seme usato
   altrimenti ritorna il nome del file di mempria creato
 Jun 15,2014 (Menton)

ajaxCall P#:_2017-0--100

Class core
 Makes an Ajax call to the given page. The page is executed asynchronously without notices.
 Nothing is returned to caller (page is run without a clue for the user).

ajr P#:_2017-0--102

ajr( cUrl, cParam, cTarget) {
Class core
 Ajax runner (internal use) 

ajRun P#:_2017-0--101

ajRun(cUrl, cParam, cTargId)
Class core

default P#:_2017-0--099

default(cVarName, anyValue)
Class core
 Mimics the command DEFAULT TO of Clipper
 Declares a variable if not already declared otherwise its value is assigned
 NOTICE that cVarName must be passed as string (i.e. between double quotes)!
 myVar := ("myVar","HEllo guys")
- Dec 15,2015

desktop P#:_2017-0--097

Class core
 Starts the DBFree library activating MaxScript extensionsfor a desktop page

jclear P#:_2017-0--105

Class core
 clears the browser local/session variable - variable will be voided but conserved in memory
 (i.e. will contain an empty string)
 cType -- 0/none=local, 1=session
 Dec 10,2015

jread P#:_2017-0--103

Class core
 Reads a variable from browser local/session storage
 cType -- 0/none=local, 1=session
 Dec 10,2015

jwrite P#:_2017-0--104

Class core
 Writes a string into a variable of the browser local/session storage
 cType -- 0/none=local, 1=session
 Dec 10,2015
 Mar 17,2016

jzap P#:_2017-0--106

Class core
 releases ALL the browser local/session variables
 (i.e. will contain an empty string)
 cType -- 0/none=local, 1=session
 Dec 10,2015

libVer P#:_2017-0--098

Class core
 Returns a string with the version number and build date of current library

web P#:_2017-0--096

Class core
 Starts the DBFree library activating MaxScript extensions for a web page

initlib P#:_2017-0--107

Class custom

chrDate P#:_2017-0--127

Class dates

CtimeDiff P#:_2017-0--134

Class dates
-- Accepts two time strings and returns a strinf representing the 
   elapsed time in time forma HH:MM
 Oct 5,2015

curDate P#:_2017-0--149

Class dates
-- return current date in a string formatted for HTML5 
   date-picker (yyyy-mm-dd)
 Feb 11,2017

curYear P#:_2017-0--148

Class dates
-- returns the number representing the current year
   Feb 11,2017

dayName P#:_2017-0--146

Class dates
 Accept a number between 1 to 7 and returns a string with day name
 in the desired language /US/UK/ES/OT/FR/DE/IT)
 Nov 29,2015

dayOfW P#:_2017-0--132

dayOfW(dDate, cLang, lShort)
Class dates
 Same as dayStr() but in english only and US format
 for compatibility only - it is preferable to use DayStr()
 Oct 5,2015

daysFrom P#:_2017-0--116

daysFrom( date1,date2)
Class dates
-- returns the number of days past from the given dates
 Oct 5,2013

daysOfM P#:_2017-0--117

Class dates
-- accepts a date and return a number representing the days of 
   month it belongs to. Honours the lap year (february of 29 days)
 Oct 5,2013

daysOfMonth P#:_2017-0--130

Class dates
 Accepts a MONTH NUMBER and returns the number of days of the given month
 Oct 5,2015  

dayStr P#:_2017-0--131

dayStr(dDate, cLang, nLen)
Class dates
-- accepts a date and returns the name of the day 
   Except for US the week starts at Monday
   Default for english is US (otherwise you must set cLang=UK)
   With nLen you can decide how long will be the string

dtoh5 P#:_2017-0--147

Class dates
 -- transforms a standard date in a string formatted for HTML5 
    new input date-picker type (yyyy-mm-dd)
    p1 -- the date to convert into formatted text
          if omitted will return current date   
    Sep 13,2016 -- Feb 11,2017 -- MAr 24,2017

dtok P#:_2017-0--144

Class dates
 Date to keyval
 Accepts a calendar date and returns a string
 representing the date in format YYY-MM-DD
 Nov 28,2015

evalTstamp P#:_2017-0--143

Class dates

firstDoM P#:_2017-0--110

Class dates
-- accepts a calendar date and returns a date representing 
 the first day of same month
 Oct 5,2013

firstDoY P#:_2017-0--114

Class dates
-- return a calendar date representing the FIRST day of the year
 Oct 5,2013 - Apr 10,2016

fulldate P#:_2017-0--142

fulldate( dThis, cCountryID, lShort, lAddtime)
Class dates
-- returns a string with day of the week, day month and year 
   of the date passed. In missing assumes the current date.
   second paramater identifies the country (IT/FR/DE/ES/PT) 
   WARNING: first day of the week is MONDAY except for USA/CAN which starts on SUNDAY
            this means that if you use lang=U it will follow north american rules
            to switch to UK (European) rules specify lang=UK
  if lShort is passes names will be shortened to three letters
  if lAddTime is specified current time will be added
   Jul 15,2010 - Nov 04,2015 - Mar 07,2016

initDates P#:_2017-0--108

Class dates

isLeap P#:_2017-0--129

Class dates
-- Accepts a date and return true if is a leap year
   WARNING: works only for current century -- use isLeapYear() for
            more precise caluclation
 Oct 5,2015

isLeapYear P#:_2017-0--118

Class dates
-- accepts a full date, a year number (4 digits) or a date-format string 
   (DD/MM/YYYY) and returns true if it is a leap year
 Nov 29,2015

itDate P#:_2017-0--122

itDate(dDate, lFullname)
Class dates

itDateStr P#:_2017-0--128

Class dates
-- Accepts a date and returns a string in italian
 Oct 5,2015

itDow P#:_2017-0--121

itDow(ddd, lFullname)
Class dates

itMonth P#:_2017-0--135

itMonth(dDate, lFullname)
Class dates
-- returns the italian name of the month of given date
 Oct 5,2015

ktod P#:_2017-0--145

Class dates
 Keyval to date-- (reverse function of dtok()
 Attention: it returns a calendar date not a string
 Nov 28,2015

lastDayOfM P#:_2017-0--112

Class dates
-- return a number representing of last day of given month
   month can be passed as number (1.12) or as calendar date
 Oct 5,2013

lastDoM P#:_2017-0--111

Class dates
-- return the calendar date of last day of month
 Oct 5,2013

lastDoY P#:_2017-0--113

Class dates
-- return a calendar date representing LAST day of the given year
 Oct 5,2013 - Apr 10,2016

monthName P#:_2017-0--115

Class dates
 returns the english name of given month (passed as number)
 Oct 5,2013

nowstr P#:_2017-0--119

Class dates
 If no parameter is passed returns a string to be used for naming files or 
 records and representing current date and time in format YYYY-MM-DD_HH-MM-SS
 Passing a string previously generated by the same function it reverses the
 function and returns the corresponding calendar date (time is lost).
 For more flexibility just use timestamp()
 Dec 10,2015

optDay P#:_2017-0--124

Class dates

optMonth P#:_2017-0--125

Class dates

optMonthIt P#:_2017-0--123

Class dates

optYear P#:_2017-0--126

optYear(nYear, nDig)
Class dates

secs2date P#:_2017-0--137

Class dates
-- accepts the output of seconds() and returns
   the corrisponding day as date
 Oct 5,2015

secs2days P#:_2017-0--138

Class dates
-- return the difference between two dates
   (passed in seconds) as number of days
 Oct 5,2015

timeDiff P#:_2017-0--133

Class dates
-- returns the time difference between two time strings

timestamp P#:_2017-0--120

timestamp( cParam )
Class dates
-- cParam defines the output type (example with Nov 3,2015 h7:50:52:14)
  none = 03/11/2015-0750
 H = 20151103-07 
 M = 20151103-0750
 S = 20151103-075052
 T = 03/11/2015-0750
 D = 2015-11-03
 I = 03-11-2015_07_50
 C = 2015-1103-0750-14

today P#:_2017-0--109

Class dates
-- returns current date in the local format specified

wcdow P#:_2017-0--140

wcdow( dThis, cCountryID )
Class dates
-- european name of the weekday (starts by monday=1)
   accepts only dates (IT/FR/DE/ES/PT)
 Oct 5,2015

wcmonth P#:_2017-0--141

wcmonth( dThis, cCountryID )
Class dates
-- european name of the month  (IT/FR/DE/ES/PT)
   accepts only a date
 Oct 5,2015

wdow P#:_2017-0--139

Class dates
-- european week (starts by monday=1)
   accepts dates or day number - return a number
 Oct 5,2015

week P#:_2017-0--136

Class dates
-- returns the number of current week based on the date
   passed as parameter: weeks go from 1 to 53
   starting from january 1
   nMode=1 week starts from sunday (default no)
 Oct 5,2015

editpage P#:_2017-0--155

Class dbd

go2apps P#:_2017-0--156

Class dbd

here P#:_2017-0--152

Class dbd

isDBD P#:_2017-0--151

Class dbd

isMemory P#:_2017-0--153

Class dbd

setLocalDb P#:_2017-0--150

setLocalDb( cDbPos, lNoCreate)
Class dbd

showMemory P#:_2017-0--154

Class dbd

appendBlank P#:_2017-0--177

Class dbf
--- counterpart of APPEND BLANK command - returns the record number of new record
    cKeyFld is the field to fill with mKeyVal (usually the field upon the index is based)
    Be always sure not to create empty records because they will cause error when reindexing
    Jul 10, 2007 - Montpellier

CloneRec P#:_2017-0--173

Class dbf

dbgrid P#:_2017-0--157

Class dbf
 Loops down the table records and build a grid cell for each one of them
 Each grid cell contains a separate web form with one of the fields of the record
 Each field reacts to changes by calling asynchronously this same page without reloading it
 The AJax call updates the field value in the table and immediately terminates without output
 p1 - C -- string for the fields to show (names separated by asterisks) default all 
 p2 - N -- 0=readonly, 1=edit
 p3 - N -- record to move to
 p4 - C -- string for the legend (names separated by asterisks) default fieldnames
 p5 - C -- link for the button (if empty the button is not shown)
 p6 - C -- type of button: 0=popup, 1=modal, 2=link -- default popup
 p7 - C -- style string for input cells (INPUT tag attribute)
 p8 - C -- style for table (TABLE tag attribute)
 p9 - C -- style for rows (TD tag attribute)
 Mar 19,2017 -- Mar 24,2017

dbInfo P#:_2017-0--181

Class dbf
-- shows all tables in use and their structure

dbskip P#:_2017-0--176

Class dbf
-- counterpart of SKIP command
 Oct 2007 - Florence

displayStru P#:_2017-0--180

Class dbf
-- returns a string containg the HTML code with the internal structure
   of the given table
   p1 -- (C) the alias to use, default current area
   p2 -- (N) output option: 1=return a string of text, else prints to screen
 Feb 27,2016 -- Aug 27,2016  -- Sep 10,2016 -- Jan 01,2016

enableClipper P#:_2017-0--160

Class dbf

enableDbase P#:_2017-0--162

Class dbf

enableFox P#:_2017-0--161

Class dbf

enableOdbc P#:_2017-0--159

Class dbf

fieldcount P#:_2017-0--170

Class dbf

fieldfit P#:_2017-0--172

fieldfit(cFldname, xCargo)
Class dbf
  Sep 07,2016

fieldfitter P#:_2017-0--171

fieldfitter(cFldname, xCargo)
Class dbf
-- obsolete -- use fieldfit()
   Mar 18,2017

fieldlen P#:_2017-0--167

Class dbf

fieldList P#:_2017-0--183

Class dbf

fieldNum P#:_2017-0--182

Class dbf
-- accepts a string representing a field name and returns the numeral position 
   of corresponding field in the record of table currently used 
   Jul 2007

fieldsize P#:_2017-0--184

Class dbf
-- returns the maximun size of a given field (expects a name or a number)
   Jan 28,2017

fieldtype P#:_2017-0--166

Class dbf
-- returns the data-type of a given field (expects a name or a number)
  Feb 14,2016

fieldval P#:_2017-0--169

Class dbf

filterkey P#:_2017-0--179

Class dbf

fit P#:_2017-0--158

fit(nField, xVal)
Class dbf
 -- Ensures the value passed is converted in the corresponding data type of the field
    useb by DBGrid
    Mar 19,2017

fsize P#:_2017-0--168

Class dbf

ftype P#:_2017-0--165

Class dbf
-- returns the data-type of a given field (expects a number)

listNext P#:_2017-0--178

Class dbf
-- Prints out  next nRecs of the current table
 p1 - N - Next records to show 
 p2 - C - Field list as string containing two-digit numbers (zero-filled)  
 p3 - C - page to call with the primary button created for each record
 p4 - C - string of common parameters to pass to the page
 p5 - C - webvar to use for passing the record number to the page
 p6 - C - URL with parameters for another page to call using secondary button 
 p7 - N - 1=legenda of field names, none = no legenda

 Usage; listNext(10,"03,04,02,16",my,"&VA=EDIT","VR","#top",1)
  Jul 2009 -- Aug 4,2016  -- Sep 14,2016 -- Feb 27,2017

pageCount P#:_2017-0--174

pageCount( nRecs, nPgRows)
Class dbf
-- returns pages required to display all rows of the table currently open
   jun 2007

setDb P#:_2017-0--163

setDb(cDbPos, xRelative)
Class dbf
-- returns the dos path pointing to the given database. If database does not
   exists it is created. 
   Passing any value as second parameter causes a nested database to be created
   (if not already existing).Nested DB are subfolders of the folder of current 
   database, which is a subfolder of _DATADIR
   Oct 2007
   - setDb(xAppId,1) usa una sottocartella LOCAL di xAppId e la usa come DBRoot

setDb3 P#:_2017-0--164

setDb3(cName, lShowOnly)
Class dbf
-- returns the dos path pointing to the given database. If database does not
   exists it is created. If passed lShowOnly (true) does not create database
   even if missing.

setdbtype P#:_2017-0--175

setdbtype( cType)
Class dbf

appInfo P#:_2017-0--189

Class extended
-- returns infos on libraries installed (obsolete)
    passing any parameter will cause the info to be printed
   without comment tag /thus displayed to screen)

casual P#:_2017-0--185

Class extended
-- returns a string containing a casual number always different but progressive
   to be used for automatic DOM ID assignments
 Jul 08,2016

convert P#:_2017-0--191

convert(anyval, cType)
Class extended
-- convert a value of a type into another
   p1 -- the original value
   p2 -- the letter (C/D/L) of the desired value
         default is text
   Feb 11,2017

getAppVer P#:_2017-0--187

Class extended
 returns the current application version

libInfo P#:_2017-0--190

Class extended
 returns infos about a library file (default the one currently used)
 Parameters: library path to search, show extended infos

modInfo P#:_2017-0--188

Class extended
 Provides some module infos to be embedded into the page as HTML comments

random P#:_2017-0--186

Class extended
-- generate a random numberbetween 100,000 and 999999
 Aug 05,2016

breadcrumb P#:_2017-0--234

Class files
 Builds a breadcrumb list of links to be printed out in the current position.
 cTarget=defaults to _self
 cClass=defaults to button xs small

createDir P#:_2017-0--222

Class files
-- create a folder  into current path
   Obsolete -- Just use makeTree() 

curDosDir P#:_2017-0--200

Class files
-- shows the path of current DOS dir
   if passed parameters (0/1)) omits the drive letter and/or the 
   slash at the end of the string
   0=option inactive, 1= option activated

curDosPage P#:_2017-0--201

Class files

curDrive P#:_2017-0--209

Class files
-- returns the drive letter (and columns) where wb site is located
 Aug 24,2016

curWebDir P#:_2017-0--207

Class files
-- ritorna il percorso web della cartella che contiene 
   il file MSP attualmente in esecuzione

curWebPage P#:_2017-0--208

Class files

dir P#:_2017-0--226

dir( cStartPath, cLink )
Class files
 Returns the directory listing of current DB 

 cLnk := "/apps/assistant/browse-edit.msp?VAR_TABLE=|"

directory P#:_2017-0--239

Class files
-- Display a list of files depending by parameters passed:
  cFolder -- path to use
  cMask   -- mask for files
  nTarget -- 0 or none=self, 1=pop up modal
  nMode   -- 1= with info column
  cIcon   -- icon to display before the name of file

dirName P#:_2017-0--224

Class files
 returns the folder name of given path
 Nov 14,2015

documentRoot P#:_2017-0--194

Class files
-- same as webroot

dos2web P#:_2017-0--202

Class files
-- trasforma un percorso DOS in percorso web
   a partire dalla document root del server web

fcountByTime P#:_2017-0--240

fcountByTime(cFold, cMask, cTime, cSign, nFlag)
Class files
-- counts (or list) how many files are newer/older than given hour time.
   it returns a number or a formatted string depending by nFlag 
 cFold == the folders to be scanned
 cMask == mask for files to search
 cTime == time in format HH:MM:SS (only hours will be considered)
          (default is current hour time)
 cSign == sign for comparison (more,less,equal - one char string)
          (default is: older than cTime)
 nFlag == any number: if passed return the result as a list of files
          separated by the $ sign (to be used for array loading)
 If nFlag is passed and no files satisfy the condition will return $
 Jan 19,2016

file2str P#:_2017-0--227

Class files

FileBase P#:_2017-0--213

FileBase( cFullFileName, noSlash )
Class files

fileBone P#:_2017-0--217

fileBone( cFile )
Class files

fileclean P#:_2017-0--212

Class files

fileDrive P#:_2017-0--210

Class files

fileExt P#:_2017-0--218

fileExt(cFilename, xExcludeDot)
Class files

filefolder P#:_2017-0--214

filefolder(cFullFileName )
Class files

FileName P#:_2017-0--215

FileName( cFullFileName, nOption )
Class files
 Returns the filename formatted as determined by nOption:
 No parameters = filename qithout drive and path but with dot and extension
 nOption = 0 -- dot and extension are trimmed out
 nOption = 1 -- drive and path omitted, but with dot and extension 

FileNoDrive P#:_2017-0--211

FileNoDrive( cPathName)
Class files

FilePath P#:_2017-0--216

FilePath( cFullFileName, lNoDrive )
Class files

fileread P#:_2017-0--236

Class files
 A substitute of memoread()
 First parameter is the file to read: if not exisiting
 the function will return an empty string.
 Second parameter tells the kind of file to read:
 None or zero=standard, 1=only 8-bit ASCII chars
 Third parameter is buffer size (default=auto detect)
 Use this function to avoid unwanted garbage chars when reading or saving
 into memo fields and/or small files (under 2 Kb)

fileScan P#:_2017-0--195

Class files
-- read a file using low level routine

fileSource P#:_2017-0--219

Class files

filewrite P#:_2017-0--238

Class files
 Substitute for memowrit - it can overwrite or append to existing file
 plus it doesn't insert special end-of-file markers unlike memowrit()
 nMode -- 0=overwrite, 1= insert at the beginning, 2=insert at the end
 default is 0

getBytes P#:_2017-0--198

Class files
 reads nBytes from any file starting at pos nStart
 (low level function)

include P#:_2017-0--193

include(cFil, cSed, cMarker)
Class files
-- usage:
   ? include(cTextFile) html
   ? include("/common/header.h",cSeed)) html
   For direct usage see: preload()
 For paseing the seed the file to be included must contain a call
 with this sintax: XY=* then the asterisk will be replace with the
 sed passed as parameter.
 If a third parameter (string) is passed it will be used instead
 Dec 30, 2015  - Sep 30,2016  - Feb 4,2017

isDir P#:_2017-0--220

Class files

isFolder P#:_2017-0--221

Class files

jlink P#:_2017-0--232

Class files

label P#:_2017-0--228

Class files

listFiles P#:_2017-0--242

Class files
-- returns a string containing a list of files
   of given folder honouring the given mask separated by cCargo1
   The string can then be processed to an array  using str2arr()
   p1 - C -- folder DOS path
   p2 - C -- DOS mask for files to show
   p3 - N 
      0=no printout (returns all in a string with separators)
      1=with full pathname
      2=filename only
      3=as web link
      4=as dos link
      5=as list of web links
      6=as popup button with parameters passed in cargo1 and class passed in cargo2
      7=as link with parameters passed in cargo1 and class passed in cargo2
   p4 - C -- cargo parameter 1 (default is #)
   p5 - C -- cargo parameter 2  
        listFiles( cDir,"*.dbf",qq,"btn btn.xs btn-danger")
        listFiles( cDir,"*.dbf",7,qq,"btn btn-xs btn-danger")
 Oct 5,2013 - Jan 21,2016 - Mar 12,2017

listFolders P#:_2017-0--243

Class files
-- returns a list of subfolders contained into cThisDir
    xFlags determines the type of output:
    empty -- names between 
  • tags 1 -- names between asterisks 2 -- names between square brakets 3 -- number of folders found 4 -- an HTML string with all links 5 -- clickable buttons
  • listFunc P#:_2017-0--229

    Class files

    makeTree P#:_2017-0--230

    Class files
    -- builds all the upper folders necessary to fulfill a
       path creation request.
       Nov 2,2015

    pageFile P#:_2017-0--199

    Class files
    -- returns the DOS path and name of current web page
       p1 -- (N) passing 1 will return the name with slashes doubled for using with javascript
     Dec 2006 -- Sep 01,2016

    pageName P#:_2017-0--197

    Class files
    -- per compatibilitÓ con apache: da usare al posto di getenv("SCRIPT_NAME") 

    plainPath P#:_2017-0--225

    Class files
     returns the folder name of given path
     (similar to dirName but using different method)
     Nov 14,2015

    preload P#:_2017-0--192

    preload(cFile, cSed, cMarker)
    Class files
     reads a text file and inserts its content directly into the HTML flow of page
     for indirect usage see also: include()
     Jan 2 2016

    readfile P#:_2017-0--235

    Class files
     Same as fileread()

    showpath P#:_2017-0--233

    Class files

    storage P#:_2017-0--223

    Class files

    subDir P#:_2017-0--204

    Class files

    sysDrive P#:_2017-0--241

    Class files
     Return a 2-character string for system drive (i.e. C:)
     jun 29,2016

    upDir P#:_2017-0--205

    Class files

    wdrive P#:_2017-0--231

    Class files

    web2dos P#:_2017-0--203

    Class files
    -- trasforma un percorso web in percorso dos
     Dec 2006 -- Sep 12,2016

    web2java P#:_2017-0--206

    Class files

    webRoot P#:_2017-0--196

    Class files
    -- nStyle 1=DOS, 2=DOS Nodrive
    -- compatible with MonGoose Web Server
    -- if used in DBDesk returns root dir  - DBMAX returns current main folder

    writefile P#:_2017-0--237

    Class files
     Same as filewrite()

    alertOnce P#:_2017-0--274

    Class html
    -- display a waning panel red and white only once for session
       p1 -- text to display -- if empty just opens the alert box and return
             if passed zero or any other numeric closes the box
       p2 -- the ID of the session object (cookie) to be checked or saved
             becomes the DOM ID of the panel DIV the alert box is displayed in
             (default name/id is 'warnonce')
       p3 -- a string for the optional style
     Oct 15,2015 -- 08 Feb 2017

    blanks P#:_2017-0--296

    Class html
    -- retuns non-breaking white spaces HTML
       Mar 18,2017

    breakline P#:_2017-0--282

    Class html
     return a HTML tag for line break 

    brk P#:_2017-0--293

    Class html
     returns an HTML break tag
     Mar 2,2017 

    buildComment P#:_2017-0--279

    Class html
     prints out in the HTML code a template for top-of-page comments
     Call this function, expose the HTML code in browser then copy and paste in your code
     Oct 5, 2015

    centred P#:_2017-0--294

    Class html
     returns a DIV for centering text in the page
     Oct 2015 -- Mar 12,2017 

    clock P#:_2017-0--295

    Class html
    -- return the javascript code for a clock
       p1 - any -- if passed returns the code else outputs to page
       Mar 16,2017

    CloneRecord P#:_2017-0--250

    Class html
     Takes a record and duplicates it adding a new one
     Jul 15,2007 

    closePage P#:_2017-0--273

    Class html
     inserts the code for closing a page (and its container)
     Oct 11,2015
     Mar 7,2016

    closeWebPage P#:_2017-0--272

    Class html
     Same as ClosePage() but to be used in CGI style
     Nov 5,2015

    codebox P#:_2017-0--269

    Class html
     display the given text with option ID as PRE element
     (usefuk for displaying source code)
     Oct 31,2015

    comment P#:_2017-0--278

    Class html
    -- inserts an HTML comment block containing the string passed

    commentln P#:_2017-0--277

    Class html
    -- inserts an HTML comment containing with the string passed 

    cvttext P#:_2017-0--284

    Class html

    display P#:_2017-0--287

    display(cFldList, nStyle)
    Class html
       p1 -C- list of fields to show (2-digit field number) separated by asterisks 
              or commas (default display all fields))
       p2 -N- display mode: 0=clean 1=row num 2=show type 3=type and size
       NOTICE: the pseudo-form is DOM identified upon the record number with prefix RECD_
     Oct 5, 2013
     Jun 27,2016 -- Sep 7,2016

    displayRecord P#:_2017-0--246

    displayRecord(nRec, nStyle)
    Class html
    -- retrieving the total fields of current record
                  Record number to go to
                  nStyle to apply 0=clean 1=row num 2=show type 3=type and size 4=no output, only text
      Usage: < % =displayRecord(recno(),1) % >
     Oct 5, 2013
     Jun 27,2016 -- Sept 30,2016 -- Jan 01,2016

    editRecord P#:_2017-0--247

    editRecord( nRec, cFieldList, cUrl, nMode, nDecs, cJaction)
    Class html
       p1 - N -- record number to go (default current record)
       p2 - C -- string with field names to display separated by asterisks (default all)
       p3 - C -- the target file to call submitting the form (defalt self)
       p4 - N -- none or 1=edit allowed, if 0 only display
       p5 - N -- decimals to use for numerics
       p6 - C -- javascript action to bind to SAVE button (by defaul passes "window.parent.location.reload();"
                 to close a modal and reload the parent page after saving the page)
     Oct 5, 2013 -- Feb 14,2016 -- Aug 10,2016 -- Sep 7,2016 -- Feb 27,2016  -- Mar 22,2017

    flds2form P#:_2017-0--264

    Class html
    -- accepts a list of fields as a string where each field to show is represented by its 
       2-digit number separated by asterisks
     Jul 20,2012 -- Sep 12,2016

    HTML5 P#:_2017-0--298

    Class html
    -- needed to handle some HTML5 elements (e.g. calendar dates)  
       p1 - N -- none==enables HTML5 support, 0==disable

    hyperlink P#:_2017-0--251

    hyperlink(cUrl, cDescr, cTarget, cStyle, cClass)
    Class html
    -- returns a string to be used in the HTML part of the page as link
     p1 (C) - URL of the link
     p2 (C) - text to show in the link
     p3 (C/N) - target (if passing "_pop" will open in a popup) or if
                passing a number is ignored 
     p4 (C) - optional style string
     p5 (C) - optional class ovverride
     Nov 4,2015 - Aug 9,2016 - Aug 16,2016

    image P#:_2017-0--291

    Class html
    -- return the HTML tag for an image
       p1 - C - image URL - if file does not exist will return empty
       p2 - C/N - string for height (with measuring unit) or height in pixels

    inputRadio P#:_2017-0--252

    inputRadio(cName, cValue, varToMatch)
    Class html
     Oct 5, 2013

    input_c P#:_2017-0--261

    input_c(cName,cId,cValue,cLabel,cPlaceholder,cHelp )
    Class html
    -- returns a form field 
     Sep 1,2014

    input_m P#:_2017-0--262

    input_m(cName,cId,cValue,cLabel,cStyle,cHelp )
    Class html
    -- returns a form field
     Sep 1,2014

    item P#:_2017-0--292

    Class html
    -- builds an item list
          empty=start the list
          0=close the list
          string=text to be itemized
       p2 - N -- 0=pointed (default) - 1=numbered 
     Mar 2,2017

    jhide P#:_2017-0--275

    Class html
    -- immediately hide an element of the page
       (not suitable for using with buttons or javascripts!)
       Use in WebObjects actions or for hiding elements of
       static code loaded with include(9 or preload()   
     Oct 31,2015

    js P#:_2017-0--297

    Class html
    --- opens a javascript code section in the page
        p1 - N -- 0=closes the section
      Mar 18,2017

    jumptop P#:_2017-0--281

    Class html
     Returns a link for moving to top of page
     p1 (C) - optional, text to display in the link
     p2 (C) - position "L" or "R"
     Aug 9,2016

    junhide P#:_2017-0--276

    Class html
    -- immediately unhide an hidden element of the page
        (not suitable for using with buttons or javascripts!)
       Use in WebObjects actions or for hiding elements of
       static code loaded with include(9 or preload()
     Oct 31,2015   

    link2app P#:_2017-0--257

    link2app( cDir, xDebug )
    Class html
    -- build a link to a Web App
     Mar 15,2012

    link2menu P#:_2017-0--256

    link2menu( cDir, cChoiches, xDebug )
    Class html
    -- returns a link from a list of possibilities in the given directory
       by default looks into current directory, passing a zero looks in 
       upper one
       If an alternative list is passed this must be in form of a string
       with filenames (incl. extension) separated by asterisks
     Feb 10,2009

    linkit P#:_2017-0--254

    Class html
    -- produces a link from a field (function to be used in commands)
     cLink := "customers.msp?VAR_SOMEVAR="
     use countries
     list off iif(empty(CODE),"...",CODE), linkit( cLink+CODE, COUNTRY, "frm2")
     Feb 10,2009

    load P#:_2017-0--258

    load( cPageUrl, cHeader, cFooter )
    Class html
    -- open a page or builds it if not exists
     Mar 15,2012

    navBrowse P#:_2017-0--267

    navBrowse(cFldList, cEditPage, cParmList, xOutput)
    Class html
    -- second of of 2 functions to implement a browse
       the call to this function can be omitted and substituted by your own browse code
       navBrowse("?")   (shows the code for customization)
       navBrowse("9,3,5,4")  (field list)
       navBrowse("1,2,3","edit.msp","XY") (webvars to pass - VR is the default)
     Jul 20,2013 -- Mar 2,2017

    navButtons P#:_2017-0--266

    Class html
    -- functions to generate a form for browsing
       <%=navButtons("?")%>   //(shows instructions)
       must be followed by a call to function navBrowse()
       If thir parameter passed just outputs the code
     Jul 20,2012 -- Mar 2,2017

    navEdit P#:_2017-0--268

    navEdit( cUrl, cFldList, nModal, xOutput)
    Class html
    -- simple record editor to be called by the button of navBrowse
       p1 - C -- target page for the form
       p2 - C -- list of fields number separated by asterisks
       p3 - N -- running in 1=modal window - 0=standalone page
       Usage: navEdit(cSelf,"01*02*03")
     Oct 5, 2013 -- Feb 26,2017 -- Mar 2,2017

    openPage P#:_2017-0--271

    Class html
     inserts the code for a  basic page header (including container open)
     Oct 11,2015
     Mar 7,2016

    openWebPage P#:_2017-0--270

    Class html
     Same as OpenPage() but to be used in CGI style
     Nov 5,2015

    optByDb P#:_2017-0--245

    Class html
    -- popola le option di una select usando un DB come fonte
       la tabella deve essere sul percorso dati corrente
       Ese. <%=optByDb("GNX_UTENTI","USR_NAME")%>
     Oct 5, 2013

    pageReload P#:_2017-0--280

    Class html
     causes the page to be reloaded
     Nov 4, 2015

    pl P#:_2017-0--288

    Class html
     print a line of text (or any other text) as HTML 
     formatted paragraph
     p1 -C- text to print
     p2 -N- dimension (larger to smaller 1,2,3,4,5,6)
            default is 5 (
    ) Sep 07,2016

    printIni P#:_2017-0--244

    Class html
    -- visualizza in HTML il contenuto di un file ini
     Oct 5, 2013

    println P#:_2017-0--286

    Class html
    -- prints out the given string between HTML tags for the paragraph size
       p1 -- the string
       p2 -- a size code as a string: minute,normal,medium,large,big,huge or 
             7,6,5,4,3,2,1 (small to large) or xs,s,m,l,xl,xxl,xxxl
     Aug 16,2016 

    rec2form P#:_2017-0--263

    Class html
    -- Builds a list of entryfields for current record 
     Jul 20,2012 -- Aug 27,2016

    ruler P#:_2017-0--283

    Class html
     return a HTML tag for an horizontal ruler
     p1 -- optional margin top and bottom distance in pixel
     p2 -- optional color string

    save2Record P#:_2017-0--259

    save2Record(nRec, aWebVarList, cAlias)
    Class html
    -- Save into record the incoming webVars matching field names
       (special function)
       p1 -N- record number to go to (mandatory))
       p2 -A- webvars stack page part (mandatory - must be added to current page)
       p3 -C- alias name of the target table
     Oct 5, 2013 -- Dec 23,2013 -- Jan 11,2016
     Sep 7,2016

    saveRecord P#:_2017-0--260

    saveRecord(nRec, aWebVarList, lDebug ) //-- corretto bug EF
    Class html
    -- si deve passare come array aWebVarList (che sarebbe aVars)
       l'array Ŕ in realta una matrice quadrata con la prima colonna contente MSPFieldName
       e la seconda MSPFieldValue
     Nov 15,2008

    setStyle P#:_2017-0--255

    Class html
    -- sets the styles for bootstrap use
       no parameters=default.css, 0=bootstrap, 1=bootstrap-theme
       2=theme, 3=takes the name from CSS entry in mspconfig file
     Mar 15,2012

    shim P#:_2017-0--265

    Class html
    -- inserts a DIV of the given height (if passed a numeric) or
       a text if given a text
       Second parameter is the conten ot the div
       Usage: shim(60)
     Jul 20,2012

    showMaster P#:_2017-0--248

    Class html
    -- show master record
     Oct 5, 2013

    showSlave P#:_2017-0--249

    Class html
    -- show slave record
     Oct 5, 2013

    strSafe P#:_2017-0--253

    Class html
    -- returns safe code for preloading in the RTE

    text P#:_2017-0--285

    Class html
    -- returns a string between HTML tags for the paragraph size
       p1 -- the string
       p2 -- a size code as a string: minute,normal,medium,large,big,huge or 
             7,6,5,4,3,2,1 (small to large) or xs,s,m,l,xl,xxl,xxxl
       print( text("Hello world","huge") )
     Aug 16,2016 -- Feb 8,2017

    url2form P#:_2017-0--290

    Class html
    -- returns a list of fields from current record
       as a string with a separator 
     p1 -C- list of fields (2-digits) default all fields
     p2 -C- separator to use (default blank space) 
     Sep 7,2016

    webvar P#:_2017-0--289

    Class html
     Returns an hidden entryfield for web forms 
     p1 -C- the name of the webvar (DOM Name for entryfield)
     p2 -X- the value (that will be converted into string)
     Sep 07,2016

    clearSess P#:_2017-0--305

    Class login

    displayGlobals P#:_2017-0--304

    Class login

    displayJvars P#:_2017-0--302

    displayJvars( cJvarStr)
    Class login

    displaySession P#:_2017-0--303

    displaySession(cThisSeed, cStyle)
    Class login
     display the stock session vars (excluding those
       added by modules) as declared in the header

    isLocal P#:_2017-0--299

    Class login

    loginButton P#:_2017-0--306

    Class login

    logoutButton P#:_2017-0--307

    Class login

    logwrite P#:_2017-0--300

    logwrite( cMsg, cUsrName, cCodOp, cCargo, nTTime, cClass )
    Class login

    setId P#:_2017-0--301

    Class login

    cfg2mem P#:_2017-0--325

    Class mem
     Reads a configuration file CFG and loads its content into memory
     WARNING: if file does not exist will be generated with default values

    file2vars P#:_2017-0--330

    Class mem
     loads variables in memory from file (file must contain
     variable names and values pairs [varName=varvalue]
     RETURN a string with separator containing the list of var names
     Second parameter is for debug and only show the process 
     WARNING: uses a private array named aParsed that MUST ne passed
     to function parseStr() DONT CHANGE THE NAME

    getCargoFile P#:_2017-0--314

    Class mem
     Returns a filename for storing Z-VARS
     Nov 4,2015 - Dec 10,2016

    getMemDir P#:_2017-0--317

    Class mem
     returns the path where memory files are actually stored

    getMemFile P#:_2017-0--311

    getMemFile(cSeedStr, vEncrypt, vUsePort)
    Class mem
     returns a filename for storing session variables
      parameters are for encryption and including port
      If this is not necessary just use getSessFile()
     Oct 5,2013

    getMemPath P#:_2017-0--318

    Class mem
     returns the path where memory files are actually stored

    getseed P#:_2017-0--316

    Class mem
     generate a new progressive number (as string) to be used
     for naming sessions
     passing nVal=0 the seed will be fixed (not change) using  
     the IP of the current connection instead of a unique ID
     Oct 5,2013 -- JAn 13,2016

    getSessFile P#:_2017-0--312

    Class mem
     Returns a filename for storing X-VARS (ignoring encryption and port)
     Nov 4,2015

    getSession P#:_2017-0--313

    Class mem
     Returns a filename for storing X-VARS (ignoring encryption and port)
     same as getSessFile
     Feb 2,2016 - Dec 10,2016

    ini2Mem P#:_2017-0--326

    ini2Mem(cIniFile )
    Class mem
     legge un file ini standard e carica le variabili contenute 
     nella memoria della pagina corrente come pubbliche

    ini2vars P#:_2017-0--331

    Class mem
    -- reads a given ini file and intitalizes all the vars
       if there are sections (between square brackets) the name of the
       section is added to the name of the variables they contain

    listMem P#:_2017-0--319

    Class mem
     returns the content of a memory array (tipically aVars)

    listVars P#:_2017-0--320

    Class mem
    -- inspects a formatted string and extracts variable names it may contain 
       default sepatator is an asterisk

    loadini P#:_2017-0--310

    Class mem
    -- reads an ini file standard and initialies the 
       variables with their values
       it returns a list of names for vars created
       separated by spaces
     Oct 5,2013

    loadIniVars P#:_2017-0--327

    Class mem
     Loads variables into memory from a large ini file
     Default row size is 128 and default end-of-line marker is CHR10 

    makeSeed P#:_2017-0--315

    Class mem
     wrapper for getseed()
     Oct 5,2013

    restmemory P#:_2017-0--309

    Class mem

    savememory P#:_2017-0--308

    Class mem
     -- saves the memory variable into memory.mem file 
     x2 := "WORLD"
     ? savememory("x*")
     clear memory
     ? restmemory()
     ? x1, x2
     Oct 05,2013

    saveSession P#:_2017-0--334

    Class mem
    -- saves all X-Vars to a session file: returns the name of the file
     Nov 18,2015

    undef P#:_2017-0--329

    Class mem

    undefined P#:_2017-0--328

    Class mem
    -- ritorna vero se la variabile passata (tra virgolette)
       non Ŕ stata dichiarata prima

    varBar P#:_2017-0--332

    Class mem
    -- shows a bar with session variables
       must receive the seed  and the action code as parameters
     WARNING: needs the approriate javascript to be loaded BEFORE being called

    webv2f P#:_2017-0--323

    webv2f(aArr, cExclude)
    Class mem
     Same as webVar2fields()

    WebVars P#:_2017-0--333

    Class mem
    -- prints out the content of thae webVars array
       returns the current number of elements of the array
     WARNING: the webVars stack MUST be declared BEFORE calling this function
     NOTICE that if the file could not be saved returns the string error.mem

    WebVars2Fields P#:_2017-0--324

    WebVars2Fields(aArr, cExclude)
    Class mem
    -- trasforma tutte le webVar dell'array in campi hidden
       il secondo parametro Ŕ la maschera di esclusione

    webVars2str P#:_2017-0--321

    Class mem
     Converts all the elements of the array passed as parameter into a string
     to be used as URL (EF_ as formfield prefix and &= as separator)
     If the paramater is not ana array returns an empty string
     Oct 5, 2013 - Nov 18,2015

    WebVars2url P#:_2017-0--322

    WebVars2url(aArr, cExclude)
    Class mem
    -- trasforma tutte le webVar dell'array in una stringa da URL

    hex P#:_2017-0--337

    Class nums

    hextoken P#:_2017-0--338

    Class nums

    keepVal P#:_2017-0--336

    keepVal( cStr, nLow, nHigh)
    Class nums

    range P#:_2017-0--335

    Class nums

    setDec P#:_2017-0--339

    Class nums

    myself P#:_2017-0--340

    Class obsolete

    getGlobFile P#:_2017-0--343

    Class sessions
     returns the name of file containing global variables

    getJseed P#:_2017-0--347

    getJseed(cVarName, nAction)
    Class sessions
    * retrieves a seed prevously saved in browser local storage and optionally reloads the page
      You can specify the name of the item to retrieve (default is JSEED uppercase)
      nAction -- 1=reloads, empty or 0 only display the result
     Nov 4,2015 - Dec 10,2015

    initGlobals P#:_2017-0--342

    initGlobals( norewrite )
    Class sessions
     initializes the global variables (if parameter passed does not save to disk)
     it also creates a text file with a default configuration
     Globals are stored in a public array named _GLOBALS
     Initializes, preload and save G-Vars (Global variables)
     returns the name of the file where the variables have been saved
     Nov 3,2015 -- Nov 17,2015 -- sep 01,2016

    initJ P#:_2017-0--355

    Class sessions

    initJseed P#:_2017-0--346

    Class sessions
    * initializes the browser-based seed system
      The item saved into localStorage is named JSEED (containing the current seed)
      The function returns the javascript code as a string (after execution) for debugging

    initJvars P#:_2017-0--345

    Class sessions
     Initializes as public the variable to be used in J-Detection forms

    initSession P#:_2017-0--341

    initSession(cSeed, nOption)
    Class sessions
     initializes as public, preloads and saves X-Vars for the given seed
     returns the name of the file where the vars have been saved
     p1 -- the seed to use (if empty creates a new one)
           REMEMBER to save the x variables created here 
     p2 -- if any value is passed saves the variables
     Nov 3,2015 -- Aug 27,2016

    initXvars P#:_2017-0--344

    Class sessions
    -- initializes as public all X-Vars (no preload is done)
       see also initSession()

    readJvar P#:_2017-0--356

    Class sessions
    -- Reads a variable stored in browser
     Nov 3,2015

    restoreSession P#:_2017-0--349

    Class sessions
    -- restore a session from a given seed -- see initSession() 
       p1 -- (C) - the seed
       if seed is not passed  or is a dollar sign a new session is created
       if the sees is passed but it is empty no session will be created 
       The function returns the name of memory file used (or an empty
       string if seed was empty)
       p2 -- (N) - passing 1 force the loading of mem file
     Nov 3,2015 - Jan 2,2016

    saveJseed P#:_2017-0--348

    Class sessions
     Saves cStr as local storage item cVar
     If cVar is omitted saves as JSEED

    showCargo P#:_2017-0--353

    Class sessions
     Same as showZvars()

    showGlobals P#:_2017-0--351

    Class sessions
    -- prints out the globals
       p1 -- if passed uses CR_LF, otherwise HTML break  line
     Aug 14,2016 

    showJvars P#:_2017-0--352

    Class sessions
    -- prints out the session variables xVars
       p1 -- if passed uses CR_LF, otherwise HTML break  line
     Aug 14,2016 

    showSession P#:_2017-0--350

    Class sessions
    -- prints out the xVars
       if any parameter passed return all as string

    showZvars P#:_2017-0--354

    Class sessions
    -- prints out the cargo variables Z-Vars
       if any parameter passed return all as string

    block P#:_2017-0--422

    Class strings
     CGI style -- output a division
     no parameter=open the DIV otherwise 0 to close it
     1 or empty=left alignment, 2=center, 3=right

    break P#:_2017-0--421

    Class strings
     CGI style -- output a break

    c2n P#:_2017-0--408

    Class strings
    -- converts any value to number
     if nMode=1 all zeros in the strings are ignored
     Dec 18,2015 -- Feb 16,2016 

    Capital P#:_2017-0--380

    Capital( cStr )
    Class strings
     Converts first letter to uppercase and the resto fo the string to lowercase

    cleanStr P#:_2017-0--373

    cleanStr( cVar )
    Class strings
    -- clean up a string to be then used with  wz_tooltip.js
     Oct 5,2013

    cleanUp P#:_2017-0--372

    cleanUp( cVar )
    Class strings
     Removes angular brackets,single and double quotes, CR_LF 
     and the words href,script
     Returns a string with the HTML equivalents of removed chars
     Oct 5,2013 - Feb 8,2017

    code2memo P#:_2017-0--358

    Class strings
    -- replace all angular brackets with square brackets
       used for neutralizing the HTML code before saving in a memo
     Mar 24,2017

    contains P#:_2017-0--397

    contains(cTarget, cString, nIgnorecase)
    Class strings
    -- Return true if the first string contains the second
       p1 -- text string to be emaninated
       p2 -- the string to look for
       p3 -- none==case sensitive, 1==ignore case
     Feb 2008 -- Aug 27,2016

    cutAt P#:_2017-0--366

    cutAt( cString, cKey)
    Class strings
    -- cut a string starting to left until it reaches cKey 
       same as using leftmost()
     Jul 14, 2007

    dblSlash P#:_2017-0--388

    Class strings
    -- same as jslash (obsolete)
     Oct 5,2013

    decval P#:_2017-0--418

    Class strings
     Accepts a string representing a number with a decimal separator and
     returns the equivalent number
     Second parameter is for the separator (default is a dot or comma)
     Jan 4, 2016

    dslash P#:_2017-0--389

    Class strings
    -- same as jslash (obsolete)
     Jul 15,2007

    fChar P#:_2017-0--374

    fChar( val )
    Class strings
    -- Accepts any value and returns it as string
     Jul 15,2007

    ffix P#:_2017-0--415

    Class strings
      Filename Fixer -  Ensure that a filename has a drive letter and
      removes double slashes from the path - convetrs web slash to DOS
      current drive and path is taken as defaults.
      Can also be used to create a filename from a numeric value.
     Dec 18,2015

    fixSlash P#:_2017-0--381

    Class strings
     Replaces single shlashes with back slashs and removes double back slahes
     Returns a cleaned string suitable to use in DOS operations
     -- see also ffix()
     Nov 7,2010

    forEach P#:_2017-0--399

    Class strings
       cList := "jan,feb,mar,may"
       ? forEach(cList,,"upper(x)")
     Feb 2008

    htmlMemo P#:_2017-0--401

    Class strings
    -- replace all angular brackets with square brackets
       used for neutralizing the HTML code before saving in a memo
       see also memoHtml()
     Feb 2008 -- Sep 01,2016

    ini2Str P#:_2017-0--395

    Class strings
    -- wrapper for iniTostr
     Feb 2008

    iniToStr P#:_2017-0--396

    Class strings
    -- aggiunta 03 Gen 2012 - modif 14 Mag 2014
       legge un file ini e lo ripone in una stringa di testo
       usando come separatori prentesi graffe

    iniVar P#:_2017-0--392

    Class strings
     Search cVarName into an .ini file  and returns true or false for found
     Feb 2008 

    intval P#:_2017-0--419

    Class strings
     Accepts a string and returns a number without decimals.
     This is somewhat the counterpart of decval() function. 
     Returns an integer number ignoring decimals ( number is not rounded)
     but decimals simply stripped away, unlike c2n()
     Useful in some rare cases to cleaa up recno() if passed via webVars
     Jan 4,2016

    jaddP P#:_2017-0--411

    Class strings
    -- adds a parameter (typically the seed) to a static URL
       parameter is added at the end of URL without checking
       if already exists
       if cElem and cStr are omitted it is added the seed  
     Dec 18,2015

    jchange P#:_2017-0--404

    Class strings
    -- Change the HTML content of a given  DOM element (using the ID) with 
       the value passed as parameter. Value is always converted to string.
    -- usage:
       jchange("myCounter", nnn )
     Dec 18,2015

    jfieldval P#:_2017-0--406

    Class strings
      changes a value of a webform element (i.e. ENTRYFIELDS)
      deciding if the final value is string or numeric
      For other elements use jvalue() instead
     Dec 18,2015

    jInnerHtml P#:_2017-0--403

    Class strings
     Same as jchange
     Dec 18,2015

    jInsertSeed P#:_2017-0--407

    Class strings
    -- add seed to a static link that has no parameters 
       if there are already these parameters please use jaddP()
     Dec 18,2015

    jslash P#:_2017-0--386

    Class strings
    -- double the forward slash to allow use of stringds
       returning DOS paths into javascripts
     Oct 5,2013

    jtitle P#:_2017-0--410

    Class strings
    -- changes the title of the web page
     Dec 18,2015

    junslash P#:_2017-0--387

    Class strings
    -- removes double slashes form the string
       (opposite of jslash)
     Oct 5,2013

    jvalue P#:_2017-0--405

    Class strings
    -- Change the HTML content of a given  DOM object (using the ID and its element)
       with the given value. Value must be any value and will be a string in resulting java code
       If element is omitted will default to innerHTML (acting exactly like jInnerHTML function)
    -- usage:
       jchange("div_date", "value", dtoc(date()) )
     Dec 18,2015   

    leftMost P#:_2017-0--368

    leftMost(cString, cKey)
    Class strings
    -- return the leftmost part of a string delimited by cKey
       same as using cutAt()
       Jan 15,2016

    memo2code P#:_2017-0--357

    Class strings
    -- converts text (angular barckets) back to to HTML
       (it is the reverse of code2memo)
       Mar 25,2017

    memoClean P#:_2017-0--398

    Class strings
    -- returns safe code for preloading in the RTE
       same as safeRTE
     Feb 2008

    memoHtml P#:_2017-0--400

    Class strings
    -- replace all square brackets with angular brackets
       used for activating HTML code deactivated by htmlMemo()
      Feb 2008  -- Sep 01,2016

    n2c P#:_2017-0--361

    Class strings
    -- exactly equivalent to zz()
       but by default decimals are off
       Jan 4, 2016

    neutralize P#:_2017-0--402

    Class strings
    -- neutralizing javascript and maxscript code in a text 
       then to be shown only by using PRE tag (or saved in memo field)
       Sep 01,2016

    nice P#:_2017-0--409

    Class strings
    -- strips underscores from a string and replaces it
       with blank spaces while converting first letter uppercase
       Option=1 converts all first letters of each word uppercase
       Option=2 removes the file extension
     Oct 5,2014

    nn P#:_2017-0--424

    Class strings
    -- returns always a number from string, dates or logical
       if a date is passed returns the days past from today
       if array, memo or none returns 0
       Mar 18,2017

    noSpaces P#:_2017-0--383

    Class strings
     Removes all spaces from the string
     Nov 7,2008

    occur P#:_2017-0--412

    Class strings
     Counts the occurences of  into 
     p1 -- (C) - string to search for
     p2 -- (C) - text where to search
     p3 -- none==case sensitive, 1==case insensitive

    onlyNum P#:_2017-0--423

    Class strings
     Returns a string stripped from all characyers and symbols
     and containing only numbers
     Feb 16,2016
     if nMode=1 all zeros in the string are ignored

    p P#:_2017-0--414

    Class strings
     Abbreviation for PRINT() function
      NOTE that this function prints out DIRECTLY to web page without
           intermediation of any sort
     Dec 18,2015

    padc P#:_2017-0--378

    padc( cString, nLength, cCaratt )
    Class strings
     Centers the text
     Returns a string of nLenght filled with cChar
     Jul 15,2007

    padl P#:_2017-0--377

    padl( cString, nLength, cCaratt )
    Class strings
     Padding the string to the left
     Returns a string of nLenght filled with cChar on left
     Jul 15,2007

    padr P#:_2017-0--379

    padr( cString, nLength, cChar )
    Class strings
     Padding the string to the right
     Returns a string of nLenght filled with cChar on right
     Jul 15,2007

    parseFor P#:_2017-0--393

    parseFor(cStr, cVarname, cOpenTag, cCloseTag, cTokenTag)
    Class strings
     -- Parse a string cStr in search of the text cVarname (which representes the
        name of a variable) and its value (separated by cTokenTag) by using 
        cOpenTage and cCloseTag as delimiters
     parseFor(cTxt,"NavScreenSize","[","]","=")  same as above
     Feb 10,2008

    parseStr P#:_2017-0--394

    parseStr(cStr, cOpenTag, cCloseTag, cTokenTag )
    Class strings
    -- fills an array aParsed (to be declared before using the function) 
       with the results of the search of ANY string delimited by cOpenTag
       and cCloseTag and separated internally by cTokenTag 
      By defaults tags are square brachets and the separator is an equal sign.
      for iii=1 to parseStr(cTxt)
        ? aParsed[iii]
      Feb 2008

    print P#:_2017-0--413

    Class strings
     same as PRINT command but suitable for direct output to
     a web page because does not insert a 
    as end of the line. Specific for usage with Bootstrap Functions The passed parameter is converted to string. If no parameter was passed returns an empty line (CR+LF) Dec 18,2015

    printline P#:_2017-0--420

    printline( cStr, nParm)
    Class strings
     CGI style -- output a line of text
     nparm is a number for the size tag 1=


    etc. if no cStr is passed prints an horizontal line

    readIniVar P#:_2017-0--390

    Class strings
     Returns a value of a variable stored into an ini.file
     If file does not exists returns NIL
     (use writeinivar() to write the vars to file)
     cFile = full file path and name of the file to read
     cVarname = variable to read (case insensitive)
     cDtype = 1 char string for type of data to return. Accepts N/C/L. 
     Oct 5,2013

    rec P#:_2017-0--363

    Class strings
     return the current record number as a string
       p1 -- (N) number of digit (zero leaded) of the returned string
     Dec 2016 -- Feb 18,2017

    reverse P#:_2017-0--360

    Class strings
     reversing the content of a string
     same as revStr()
     Oct 5,2013 

    revStr P#:_2017-0--359

    Class strings
     reversing the content of a string
     Oct 5,2013

    rightMost P#:_2017-0--367

    rightMost( cString, cKey)
    Class strings
    -- return the righmost part of a string delimited by cKey
     Jan 15,2016 -- Sep 01,2016

    rslash P#:_2017-0--382

    Class strings
     Ensures the last character of the string is a back slash
     Jul 15,2007

    splitVal P#:_2017-0--384

    Class strings
    -- recupera da una stringa la porzione di testo
       prima o dopo il separatore 
       Se  la porzione sinistra, altrimenti
       la destra. Per recuperare la coppia completa
       chiamarla due volte. Es:
       cTxt := "mario/rossi"
       c1 := splitVal(cTxt,0,"/")
       c2 := splitVal(cTxt,1,"/")
       Utile per leggere le coppie dai file INI
     Nov 7,2008

    ssoff P#:_2017-0--417

    Class strings
    -- server side tags off - removes all ss tags
       Nov 30,2015

    strcount P#:_2017-0--416

    Class strings
     count how many occurrencies of a string are found into another
     cTxt -- the text to be searched
     cKey -- the string to count within the text
     see also occur()
     Oct 5,2014

    StripChars P#:_2017-0--371

    StripChars( cTxt , nUpperASCII)
    Class strings
     Removes all non printable characters ( less than 65 or more of 254)
     Second parameters is to tell what is the upper limit (typically 126 instead of 256)
     Oct 5,2013

    trimLeft P#:_2017-0--365

    trimLeft( cStr, nPos )
    Class strings
     -- Trims a string of nPos characters starting from left
        if cStr is shorter than nPos the string returned is null
     Jul 14, 2007

    trimLeftAt P#:_2017-0--369

    trimLeftAt(cString, cKey)
    Class strings
    -- return the leftmost part of a string delimited by cKey
       same as using cutAt()
     Jul 14, 2007

    trimRight P#:_2017-0--364

    trimRight( cStr, nPos )
    Class strings
     -- Trims a string of nPos characters starting from right
        if cStr is shorter than nPos the string returned is null
     Jul 14, 2007

    trimRightAt P#:_2017-0--370

    trimRightAt(cString, cKey)
    Class strings
    -- return the rightmost part of a string delimited by 
      the first occurrence from left of cKey 
      see also rightMost()
     Jul 14, 2007

    WordLeft P#:_2017-0--376

    WordLeft( cStr, cSep )
    Class strings
     returns the leftmost portion of the string delimited by cSep
     jul 15,2007

    WordRight P#:_2017-0--375

    WordRight( cStr, cSep, lOffset )
    Class strings
     returns the rightmost portion of the string delimited by cSep
     if lOffset is specified the separator is omitted from result
     see also rightMost()
     Jul 15,2007

    writeIniVar P#:_2017-0--391

    Class strings
     Salva una variabile e il suo valore in un file ini
     di tipo DBFree 
     Se il file non esiste viene creato
     Ritorna il nome del file INI in cui ha scritto
     Oct 5,2013

    wstr P#:_2017-0--385

    Class strings
    -- web string, senza spazi davanti e dietro
       usata per passare valori via URL
     Nov 7,2008

    zz P#:_2017-0--362

    Class strings
    -- convert any value to a string
       Uprated and fixed version to reflect the decimals setting with no limit on lenght
       Second parameter is to set how many decimals to use 
       Oct 4,2013 -- Aug 29,2016 -- Oct 01,2016

    callingpage P#:_2017-0--432

    Class web
    -- returns the URL of current page (relative to web root)
       nStyle: 0=only name and port
               1=full address but dropping port
               2=full address (protocol, server, port))
     Sept 6,2011  - Dec 10,206

    computername P#:_2017-0--439

    Class web
    -- return the computer name as seen by the OS
       (if this is supported by the web server in use)

    DnsList P#:_2017-0--434

    Class web
    -- returns the content of local DNS file (Windows XP and above)
     Oct 4,2013

    folderBar P#:_2017-0--435

    Class web
    -- returns a string containing navigation links 
       that take to current folder

    ip P#:_2017-0--436

    Class web

    ip2num P#:_2017-0--429

    Class web
    -- trasforma un indirizzo IP (stringa) in un numero che la rappresenta

    isMob P#:_2017-0--442

    Class web
    -- returns false or true if the string passed contains one of the names
       corrisponding to an user agent/browser
       Usage: isMob(xNavUserAgent)

    isWeb P#:_2017-0--425

    Class web
    -- return true if the code is running through a web server

    jreload P#:_2017-0--441

    Class web
     Forces the web page to load a new URL
     if no parameter is passed reloads the same page

    jsetId P#:_2017-0--440

    jsetId( cElement, cProperty, cValue )
    Class web
    -- find (by ID) the cElement in the page and set its cProperty to cValue

    listWebVars P#:_2017-0--426

    listWebVars(aArr, nStyle)
    Class web
    -- list all webVars stored in the given array (usually aVars)
       nStyle=0 -- returns the array as string delimited with asterisks (default)
       1 -- returns a string to be used with pair parsers (square brackets)
       3 -- same as 2 but using braces and colons
     Oct 4,2013

    num2ip P#:_2017-0--430

    Class web
    -- trasforma un numero contenente un indirizzo IP nella stringa dell'IP

    passFields P#:_2017-0--428

    Class web
    -- transforms an array of fields into hidden fields to put in a form
     Aug 15, 2008

    passVars P#:_2017-0--427

    Class web

    protocol P#:_2017-0--431

    Class web
     Returns the protocol used by the given URL - if the URL does not contains
     a valid protocol specification return an empty string
     Dec 10,2016

    scriptName P#:_2017-0--433

    Class web
     Jul 15, 2005

    serveraddr P#:_2017-0--437

    Class web
     Returns the actual IP address of the server
     Dec 30, 2015

    servername P#:_2017-0--438

    Class web
    -- return the server name as seen by the client (in effect 
       the URL used for the connection as seen by the DNS)
     Nov 18,2015

    serverport P#:_2017-0--443

    Class web
    -- returns the current port actually used for the connection 
     Nov 18,2015

    Top of page