Tuesday, September 28, 2010

Format expression rules

A format expression for strings can have one section or two sections separated by a semicolon (;).
If you use The result is
One section only The format applies to all string data.
Two sections The first section applies to string data, the second to Null values and zero-length strings ("").
A user-defined format expression for numbers can have from one to four sections separated by semicolons. If the format argument contains one of the named numeric formats, only one section is allowed.

If you use The result is
One section only The format expression applies to all values.
Two sections The first section applies to positive values and zeros, the second to negative values.
Three sections The first section applies to positive values, the second to negative values, and the third to zeros.
Four sections The first section applies to positive values, the second to negative values, the third to zeros, and the fourth to Null values.



read moe

File related variables

These variables are used with WF and DF commands. In all other cases their values are ignored by WhizBase.
WB_FileName - This variable contains the file name of the DF (file will be deleted) and WF (key value will be written in file).
WB_KeyName - This variable contains the name(s) of the key(s) that will be changed/added/deleted using WF.
WB_KeyValue - This variable contains the value(s) for the key(s) that will be changed or added using WF.
WB_Section - This variable contains the name of the section containing the key that will be changed/added/deleted using WB_Command value WF.
WB_Separator - This variable contains the character which will be used to separate different entries in the WB_Keyname and WB_KeyValue variables.

read more

FileCommands

Syntax:FileCommands=On/Off
If this variable is set to True, WhizBase will process files that include writing and/or deleting files on server. It is strongly recommended not to set this variable to True together with AbsolutePath set to true, unless webmaster of virtual server is an experienced WhizBase developer. Default value is Off.

Example of use

FileCommands variable is used in Server configuration section, a configuration is set for all aliases of a single virtual host.
[wbsp.com]
DisableWB=F
AbsolutePath=On
Upload=On
FileCommands=On
Execute=JavaScript,VBScript,JScript
HiddenEnvVars=PATH,COMP*,System*
TimeOutSec=20
DefaultDocument=index.wbsp
ADOConnectionString=T
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=0
HideDocuments=sr,aut,inc,ic,mdb
ScriptTimeOutSec=60

[dsd.ba]
DisableWB=F
AbsolutePath=Off
Upload=On
FileCommands=Off
Execute=VBScript
HiddenEnvVars=PATH,COMP*,System*,Win*
TimeOutSec=10
DefaultDocument=default.wbsp
ADOConnectionString=F
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=10
 

FDT ($WBFN)

Availability
FDT is available for use with all WBSP commands.
Syntax

$WBFN[FDT(formatstring)]

Arguments
formatstring - any valid named or user-defined format string.

Returns
Current server date or time (depending on value of formatstring argument) formatted using formatstring.
Example


Today is $wbfn[fdt(dd-mmmm-yyyy)]!

Result
Today is 07-july-2008!

Execute

Execute=languagelist
This variable contains the comma-separated list of scripting languages that are allowed to be used on the virtual server. If this variable is empty then server-side scripting functionality of WBSP engine (using $wbrun function) will be disabled on that virtual host. There is no default value for this variable, so if administrator does not set the list, scripting will be disabled.
The next example will show usage of Execute in WBSP:
[default]
DisableWB=F
AbsolutePath=Off
Upload=Off
FileCommands=Off
Execute=JavaScript
HiddenEnvVars=PATH,COMP*,System*,Win*
TimeOutSec=10
DefaultDocument=index.wbsp
ADOConnectionString=F
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=30
HideDocuments=sr,ic,inc,aut,mdb,dbf

Monday, September 27, 2010

Exceptions

WhizBase function $WBINC can not accept other WhizBase functions as arguments, but there is a similar function - $WBRINC that can be used when you need to process the function's arguments.

read more

Error message tags

Error message tags are WBSP placeholders for various parts of an error message. They are not intended to be used on the ordinary WBSP pages nor in normal circumstances, but in error template file (defined by WB_ErrFile variable and sent to client when error occurs). Their purpose is to format and/or hide some of the error details. Also, when output type (Content-type) is not text/html they can be used to generate proper error report (e.g. XML, XHTML, WML, RTF, etc.)
$WBERRDESC - Full error description including error message and error number.
$WBERRMSG - Text-only error description without error number.
$WBERRNUM - Error number, without any text message.
$WBERRMAIL - Email address specified in WB_ErrMail form field for current WBSP file.

