<?php
/*
The Actual calls to element includes and such are contained within
functions to prevent varaible collision in the main namespace.
*/
Function print_form() {
global $default;

$value      = $default->server;
$desc_text  = 'Default IMAP server';
$size       = 50;
$name       = 'server';
$desc       = '';
include( './templates/setup/form_text_elem.inc' ); 

$value      = $default->from_server;
$desc_text  = 'Default from address append';
$size       = 50;
$name       = 'from_server';
$desc       = 'The address that completes the username@thisvalue combination.';
include( './templates/setup/form_text_elem.inc' ); 

$value      = $default->port;
$desc_text  = 'Default IMAP Port';
$size       = 10;
$name       = 'port';
$desc       = 'The port that the imap server is on i.e. 143';
include( './templates/setup/form_text_elem.inc' ); 

$form_subtitle = 'Cyrus IMAP Configuration';
?>
   <tr bgcolor="<?php echo $default->item_bg; ?>">
      <td colspan="2">
      <font size=+1><b><?php echo( $form_subtitle ); ?> :</b></font>
      </td>
   </tr>

<?php

$value      = $default->cyrus->enabled;
$desc_text  = 'Cyrus IMAP Server';
$size       = 50;
$name       = 'cyrus_enabled';
$desc       = 'Are you using a Cyrus IMAP Server';
include( './templates/setup/form_true_false_elem.inc' );

$value      = $default->personal_folders;
$desc_text  = 'Personal Folders';
$size       = 10;
$name       = 'personal_folders';
$desc       = 'Cyrus IMAP Personal Folders Name';
include( './templates/setup/form_text_elem.inc' );


$form_subtitle = 'Mail Folder Configuration';
?>
   <tr bgcolor="<?php echo $default->item_bg; ?>">
      <td colspan="2">
      <font size=+1><b><?php echo( $form_subtitle ); ?> :</b></font>
      </td>
   </tr>

<?php

$value      = $default->folders;
$desc_text  = 'Mail Folder Root';
$size       = 50;
$name       = 'folders';
$desc       = 'This is the base of where your mail folders live, it is relative to your user directory. I.E. mail/';
include( './templates/setup/form_text_elem.inc' ); 

$value      = $default->use_imap_subscribe;
$desc_text  = 'Use IMAP Subscibe';
$size       = 50;
$name       = 'use_imap_subscribe';
$desc       = '';
include( './templates/setup/form_true_false_elem.inc' ); 

$value      = $default->show_dotfiles;
$desc_text  = 'Show Dot Files';
$size       = 50;
$name       = 'show_dotfiles';
$desc       = 'Show files starting with a period in your folder list.';
include( './templates/setup/form_true_false_elem.inc' );

$value      = $default->save_sent_mail; 
$desc_text  = 'Save Sent Mail';
$size       = 50;
$name       = 'save_sent_mail';
$desc       = '';
include( './templates/setup/form_true_false_elem.inc' );


}

$form_subtitle = 'Mail Server Configuration';
include( './templates/setup/stub_form.inc' );

?>
