PHP Classes

File: test_random_form.php

Recommend this page to a friend!
  Classes of Manuel Lemos   Multipage forms class   test_random_form.php   Download  
File: test_random_form.php
Role: Example script
Content type: text/plain
Description: Example page script to demonstrate multipage forms in random access mode with custom image button generation
Class: Multipage forms class
Create and manage forms split over multiple pages.
Author: By
Last change:
Date: 23 years ago
Size: 1,246 bytes
 

Contents

Class file image Download
<?
/*
 * test_random_form.html
 *
 * @(#) $Header: /cvsroot/PHPlibrary/test_random_form.html,v 1.1 2000/11/20 03:53:26 mlemos Exp $
 *
 */

 
require("forms.php");
 require(
"pagedformclass.php");
 require(
"subscriptionclass.php");

 
$subscription=new subscription_class;
 if(IsSet(
$image))
 {
 
$subscription->OutputImageButton($image);
 }
 else
 {
?><HTML>
<HEAD>
<TITLE>Test for Manuel Lemos' PHP paged form class - Random access</TITLE>
</HEAD>
<BODY>
<H1><CENTER>Test for Manuel Lemos' PHP paged form class - Random access</CENTER></H1>
<HR>
<?
  $subscription
->sequential=0;
 
$subscription->edit=0;
 
$subscription->edit_buttons=1;
  if(
$subscription->load())
  {
   if(
$subscription->finished)
    echo
"<H2><CENTER>".HtmlEntities($subscription->paged_form_object->GetInputValue("user_name")).", your subscription information was successfully updated.</CENTER></H2>\n";
   else
   {
    if(
$subscription->canceled)
     echo
"<H2><CENTER>Your subscription changes were canceled.</CENTER></H2>\n";
   }
   echo
"<H2><CENTER>".HtmlEntities($subscription->page_names[$subscription->page])."</CENTER></H2>\n";
   echo
$subscription->outputform();
  }
  else
   echo
"<H2>Error: ".$subscription->error."</H2>\n";
?>
<HR>
</BODY>
</HTML>
<?
 
}
?>