read more

Error reporting

These variables are used for formatting error reports.
WB_ErrMail

read more

Error messages

Common system errors - These errors are not specific to WhizBase but the are related to system configuration, disk/file access permissions and regional settings.
Database errors - These errors are not specific to WhizBase but they are related to database usage. Their error numbers are between 3000 and 3999 and they can also have a negative error number.
WhizBase specific errors - Errors with error numbers between 5000 and 5999 are specific to WhizBase only.

read more

Displaying records from database table

The easiest (and fastest) way for displaying the database records is shown in following example:
[FormFields]
wb_basename=biblio.mdb
wb_rcdset=Titles
WB_Command=Q
WB_TempName=$default$
This will produce simplest report containing all fields from table Titles in a HTML table, on a white background, broken in pages containing 20 records per page. This report is not completely useless and usually is used for testing purposes.
However, to make report a little bit nicer we will do small changes in previous example:
[FormFields]
wb_basename=biblio.mdb
wb_rcdset=Titles
WB_Command=Q
WB_MaxRec=10




Simple database example


$wbdetail[t]
Now we have added some title to the report and some HTML formatting using $WBDetail[T] function and CSS styles. We also changed the number of records per page using WB_MaxRec.
With further modifications we can include Author's and Publisher's names instead of their ID numbers, and sort titles by year in descending order as shown in following example:
[FormFields]
wb_basename=biblio.mdb
WB_RcdSet=(Authors inner join titles on authors.au_id=titles.au_id) inner join publishers on publishers.pubid=titles.pubid
WB_DBFlds=Title,[Year Published],ISBN,Authors.Name as Author,publishers.Name as Publisher
WB_Command=Q
WB_MaxRec=10
WB_Order=[Year published] desc




Simple database example


$wbdetail[t]
To enable search though this recordset we should add the search form and modify the recordset definition as shown in following example:
[FormFields]
wb_basename=biblio.mdb
WB_RcdSet=(select Title,[Year Published],ISBN,Authors.Name as Author,publishers.Name as Publisher,Authors.Name,publishers.Name from (Authors inner join titles on authors.au_id=titles.au_id) inner join publishers on publishers.pubid=titles.pubid)
WB_Command=Q
WB_MaxRec=10
WB_Order=[Year published] desc




Simple database example
















$wbdetail[t]

This looks much better, but in some cases there is a need for placing the database field in a specific location on your report, or even not using HTML at all. In that case we do not use $WBDetail function but some (or all) of database field functions $WBF, $WBRF. In the following example we will modify the code so it will return previous recordset in XML format:
[FormFields]
wb_basename=biblio.mdb
WB_RcdSet=(Authors inner join titles on authors.au_id=titles.au_id) inner join publishers on publishers.pubid=titles.pubid
WB_DBFlds=Title,[Year Published],ISBN,Authors.Name as Author,publishers.Name as Publisher
WB_Command=Q
WB_MaxRec=$all$
WB_Order=[Year published] desc
WB_ContentType=text/xml



$wbmrepl[$wbf[Title]|',&|',&]
$wbf[year published]
$wbf[isbn]
$wbf[Author]
$wbf[Publisher]
We modified WB_MaxRec to special value $all$ (this will show all records from recordset in a single report page) and set the WB_ContentType variable to text/xml. Note that we also had to use $WBMREPL function to replace apostrophe and ampersand characters in field "Title".

read more

Wednesday, September 22, 2010

DisableWB

DisableWB=T/F

If this variable is set to True, WhizBase engine will not process WBSP files located on that specific virtual host, and error will be generated. Default value is False.
Example of use:
[default]
DisableWB=F
AbsolutePath=Off
Upload=Off
FileCommands=Off
Execute=JavaScript
HiddenEnvVars=PATH,COMP*,System*,Win*
TimeOutSec=10
DefaultDocument=index.wbsp
ADOConnectionString=F
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=30
HideDocuments=sr,ic,inc,aut,mdb,dbf
The next example will disable usage of WBSP on all virtual hosts, but those that are defined in Servers section:
[default]
DisableWB=T


