;;; modify-task.mhtml: -*- Meta-HTML -*- 

;;;  Copyright (c) 1996 Universal Access Inc.
;;;  Author: Henry Minsky (hqm@ua.com) Fri Sep  6 16:50:54 1996.

<set-var title="Create Rolodex Entry">
<include header.mhtml>
<include rolodex.mhtml>

<require-rolodex-login>

<h1>Create Rolodex Entry</h1>

<b>Name:</b> <get-var entry-name>

<when <match <get-var posted::action> "Create">>
  <add-entry name=<get-var entry-name> 
	    street=<get-var street>
	    city=<get-var city>
	    state=<get-var state>
	    country=<get-var country>
	    zip=<get-var zip>
	    email=<get-var email>
	    dayphone=<get-var dayphone>
	    evephone=<get-var evephone>
	    fax=<get-var fax>
	    comments=<get-var comments>>
  <redirect "welcome.mhtml">
</when>

;;; Put up a text input field
<defsubst input-field var>
  <tr>
    <th align=right><get-var var></th>
    <td>
      <input type=text size=24 name=<get-var var> value=<get-var <get-var var>>>
    </td>
  </tr>
</defsubst>


<defsubst create-entry>
  <form action="<get-var mhtml::current-doc>" method=post>
    <b>Name:</b> <input type=text name="entry-name" size=48><br>
    <b>Created:</b> 
    <date <get-var creation-time>><br>
    
    <table>
    <input-field Street>
    <input-field City>
    <input-field State>
    <input-field Country>
    <input-field Zip>
    <input-field Email>
    <input-field Dayphone>
    <input-field Evephone>
    <input-field Fax>

    <tr>
	<td align=right>
	  <b>Comments:</b><br>
	  <textarea name=text cols=48 rows=4></textarea>
	  </td>
	</tr>
    </table>
    <center>
      <input type=submit name=action value="Create">
      <input type=submit name=action value="Cancel">
    </center>
  </form>
</defsubst>

<create-entry>

<include footer.mhtml>