| | maillist.mv v1.0 - Illustration of processing a form to create | a mailing list | | PROCEDURE FOR INSTALLING THIS TEMPLATE: | | 1. Copy and run | maillist.mv will automatically create | the files it needs. | | DIRECTORIES/FILES IT USES: | (These can easily be changed--See the section labelled | global variables) | | mailing.dat A delimited text file containing | the people who have signed up for | the mailing list. | | WHERE TO GET HELP: | | Htmlscript maintains an open list server for the Miva | users group. You can post messages to this list with questions | and items of interest for other htmlscript users. To subscribe | to this list send email to majordomo@htmlscript.com with the | following on the *first line* of the message body (not the subject): | | subscribe hts-users [your email address] | | Email your questions to: hts-users@htmlscript.com | | global variables | | DESCRIPTION: | | These variables are used throughout the program. Lista de e-mails de WebFe | This little section of code decides if the document | has been loaded because the user has submitted the form, | or because the user has come to the form for the first | time. | | The variable "beenhere" is actually a hidden FORM | field--if the form has not been submitted, it will | have a value of "" (NULL) | validateform() | | DESCRIPTION: | | validateform() checks the values the user | submitted with the form and either | | a) Saves the data to a file if it | matches the validation rules | and displays a message telling | the user they have been added to | the mailing list | | - or - | | b) Prints error messages telling the | user which fields are invalid | and redisplays the form. | | The variables "person" "email" and "phone" were automatically | created by Miva from the submitted form values | The person's name must be at least 3 characters | long and contain at least one space | The person's email address must be at least 3 characters | long and contain an @ | The person's phone number must be at least 7 characters long | formerror() | | DESCRIPTION: | | formerror() displays an error message telling the user | that they have not filled out the form correctly. | It also sets the global variable "formerror" to 1, | telling validateform() that there is an error in the form | and the submitted data should not be added to the mailing | list. Error de datos de entrada:

  1. | printform() | | DESCRIPTION: | | printform() displays the mailing list form
     
    Lista de Correos
     
    Su nombre y Apellido:
    Su e-mail :
    Ciudad:
    | Create a hidden form field that will let us know we | are processing submitted form data
    Este sitio se ve mejor en 800 x 600 16bits color
    Enviar comentarios y sugerencias a info@webfe.com.ar
    Copyright © 1999 WebFe.com.ar. Todos los derechos reservados.

    | savedata() | | DESCRIPTION: | | savedata() uses MvEXPORT to save the submitted form | data to a file.
     
    Lista de Correos

     

    A sido agregado a nuestra lista de e-mail.

    &[ g.htmlscriptapplets ]

    Gracias por participar.

    Ingrese a consultar nuestra lista de e-mails

     

    Este sitio se ve mejor en 800 x 600 16bits color
    Enviar comentarios y sugerencias a info@webfe.com.ar
    Copyright © 1999 WebFe.com.ar. Todos los derechos reservados.