read more

Difference between report and input functions

WhizBase input functions are similar to the report functions. They have different syntax (input functions use general syntax $wbfnname {arg} instead of report functions - $wbfnname[arg]), but the main difference is in way of using them and when they are interpreted on server. Inserting server’s date/time in the database as record update time, for example, without input functions requires some serious work including unnecessary redirections and resource consuming.
Example:
If you put hidden field in your report like this
then, when WBSP engine process this report, this field has value of server's date/time when the page was sent to browser:
This field will have the same value even if the form is submitted hours later, what means that it is completely useless for tracking record update time.
However if you use same function in input syntax WhizBase will ignore it during report processing. To use same function as above, but this time in input syntax simply change the value as follows:
WBSP will ignore this function during report processing and visitor's browser will receive exactly the same code as you wrote it in report:
As an opposite from previous case it is of no importance how long you will wait before submitting this form. Once you submit the form WBSP will receive
06-avg-2010 10:34:14
as a value for WBF_LastUpdated form field, process it and write exact update time to DB field named LastUpdated.
Because input functions are processed  before opening the database it is not possible to use DB related functions as input functions (except $WBSR and $WBSRQ). Using these functions in input syntax will result with empty string.
Any WB form field can have input function in its value and they can be used both in HTML forms and WBSP files:
WB_Query=PageID=1
Or
 

Developer

Developer=registered developer name
This variable contains the name of the registered developer used in combination with RegCode variable. If valid combination of these two variables exists, virtual hosts do not need their own registration keys.


read more

Detail section

Detail section is everything located between and comments. When WBSP start processing the detail section, it moves the recrdset to the record defined in WB_StartRec variable, processes all tags and functions found in detail section, sends the resulting content to the client, moves the recordset to the next record and repeat the process for every record in record range (starting with record number WB_StartRec and ending with record number WB_StartRec + WB_MaxRec). It means that detail section will be repeated as many times as there is records in the range. It is very important to place and comments properly, because misplacing them can produce unwanted results.
Here's an example:




Titles


Year published Title ISBN
$wbf[Year published] $wbf[title] $wbf[ISBN]

$WBNavigator


When processed this WBSP page will produce a table with 3 columns and 20 rows containing filed values for Year published, Title and ISBN fields from table Titles.
However, if we misplace the and comments by putting them inside the structure, like this:




Titles


Year published Title ISBN
$wbf[Year published] $wbf[title] $wbf[ISBN]

$WBNavigator


we'll get a two rows table with 3 columns in first row and 60 columns in second row (3 columns for every record displayed).

read more

DF (WB_Command) - Delete file

Description
This command is used for irreversibly deleting file specified in variable WB_FileName. The file will not be sent to recycle bin, but deleted permanently.

read more

Monday, September 20, 2010

DU (WB_Command) - Delete DB user or group

Description
This command is used for deleting specified user (WB_DBUser) or specified group (WB_DBGroup) from workgroup file (WB_System). The result can be displayed using $WBAdmin[] tag.

read more

DG (WB_Command) - Delete DB user from group

Description
This command is used for deleting specified user (WB_DBUser) from specified group (WB_DBGroup)  in workgroup file (WB_System). The user will not be deleted from workgroup file, but simply will not be a member of the group. The result can be displayed using $WBAdmin[] tag.

read more

D (WB_Command) - Delete

Syntax: WB_Command=D
Description
This command is used for deleting the records from the database. When executed, it opens the recordset (variables WB_BaseName and WB_RcdSet must be defined when you use this command), deletes all records in the selected recordset and displays processed WBSP page or redirects client to URL defined in WB_Redirect variable.
Important: Delete command can and will permanently delete all the records that match the condition. We strongly recommend you to password-protect either your database (using MS Access system.md? file) or the WBSP page containing this command (using WB_HTAccess). To disable deletion of more than one record at the time define the WB_UID variable in WBSP page containing the DELETE command.

