Please visit our sponsors !
AppML HTML Forms
With AppML, the <htmlform> element defines an
HTML form.
HTMLForm Sub Elements
The <htmlform> element can have the following sub elements:
- title
- stylesheet
- script
- onload
- commands
- sql
- elements
- header
- form
- footer
The Title Element
An AppML <title> element inside an <htmlform> element has the
same function as the title element inside the <appml> element.
If this element is omitted the application will use the default title from
the <appml> element.
The Stylesheet Element
An AppML <stylesheet> element inside an <htmlform> element has
the same function as the stylesheet element inside the <appml> element.
If this element is omitted the application will use the default stylesheet
from the <appml> element.
The Script Element
The AppML <script> element provides a method for adding standard HTML
scripts to the application.
Any legal script code can go inside the <script> element.
Example:
<script type="text/javascript">
<!--
function message()
{
alert("This alert box was called with the onload event")
}
// -->
</script>
|
The Onload Element
The AppML <onload> element defines a script to be executed when the
AppML application loads in a browser.
This example will execute the Javascript "message()" when the AppML
page loads.
<onload>javascript:message()</onload>
|
The Commands Element
The AppML <commands> element provides a method for substituting the
standard AppML commands with another set of commands.
Example:
<commands>
<input type="button" class="cmd"
onclick="javascript:db_putrecord('update')"
value="Submit" />
<input type="button" class="cmd"
onclick="javascript:db_putrecord('delete')"
value="Delete" />
</commands>
|
The SQL Element
The AppML <sql> element defines the SQL statement to be used to extract
data from the database.
If this element is omitted, the input form will use the default <sql>
element from database description.
The Header Element
The AppML <header> element is used to define an additional output that
will be displayed before the actual input form on a page.
Any HTML code may be included inside the <header> element.
The Footer Element
The AppML <footer> element is used to define an additional output that
will be displayed after the actual input form on a page.
Any HTML code may be included inside the <footer> element.
The Elements Element
The <elements> element can have the following sub elements:
- required
- submit
- type
- format
- value
- onchange
The Form Element
The AppML <form> element is used to define the layout of the input
form. If this element is omitted, a default layout is used.
Any legal HTML form elements can be put inside the <form> elements. If
this element is used, each input field inside the form must have an id attribute
that corresponds with the name of the data fields in the underlying recordset.
Example:
<htmlform>
<sql>
Select CompanyName,ContactName,City from Suppliers
</sql>
<form>
<table class='input' width='100%'>
<tr>
<td valign='center'>Company Name</td>
<td>
<input size='41' id='companyname' value='' />
</td>
</tr>
<tr>
<td valign='center'>Contact Name</td>
<td>
<input size='31' id='contactname' value='' />
</td>
</tr>
<tr>
<td valign='center'>City</td>
<td>
<input size='16' id='city' value='' />
</td>
</tr>
</table>
</form>
</htmlform>
|
HTMLForm Attributes
The <htmlform> element has the following attributes:
The Name attribute
The name attribute is used to name the <htmlform> element. This enables
an AppML Form Service to run a number of different input forms from the same
AppML description.
Example:
<htmlform name="Suppliers">
|
The Src attribute
The src attribute provides a reference to an <htmlform> element stored
in an external AppML description file.
Example:
<htmlform name="Suppliers" src="suppliers_input">
|
The New and Delete attributes
The new and delete attribute can be used to disable the NEW and DELETE
buttons from the AppML HTML Form.
Example:
<htmlform new="false" delete="false">
|
An XML Schema for AppML
If you have Internet Explorer, you can Click
Here to view the full XML Schema for an AppML document.
Jump to: Top of Page
or HOME or
Printer friendly page
Search W3Schools:
What Others Say About Us
Does the world know about us? Check out these places:
Dogpile
Alta Vista
MSN
Google
Excite
Lycos
Yahoo
Ask Jeeves
We Help You For Free. You Can Help Us!
W3Schools is for training only. We do not warrant its correctness or its fitness for use.
The risk of using it remains entirely with the user. While using this site, you agree to have read and accepted our
terms of use and
privacy policy.
Copyright 1999-2002 by Refsnes Data. All Rights Reserved
|