Changes in v3.2
-------------------------
1. redirectonly configuration variable
A new configuration variable, redirectonly, has been
added to the CGI versions of Miva. This flag allows you
to configure Miva to only allow itself to be invoked
via Apache redirect.
redirectonly=yes|no
2. serveruserid configuration variable
A new configuration variable, serveruserid, has been
added to the CGI versions of Miva. serveruserid allows you
to control which user id may execute the Miva binary. This
allows you to prevent people with shell access from executing
the Miva binary from a shell prompt.
serveruserid=[numeric userid]
3. GET support
Miva now supports name/value pairs as part of the URL. This
allows Miva to process HTML FORMs submitted using a METHOD of
GET. In addition, it makes parsing the s.argN variables a
thing of the past.
A global variable is created for each variable passed in the
URL. For example, the URL:
http://www.somesite.com/test.mv?VarA=This+is+a+test&VarB=123
would create two global variables:
VarA = This is a test
VarB = 123
If a variable is specified without a value, it will be created
with its value equal to the name of the variable.
4. UPS OnLine Cost Calculation
MvCOMMERCE now supports a METAMETHOD of UPSCost. This allows
you to do *online* calculation of UPS shipping charges using
UPS' CGI gateway.
Syntax:
The value of the FIELDS attribute is dependent on the request, and
is beyond the scope of this document. You can see ups.mv for
a partial list, or download the complete documentation from
UPS' web site.
Depending on the services requested, MvCOMMERCE will iterate
once or multiple times. Iteration may be stopped by using
MvCOMMERCESTOP.
While inside the MvCOMMERCE block, the following variables are
available:
errmsg Description of error, or NULL if no
error occurred.
errorcode Numeric code of error, or NULL if no
error occurred.
message Informational message
product UPS product code
orig_postal Shipment source postal code
orig_country Shipment source country code
dest_postal Shipment destination postal code
dest_country Shipment destination country code
zone UPS shipping zone
weight Shipment weight
productchrg Shipment charge, minus any accessory or
surcharges
accs_surcharg Shipment accessory or surcharges
totalchrg Total cost of shipment
time Commit time, or -1 if EOD
5. dBase III Memo Fields
dBase III memo fields are now supported.
Syntax:
Memo field data is stored in a separate file. The memo file
has the same name as the database file, but with the extension
.DBT. The memo file is automatically created/opened by Miva.
Due to the structure of the dBase III memo file, all updates are
done by simply appending the new data to the end of the file.
To prevent the memo files from growing out of control, Miva only
updates the memo file when a field is considered "dirty." A
field is flagged as dirty whenever a value is assigned to it,
even if that value is the same as the previous value of the field.
6. MvFILTER
A new tag, MvFILTER, has been added. MvFILTER provides a fast,
easy way to do sequential searches through a dBase database.
Syntax:
After specifying a filter, only fields which match the filter
will be "visible."
The variables totrec and recno will still refer to the total
number of records in the database and the absolute record
number.
When using MvFIND with a filter, the first record which matches
both the value being searched for and the filter will be found.
7. MvDO
A new tag, MvDO, has been added. MvDO provides an easy way
to include HTML and/or Miva code from supplemental script
files.
Syntax:
If the NAME and VALUE attributes are specified, Miva will
evaluate the expression in VALUE and store the result into
NAME (this would be used, for example, to call a function
in the file specified by FILE).
If NAME/VALUE are not specified, Miva will simply begin
executing the file specified by FILE from the top, and
will merge the output of the supplemental file with the
output of the primary file.
8. encodeentities/decodeentities
Two new builtin functions are provided to encode and decode
HTML entities (ie >, <, etc..).
Syntax:
9. makesessionid/Cookies
Cookies have been revamped again. The htscallerid cookie now
expires one year after being set, and has been lengthened to
128 bits to aid uniqueness.
In addition, a builtin function, makesessionid, has been
provided to generate a 128 bit unique id.
Syntax:
10. MvLOCKFILE
...
MvLOCKFILE exclusively locks a file.
11. Macro Encoding
The output of macros may now be optionally encoded:
&[ [:encoding] ]
Where encoding is one of the following:
entities Functionally the same as encodeentities()
attribute Functionally the same as encodeattribute()
i.e.:
&[ g.FormField:entities ]
Changes in Miva Mia v1.20 Beta 3
--------------------------------
1. Fixed a bug which caused MvEXIT within a function called via MvDO to crash.
2. Changed MvDO to function relative to the directory of the "master" script
file.
3. Fixed a crash which occurred when a filter is set inside a file called
with MvDO.
4. Changed dBase MEMO fields to be loaded only when they are referenced.
5. EncodeAttribute() no longer encodes underscores.
6. Added the "string" FLAG for dBase indexes to force string comparisons
in the case of large numeric strings.
7. Fixed several memory overwrites in the SCMP processing code.
8. Fixed a bug which would cause spurious syntax errors when an index
expression or MvDO function call contained parenthesis or commas
inside a quoted string.
9. Fixed a bug which caused the EOF flag to be reset when skipping 0
rows.
10. Fixed a bug in the UPSOnLine Cost Calculation which prevented
sending values with spaces.
11. dBase NUMBER fields now truncate numbers to the specified number
of decimal places.
12. Fixed a bug which caused MvSKIP operations immediately following
an MvUPDATE to occasionally go to the wrong row.
13. Indexes are now updated ONLY if the index key value has changed.
14. Fixed a bug which caused MvSKIP after MvPRIMARY to position to the
wrong row.
15. Fixed a bug which caused pages to display incorrectly in v3.X browsers
and Opera.
16. Fixed a crash which occurred when dBase files with version tags
other than 0x83 contain memo fields.
17. A new tag, MvLOCKFILE, has been added:
...
MvLOCKFILE exclusively locks a file. Please note that it SHOULD NOT
be used to lock an in-use dBase file, as this will cause a deadly
embrace. Instead, you should create a semaphore file and lock it.
i.e.:
18. The output of macros may now be optionally encoded:
&[ [:encoding] ]
Where encoding is one of the following:
entities Functionally the same as encodeentities()
attribute Functionally the same as encodeattribute()
i.e.:
&[ g.FormField:entities ]
19. Fixed a bug which caused a dBase memo file to be incorrectly updated while
at EOF.
20. A new function, gettoken() has been added:
gettoken() allows quick parsing of strings, ala the C function strtok:
gettoken( string, separators, position )
string The source string
separators A string containing the single character separators
position The token to retrieve
gettoken() returns the specified token, or NULL if the token could not be found.
i.e.:
21. Fixed a bug which prevented storing negative numbers into dBase NUMBER fields.
22. Fixed bugs in rtrim and ltrim which prevented them from correctly removing newlines.
23. Added STANDARDOUTPUTLEVEL and ERROROUTPUTLEVEL attributes to MvFUNCTION:
STANDARDOUTPUTLEVEL and ERROROUTPUTLEVEL may now be specified for a function.
If specified, they override the previous settings until the function returns.
i.e:
... Some large looping operation ...
Changes in Miva Mia v1.20 Beta 2
--------------------------------
New Features
- GET support
Miva now supports name/value pairs as part of the URL. This
allows Miva to process HTML FORMs submitted using a METHOD of
GET. In addition, it makes parsing the s.argN variables a
thing of the past.
A global variable is created for each variable passed in the
URL. For example, the URL:
http://www.somesite.com/test.mv?VarA=This+is+a+test&VarB=123
would create two global variables:
VarA = This is a test
VarB = 123
If a variable is specified without a value, it will be created
with its value equal to the name of the variable.
- UPS OnLine Cost Calculation
MvCOMMERCE now supports a METAMETHOD of UPSCost. This allows
you to do *online* calculation of UPS shipping charges using
UPS' CGI gateway.
Syntax:
The value of the FIELDS attribute is dependent on the request, and
is beyond the scope of this document. You can see ups.mv for
a partial list, or download the complete documentation from
UPS' web site.
Depending on the services requested, MvCOMMERCE will iterate
once or multiple times. Iteration may be stopped by using
MvCOMMERCESTOP.
While inside the MvCOMMERCE block, the following variables are
available:
errmsg Description of error, or NULL if no
error occurred.
errorcode Numeric code of error, or NULL if no
error occurred.
message Informational message
product UPS product code
orig_postal Shipment source postal code
orig_country Shipment source country code
dest_postal Shipment destination postal code
dest_country Shipment destination country code
zone UPS shipping zone
weight Shipment weight
productchrg Shipment charge, minus any accessory or
surcharges
accs_surcharg Shipment accessory or surcharges
totalchrg Total cost of shipment
time Commit time, or -1 if EOD
- dBase III Memo Fields
dBase III memo fields are now supported.
Syntax:
Memo field data is stored in a separate file. The memo file
has the same name as the database file, but with the extension
.DBT. The memo file is automatically created/opened by Miva.
Due to the structure of the dBase III memo file, all updates are
done by simply appending the new data to the end of the file.
To prevent the memo files from growing out of control, Miva only
updates the memo file when a field is considered "dirty." A
field is flagged as dirty whenever a value is assigned to it,
even if that value is the same as the previous value of the field.
- MvFILTER
A new tag, MvFILTER, has been added. MvFILTER provides a fast,
easy way to do sequential searches through a dBase database.
Syntax:
After specifying a filter, only fields which match the filter
will be "visible."
The variables totrec and recno will still refer to the total
number of records in the database and the absolute record
number.
When using MvFIND with a filter, the first record which matches
both the value being searched for and the filter will be found.
- MvDO
A new tag, MvDO, has been added. MvDO provides an easy way
to include HTML and/or Miva code from supplemental script
files.
Syntax:
If the NAME and VALUE attributes are specified, Miva will
evaluate the expression in VALUE and store the result into
NAME (this would be used, for example, to call a function
in the file specified by FILE).
If NAME/VALUE are not specified, Miva will simply begin
executing the file specified by FILE from the top, and
will merge the output of the supplemental file with the
output of the primary file.
- encodeentities/decodeentities
Two new builtin functions are provided to encode and decode
HTML entities (ie >, <, etc..).
Syntax:
- makesessionid/Cookies
Cookies have been revamped again. The htscallerid cookie now
expires one year after being set, and has been lengthened to
128 bits to aid uniqueness.
In addition, a builtin function, makesessionid, has been
provided to generate a 128 bit unique id.
Syntax:
- CyberSource SCMP
This build of Miva Mia supports CyberSource SCMP commerce
processing. For full documentation on the Miva/CyberSource
integration, see http://www.htmlscript.com/cybersource
Bug Fixes
Fixed a bug which caused the process_id variable to be negative.
Fixed a bug which caused empty dBase CHAR fields to show up as
a single space instead of NULL.
Fixed several crashes caused by using MvPACK while a filter was
in use.
Fixed a bug which caused records added when the current record is
marked as deleted to be added as deleted.
Fixed a bug which prevented removing a filter once one had been
specified. To remove the filter, simply use MvFILTER with no
FILTER attribute specified.
Fixed isalpha. It was behaving as if it were isnumber.