Example of use

Using addition with WB_Command in a WhizBase file.
[FormFields]
WB_BaseName=biblioA.mdb
WB_RcdSet=Titles
WB_Command=D
WB_UID=ID
WB_Redirect=default.wbsp
 
 

Default section

Default section contains configuration that will be applied to any virtual host that does not have its own configuration section.
Here's an example:
[default]
DisableWB=F
AbsolutePath=Off
Upload=Off
FileCommands=Off
Execute=JavaScript
HiddenEnvVars=PATH,COMP*,System*,Win*
TimeOutSec=10
DefaultDocument=index.wbsp
ADOConnectionString=F
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=30
HideDocuments=sr,ic,inc,aut,mdb,dbf
The next example will disable usage of WBSP on all virtual hosts, but those that are defined in Servers section:
[default]
DisableWB=T
 

Default.inc

Special case of include file are files named default.inc. These files will always be included in search, even if there is no Include section defined in WBSP file. WBSP engine will try to read default.inc file located in same directory with WBSP file and, if that file does not exist or does not contain specified variable, it will proceed reading all default.inc files located in directories above current directory until wwwroot directory of virtual host is reached.  However, none of the files will be processed if WBSP engine finds the variable either in WBSP file itself or in other include files.

read more

Thursday, September 16, 2010

DefaultDocument

This variable contains the file name of default WBSP file defined in your server's configuration (e.g. index.html, index.htm, index.wbsp).
Some web server software can have problems recognizing the default document. If that is the case with your web server software than setting this variable will solve the problem. Default value is default.wbsp.

Example of use:

DefaultDocumentvariable is used in Server configuration section, a configuration is set for all aliases of a single virtual host.
[wbsp.com]
DisableWB=F
AbsolutePath=On
Upload=On
FileCommands=On
Execute=JavaScript,VBScript,JScript
HiddenEnvVars=PATH,COMP*,System*
TimeOutSec=20
DefaultDocument=index.wbsp
ADOConnectionString=T
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=0
HideDocuments=sr,aut,inc,ic,mdb
ScriptTimeOutSec=60 

DB Administering

These variables are used to modify database and table permissions, users, groups and passwords for MS Access *.MDB databases. They can not be used with other database types including MS Access 2007 files (*.ACCDB).
WB_DBAddData
WB_DBAdmin
WB_DBDelData
WB_DBEditData
WB_DBGroup
WB_DBModDes
WB_DBNewPass
WB_DBNPassCh
WB_DBOldPass
WB_DBReadData
WB_DBReadDes
WB_DBUser
WB_PID

read more

Database reated functions

Because these functions work with recordset and input functions are processed before opening the database it is not possible to use all these functions in input syntax func{arg}. Functions that can be used in input syntax ($WBSR and $WBSRQ) have both syntax forms listed.
$WBDetail
$WBF
$WBRF
$WBFF
$WBFU
$WBFC
$WBSR
$WBSRQ

read more

DAY ($WBFN)

Availability
DAY is available for use with all WBSP commands.
Syntax
$WBFN{DAY}
$WBFN[DAY]

Arguments
DAY function does not have any arguments.
Returns
A whole number between 1 and 31, inclusive, representing the day of the month for current server date.
Example of use:
Use it in any WBSP file:


We are in the $wbfn[day]th day in the month!

Result
We are in the 6th day in the month!

read more 

DATE ($WBFN)

Availability
DATE is available for use with all WBSP commands.
Syntax
$WBFN{DATE}
$WBFN[DATE]

Arguments
DATE function does not have any arguments.
Returns
Current server date in short date format depending on server’s regional settings.
Example of use:
Use it in any WBSP file:


Today's date is $wbfn[date]!

Result
Today's date is 06.07.2010!

read more 

Wednesday, September 15, 2010

Database

These variables are used for configuring database-related parameters.
WB_BaseName
WB_Cdate
WB_Connect
WB_DBObject
WB_Having
WB_MaxPages
WB_MaxRec
WB_RcdSet
WB_ShowEmpty
WB_WholeWord
Recordset field value container: WBF_field

read more

Database related tags

Database related tags are WBSP keywords related to database operations.
$WBQUERY
$WBCQUERY
$WBDELETED
$WBRecordBreak 

read more

Database errors

These errors are not specific to WhizBase but they are related to database usage. Their error numbers are between 3000 and 3999 and they can also have a negative error number. If you can not find the explanation in this manual, please search the Internet using following search term:
error errornumber

read more

Configuraton section subsections

Configuration section contains definitions for WBSP variables needed for a specific task. It can have one or more subsections, depending on purpose of the WBSP page – Include, FormFields, Upload, MsgAndLbl, Referrer check, ErrorMessages and UserData.

read more

Configuration section

This section should be placed on top of the WBSP file and separated from rest of the file with comment. This way WBSP engine will not send anything from this section to the client (e.g. visitor's browser), and all variables and file paths will stay hidden from visitor. Configuration section contains definitions for WBSP variables needed for a specific task. It can have one to seven subsections, depending on purpose of the WBSP page – Include, FormFields, Upload, MsgAndLbl, Referrer check, ErrorMessages and UserData. To learn more about these sections please read the explanations for each section in chapter "Configuration section subsections".

Here's an example (configuration section is marked blue)




Titles


Year published Title ISBN
$wbf[Year published] $wbf[title] $wbf[ISBN]


$wbnavigator[]


Tuesday, September 14, 2010

CD (WB_Command) - Compact database

Description
This command is used for compacting MS Access database *.MDB file. Variable WB_BaseName is required.


read more

Common system errors

These errors are not specific to WhizBase but the are related to system configuration, disk/file access permissions and regional settings.

read more

Comments

WhizBase version 6 adds support for comments. To avoid mistakes and removing parts of programming code written in other programming techniques and/or languages WhizBase uses hash and asterisk characters for opening and asterisk and hash characters for closing of the comments:
e.g.

Multiline comments are supported in the body of the reports and subreports (below ), and in included files ($WBINC and $WBRINC).
If you want to comment the variables in the configuration section(s) use the single hash (without asterisk) at the beginning of the row containing the variable:
e.g.
#WB_TempName=$default$
the line above will be completely ignored by WhizBase
or use in the single row:
e.g.
WB_Query=ID>1 #* and Year=2006 *# and ID<100
the line above will be processed to:
WB_Query=ID>1  and ID<100
or use in multilines:
e.g.
Hello World #* Here is a greeting
it is a greeting that we programmers use for testing our codes *#
this is WhizBase.
the line above will be processed to:
Hello World
this is WhizBase.
Beside documenting purposes comments can help you in debugging your WhizBase code - simply comment the part you suspect that generates the error and test the page again.

read more

CHR ($WBFN)

Availability
CHR is available for use with all WBSP commands.
Syntax:
$WBFN[CHR(decnumber)]
Arguments
decnumber - any integer in range 0 to 255.
Description
This function returns a character from the ASCII code of a decimal number.

Example of use

Using $wbfn function with chr() to give a character from ASCII code 65.


Character with ASCII code 65 is $wbfn[chr(65)]!

Result
Character with ASCII code 65 is A
 

CP (WB_Command) - Change DB user password

Description
This command is used for setting a new password for specified user (WB_DBUser) in workgroup file (WB_System), using old password value (WB_DBOldPass) and new password value (WB_DBNewPass) that can be verified using control password value (WB_DBNPassCh). The result can be displayed using $WBAdmin[] tag.

read more

Wednesday, September 8, 2010

CGISecurityString

CGISecurityString=anystring
This variable has no effect on the WhizBase when it is installed as a scripting engine. It contains the administrator-defined case-sensitive string that must match the beginning of the file used to activate the WhizBase in the CGI mode. It is used when for some reason it is not suitable to use ActivateCGIByExt. There is no default value for this variable.

Example of use:

CGISecurityString variable is used in Server configuration section, a configuration is set for all aliases of a single virtual host.
[wbsp.com]
DisableWB=F
AbsolutePath=On
Upload=On
FileCommands=On
Execute=JavaScript,VBScript,JScript
HiddenEnvVars=PATH,COMP*,System*
TimeOutSec=20
DefaultDocument=index.wbsp
ADOConnectionString=T
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=0
HideDocuments=sr,aut,inc,ic,mdb
ScriptTimeOutSec=60
And in every WBSP file:
CGISecurityString=LnTW34FxD

Valid WBSP file:
LnTW34FxD
[FormFields]
wb_command=...

Invalid WBSP file:
[FormFields]
wb_command=...
 

CGI mode

Unlike previous versions that were either CGI program or hypertext pre-processor, from WhizBase 5 it can be used both ways.

To use WhizBase in CGI mode you still need valid WBSP file, but instead of calling WBSP file directly (e.g. http://someserver/somefile.wbsp) you should insert in your URL engine file followed by full wbsp file path relative to the web server's root directory (e.g. http://someserver/cgi-bin/wbsp.exe/somefile.wbsp).

Due to security reasons we have disabled direct execution of the engine file
(e.g. http://someserver/cgi-bin/wbsp.exe?wb_basename=somebase.mdb&wb_rcdset=sometable&wb_command=q will not work).

read more

Bottom section

Everything from comment to the end of the report template is Bottom section. It will be processed by WBSP engine and sent to client, after WBSP processes  the DB related functions , they will not produce error, but they also will not return proper value (eg. for all $wbf functions it will return empty string). To display proper result of these functions in bottom section, place the result in a variable using $wbsetv function, and retrieve them in bottom section using $wbgetv function.
Here's an example (bottom section is marked blue)




Titles


Year published Title ISBN
$wbf[Year published] $wbf[title] $wbf[ISBN]


$wb_navigator[]

BIN ($WBFN)

Availability
BIN is available for use with all WBSP commands.
Syntax
$WBFN[BIN(decnumber)]
Arguments
decnumber - any integer in range 0 to 2147483647.
Returns
A string representing the binary value of the number passed as an argument.
Example of use:
Use it in any WBSP file:


Binary value of letter A is $wbfn[bin(65)]!

Result
Binary value of letter A is 1000001!

read more

ASC ($WBFN)

Availability
ASC is available for use with all WBSP commands.
Syntax
$WBFN[ASC(character)]
Arguments
character - any ASCII character.
Returns
An ASCII code of the character passed as an argument.
Example of use:
Use it in any WBSP file:


ASCII code of letter A is $wbfn[asc(A)]!

Result
ASCII code of letter A is 65!

read more 

Tuesday, September 7, 2010

HTML form and input elements

HTML from

The Form element is used to delimit a data input form. There can be several forms in a single document, but the Form element cannot be nested. (i.e. a form cannot contain another form)

The ACTION attribute is a URL specifying the location to which the contents of the form data fields are submitted to elicit a response. As mentioned before, this could be simply a direction to an e-mail address, but generally, would be used to point towards some kind of server based CGI script/application that handles the forwarding of form data. If the ACTION attribute is missing, the URL of the document itself is assumed. The way data is submitted varies with the access protocol of the URL to which the form data is sent and with the values of the METHOD and ENCTYPE attributes.
Generally, the METHOD attribute specifies a method of accessing the URL specified in the ACTION attribute and will be either GET or POST. The GET method is ideal for form submission where the use of the form data does not require external processing. For example, with database searches, there is no lasting effect caused by the query of the form (that is, the query runs its search through the database and reports the results). However, where the form is used to provide information for example, that updates a database, then the POST method should be used, with the ACTION attribute pointing to a CGI script that executes the form data processing.
The ENCTYPE specifies the media type used to encode the form data. The default ENCTYPE is the MIME type 'application/x-www-form-urlencoded'
The
element can also accept the TARGET attribute (as in elements), to specify what window is used for any form feedback. It can take the following values : can also take the NAME attribute, which can be used to set the name of the element for scripting purposes.

Input elements

ALIGN
Vertical alignment of the image. For use only with TYPE=IMAGE in HTML level 2. The possible values are exactly the same as for the ALIGN attribute of the element.

CHECKED
Indicates that a checkbox or radio button is selected. Unselected checkboxes and radio buttons do not return name/value pairs when the form is submitted.

MAXLENGTH
Indicates the maximum number of characters that can be entered into a text field. This can be greater than specified by the SIZE attribute, in which case the field will scroll appropriately. The default number of characters is unlimited.

NAME
Symbolic name used when transferring the form's contents. The NAME attribute is required for most input types and is normally used to provide a unique identifier for a field, or for a logically related group of fields. The name given to the element can also be used to reference it for scripting purposes.

SIZE
Specifies the size or precision of the field according to its type. For example, to specify a field with a visible width of 24 characters:
INPUT TYPE="text" SIZE="24"

SRC
To be used with the TYPE=IMAGE , this attribute represents a URL specifying an the desired image.

TEXT: is used for a single line text entry fields. It should be used in conjunction with the SIZE and MAXLENGTH attributes to set the maximum amount of text that can be entered. For textual input that requires multiple lines, the

Appendixes

User defined formats
Named formats
Format expression rules
HTML form and input elements
SQL patterns
The American Standard Code for Information Interchange - ASCII

read more

ADOConnectionString

Syntax:ADOConnectionString=On/Off
If this variable is set to True then WBSP will accept any valid ADO connection string in WB_DBObject . If it is set to False then WB_DBObject will accept only predefined values D35, D36, A35, A40 and A07. Default value is off.

Example of use

ADOConnectionString variable is used in Server configuration section, a configuration is set for all aliases of a single virtual host.
[wbsp.com]
DisableWB=F
AbsolutePath=On
Upload=On
FileCommands=On
Execute=JavaScript,VBScript,JScript
HiddenEnvVars=PATH,COMP*,System*
TimeOutSec=20
DefaultDocument=index.wbsp
ADOConnectionString=T
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=0
HideDocuments=sr,aut,inc,ic,mdb
ScriptTimeOutSec=60

[dsd.ba]
DisableWB=F
AbsolutePath=Off
Upload=On
FileCommands=Off
Execute=VBScript
HiddenEnvVars=PATH,COMP*,System*,Win*
TimeOutSec=10
DefaultDocument=default.wbsp
ADOConnectionString=F
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=10
 

AG (WB_Command) - Add DB user to group

Description
This command is used for adding specified user (WB_DBUser) to specified group (WB_DBGroup) in workgroup file (WB_System). The result can be displayed using $WBAdmin[] tag.

read more 

AU (WB_Command) - Add DB user or group

Description
This command is used for adding specified user (WB_DBUser) or specified group (WB_DBGroup) to workgroup file (WB_System). The result can be displayed using $WBAdmin[] tag.

read more

Monday, September 6, 2010

A (WB_ Command ) - Add

Syntax: WB_Command=A
Description
This command is used for adding the new records to the database. When executed, it opens the recordset (variables WB_RcdSet must be defined when you use this command), adds the record(s) and displays processed WBSP page or redirects client to URL defined in WB_Redirect variable.
Note: If WBSP page with command A receives form data for more than one record, it will add all the records received. In this case WhizBase requires arrays of WBF_ fields with equal number of members (e.g. if you are adding 3 fields for 4 records you MUST send four sets of WBF_field1, WBF_fied2 and WBF_field3 form fields).

Example of use

Using addition with WB_Command in a WhizBase file.
[FormFields]
WB_BaseName=biblioA.mdb
WB_RcdSet=Titles
WB_Command=A
WB_Redirect=default.wbsp
 
 

ActivateCGIByExt

Syntax:ActivateCGIByExt=fileextension
This variable has no effect on WhizBase that is installed as a scripting engine. It defines the file extension required for activating WhizBase in CGI mode. The default value is wbsp (WhizBase can be activated in CGI mode only by a file with .wbsp extension), and if, for any reason, there is a need for disabling this security measure set this variable to $empty$.

Example of use

ActivateCGIByExt variable is used in Server configuration section, a configuration is set for all aliases of a single virtual host.
[wbsp.com]
DisableWB=F
AbsolutePath=On
Upload=On
FileCommands=On
Execute=JavaScript,VBScript,JScript
HiddenEnvVars=PATH,COMP*,System*
TimeOutSec=20
DefaultDocument=index.wbsp
ADOConnectionString=T
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=0
HideDocuments=sr,aut,inc,ic,mdb
ScriptTimeOutSec=60

[dsd.ba]
DisableWB=F
AbsolutePath=Off
Upload=On
FileCommands=Off
Execute=VBScript
HiddenEnvVars=PATH,COMP*,System*,Win*
TimeOutSec=10
DefaultDocument=default.wbsp
ADOConnectionString=F
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=10
 

Access control

WhizBase controls page access using both IP filtering (WB_IPListFile) and user's credentials (WB_HTAccess, WB_HTUsr, WB_HTPass).

read more

AbsolutePath

Syntax:AbsolutePath=On/Off
If this variable is set to True, WBSP engine will allow owner of the site (author, user that creates WBSP files and uploads them to server) to use absolute path names, i.e. to access files outside his wwwroot directory, files located on other disks or even other network computers.
Setting this value to True can have great advantages on intranet (or if you use entire server exclusively) but it is not wise to set this to True on shared web server with many users. Default value is False.

Example of use

AbsolutePath variable is used in Server configuration section, a configuration is set for all aliases of a single virtual host.
[wbsp.com]
DisableWB=F
AbsolutePath=On
Upload=On
FileCommands=On
Execute=JavaScript,VBScript,JScript
HiddenEnvVars=PATH,COMP*,System*
TimeOutSec=20
DefaultDocument=index.wbsp
ADOConnectionString=T
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=0
HideDocuments=sr,aut,inc,ic,mdb
ScriptTimeOutSec=60

[dsd.ba]
DisableWB=F
AbsolutePath=Off
Upload=On
FileCommands=Off
Execute=VBScript
HiddenEnvVars=PATH,COMP*,System*,Win*
TimeOutSec=10
DefaultDocument=default.wbsp
ADOConnectionString=F
ActivateCGIByExt=wbsp
CGISecurityString=LhBv3KP
MaxInstances=10
 

75 - Path/File access error

This error is generated when WhizBase tries to write file in a directory where it has no write permissions.
To solve this assign the user that starts WhizBase (usually Internet Guest Account) full access permissions (read/write) to directories that require writing (e.g. upload directories, directories where log and database files are located, etc.).

read more

Friday, September 3, 2010

5084 - Required form field 'WB_SMSPort' missing!

This error is generated when user tries to execute WB_Command SMS and WB_SMSPort variable is empty. For more information please read the explanation for WB_SMSPort variable (section FormFields).

read more

5083 - Empty SMS list recordset!

This error is generated when user tries to execute SMS List command (SMS with WB_SMSField) and resulting recordset is empty.

read more

5082 - Invalid path!

This error is generated when WhizBase receives an invalid path to any file in any variable or function.

read more

5081 - Invalid assign method! Use WBAAdd[] function.

This error is generated when you try to set value of an array element using $WBAADD function.

read more

5080 - Invalid time out interval

This error is generated when WB_TimeOut variable receives value less than 0 or greater than 86400.

read more

5079 - Script time out error

This error is generated when single WBSP page takes more time to execute than it is defined in WB_TimeOut variable.

read more

5078 - $WBCASE function syntax error

This error is generated when:
  1. $WBCASE function does not have all five arguments
  2. Arguments "condition list" and "result list" do not have same number of items.
read more

5077 - Too many instances for server !

This error is generated when number of instances of WBSP.EXE started by single virtual server is greater than number defined in server configuration variable MaxInstances.

read more

5076 - WB_Redirect required!

This error is generated when WBSP file that uses WB_Destination variable does not have WB_Redirect variable defined.

read more

5075 - Syntax error

This error is generated when WBSP tries to process nested function with syntax error (usually illegal use of # character).

read more