<head>

<?php


    $table_name = $_SESSION['db_prefix']."_list_places";
    $position_query = "SELECT item_name FROM $table_name ORDER BY item_name ASC";
	$arrId2 = array ();
	$arrName2 = array ();
	$position_result = execsql($position_query);
	if ($position_result!="") {
	$position_num = mysql_num_rows($position_result);
	$b = 0;
	while ($b < $position_num) {
		$arrId2[$b] = mysql_result($position_result, $b, "item_name");
		$arrName2[$b] = mysql_result($position_result, $b, "item_name");
		$b++;
	}
	}
	
	$table_name = $_SESSION['db_prefix']."_list_country";
    $position_query = "SELECT item_name FROM $table_name ORDER BY item_name ASC";
	$arrId1 = array ();
	$arrName1 = array ();
	$position_result = execsql($position_query);
	if ($position_result!="") {
	$position_num = mysql_num_rows($position_result);
	$b = 0;
	while ($b < $position_num) {
		$arrId1[$b] = mysql_result($position_result, $b, "item_name");
		$arrName1[$b] = mysql_result($position_result, $b, "item_name");
		$b++;
	}
	}
	
	$table_name = $_SESSION['db_prefix']."_list_account";
    $position_query = "SELECT item_name FROM $table_name ORDER BY item_name ASC";
	$arrId5 = array ();
	$arrName5 = array ();
	$position_result = execsql($position_query);
	if ($position_result!="") {
	$position_num = mysql_num_rows($position_result);
	$b = 0;
	while ($b < $position_num) {
		$arrId5[$b] = mysql_result($position_result, $b, "item_name");
		$arrName5[$b] = mysql_result($position_result, $b, "item_name");
		$b++;
	}
	}
?>
<!--style sheets-->

<!--jscript-->
<script language="JavaScript" src="../jscript/gen_validatorv4.js"  type="text/javascript" xml:space="preserve"></script>
<script language="JavaScript" src="../jscript/capitalize_textbox.js"  type="text/javascript"></script>  
<script language="JavaScript" src="../jscript/lower_case.js"  type="text/javascript"></script>
<script language="JavaScript" src="../jscript/upper_case.js"  type="text/javascript"></script>  
<script language="JavaScript" src="../jscript/numbers_only.js"  type="text/javascript"></script>

</head>
<?php include('../include/wait.php') ?>
<body onLoad="MM_showHideLayers('wait','','hide')" onFocus="MM_showHideLayers('wait','','hide');">

<div class="page_middle_frame">
<?php


 if ($_SESSION['type']=="corporate") { ?>

<form id="feedbackform" method="get" action="orderTilesWizbase.php">
                   
            <div class="wizard_frame">
              <table width="630" id="table_display_wizard">
                <tr>
                  <td>Account:</td>
                  <td><?php echo $_SESSION['type']; ?></td>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
                <tr>
                  <td width="123">Company name:
&nbsp;&nbsp;
<label class="star">*</label></td>
                  <td width="216"><input name="comp_name_text" type="text" class="text200" id="comp_name_text" value="<?php echo $_SESSION['comp_name'] ?>" onKeyUp="ToLower(this)" onBlur="capitalize(this)" autofocus tabindex="1"/></td>
                  <td width="92">&nbsp;</td>
                  <td width="179">&nbsp;</td>
                  </tr>
              </table>
              <table width="630" id="table_display_wizard">
                <tr>
                  <td>Postal address:&nbsp;&nbsp;<label class="star">*</label></td>
                  <td><select name="bag_box_select" class="select80" id="bag_box_select" tabindex="2">
                    <option value="PO Box">PO Box</option>
                    <option value="P Bag">P Bag</option>
                    <option value="<?php echo $_SESSION['bag_box'] ?>" selected="selected"><?php echo $_SESSION['bag_box'] ?></option>
                  </select>
                    <label class="label_std">
                      <input name="box_no_text" type="text" class="text100" id="box_no_text" value="<?php echo $_SESSION['box_no'] ?>" onKeyUp="ToUpper(this)" tabindex="3"/>
                    </label></td>
                  <td>Place:&nbsp;&nbsp;<label class="star">*</label></td>
                  <td><select name="post_place_select" class="select120"  tabindex="4">
                    <option value="<?php echo $_SESSION['post_place'] ?>" selected="selected"><?php echo $_SESSION['post_place'] ?></option>
                    <?php
        	for ($j = 0; $j < count($arrId2); $j++) {
    		echo "<option value=" . "\"" . $arrId2[$j] . "\"" . ">" . $arrName2[$j] . "</option>";
	}
?>
                  </select></td>
                </tr>
                <tr>
                  <td>Physical address:</td>
                  <td><input name="phys_address_text" type="text" class="text200" id="phys_address_text"  onblur="capitalize(this)" onKeyUp="ToLower(this)" value="<?php echo $_SESSION['phys_address'] ?>" tabindex="5"/></td>
                  <td>Place:</td>
                  <td><select name="phys_place_select" class="select120"  tabindex="6">
                    <option value="<?php echo $_SESSION['phys_place'] ?>" selected="selected"><?php echo $_SESSION['phys_place'] ?></option>
                    <?php
        	for ($j = 0; $j < count($arrId2); $j++) {
    		echo "<option value=" . "\"" . $arrId2[$j] . "\"" . ">" . $arrName2[$j] . "</option>";
	}
?>
                  </select></td>
                </tr>
                <tr>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                  <td>Country:</td>
                  <td><select name="country_select" class="select120"  tabindex="7">
                  <option value="<?php echo $_SESSION['country'] ?>" selected="selected"><?php echo $_SESSION['country'] ?></option>
                  <?php
        	for ($j = 0; $j < count($arrId1); $j++) {
    		echo "<option value=" . "\"" . $arrId1[$j] . "\"" . ">" . $arrName1[$j] . "</option>";
	}
?>
                </select></td>
                </tr>
                <tr>
                  <td>Phone 1:&nbsp;&nbsp;<label class="star">*</label></td>
                  <td><input name="phone_text" type="text" class="text100" id="phone_text" value="<?php echo $_SESSION['phone'] ?>" onKeyPress="return numbersonly(this, event)" tabindex="8"/></td>
                  <td>Fax:</td>
                  <td><input name="fax_text" type="text" class="text100" id="fax_text" value="<?php echo $_SESSION['fax'] ?>" onKeyPress="return numbersonly(this, event)" tabindex="9"/></td>
                </tr>
                <tr>
                  <td>Phone 2</td>
                  <td><input name="phone2_text" type="text" class="text100" id="phone2_text" value="<?php echo $_SESSION['phone_2'] ?>" onKeyPress="return numbersonly(this, event)" tabindex="10"/></td>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
                <tr>
                  <td width="123">Contact 1:
                    &nbsp;&nbsp;
                    <label class="star">*</label></td>
                  <td width="216"><input name="contact_1_text" type="text" class="text200" id="contact_1_text" value="<?php echo $_SESSION['company_contact'] ?>" onKeyUp="ToLower(this)" onBlur="capitalize(this)" tabindex="11"/></td>
                  <td width="92">Cell:&nbsp;&nbsp;
                    <label class="star">*</label></td>
                  <td width="179"><input name="cell_1_text" type="text" class="text100" id="cell_1_text" value="<?php echo $_SESSION['contact_phone'] ?>" onKeyPress="return numbersonly(this, event)" tabindex="12" /></td>
                </tr>
                <tr>
                  <td>e-mail:</td>
                  <td><input name="email_1_text" type="text" class="text200" id="email_1_text" value="<?php echo $_SESSION['email_1'] ?>" onKeyUp="ToLower(this)" tabindex="13"/></td>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
              </table>
              <table width="630" align="left" id="table_display_wizard">
                <tr>
                  <td width="122">Contact 2:
                    &nbsp;</td>
                  <td width="217"><input name="contact_2_text" type="text" class="text200" id="contact_2_text" value="<?php echo $_SESSION['contact_2'] ?>" onKeyUp="ToLower(this)" onBlur="capitalize(this)" tabindex="14"/></td>
                  <td width="92"><label class="label_std">Cell:</label></td>
                  <td width="179"><input name="cell_2_text" type="text" class="text100" id="cell_2_text" value="<?php echo $_SESSION['cell_2'] ?>" onKeyPress="return numbersonly(this, event)" tabindex="15"/></td>
                </tr>
                <tr>
                  <td>e-mail:</td>
                  <td><input name="email_2_text" type="text" class="text200" id="email_2_text" value="<?php echo $_SESSION['email_2'] ?>" onKeyUp="ToLower(this)" tabindex="16"/></td>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
                <tr>
                  <td>Web site:</td>
                  <td colspan="3"><label for="textfield"></label>
                    <input name="web_text" type="text" class="text300" id="web_text" value="<?php echo $_SESSION['web_site'] ?>" tabindex="17"></td>
                  </tr>
                <tr>
                  <td>VAT registration:</td>
                  <td colspan="3">  <input type="text"  class="text300" name="vat_text" id="vat_text" value="<?php echo $_SESSION['vat_no'] ?>" tabindex="18"></td>
                </tr>
                <tr>
                  <td valign="top">Notes:</td>
                  <td colspan="3"> <textarea name="notes_text" cols="60" rows="3" class="text_box" id="notes_text" tabindex="19"><?php echo $_SESSION['notes'] ?></textarea></td>
                </tr>
              </table>
              
            </div>
            <br />
<br>
<br>
<br>

              <table width="590" height="50" align="left" id="table_button_bar">
                <tr>
                  <td width="117"><input type="button" name="lastprev_button" class="imagebutton" value="Prev" onClick="needToConfirm = false;MM_showHideLayers('wait','','show');MM_goToURL('parent','orderTilesWizbase.php?s=&amp;p=2');return document.MM_returnValue" tabindex="22"/></td>
                  <td width="115">&nbsp;</td>
                  <td width="99">
                    <input name="p" type="hidden" id="p" value="3" />
                    <input name="s" type="hidden" id="s" value="3" />
                  </span></td>
                  <td width="125" align="right"><input name="cancel_button" type="button" class="imagebutton" id="cancel_button" onClick="editwindow=dhtmlmodal.open('editBox', 'iframe', '../edit_windows/undo_quote.php?quote_no=<?php echo $_SESSION['quote_no'] ?>&status=cancel&p=3', 'Cancel create job', 'width=500px,height=125px,center=1,resize=0,scrolling=0')
needToConfirm = false;
editwindow.onclose=function(){return window}; return false" value="Cancel" tabindex="23"/></td>
                  <td width="110" align="right"><input type="submit" name="next_button" class="imagebutton" value="Next" tabindex="20" onClick="needToConfirm = false; "  /></td>
                </tr>
            </table>
</form>
<!--form validation-->
  <script language="JavaScript" type="text/javascript" xml:space="preserve">
  var frmvalidator  = new Validator("feedbackform");
  frmvalidator.EnableMsgsTogether();
  frmvalidator.addValidation("comp_name_text","req","Please enter the name of the company.");
  frmvalidator.addValidation("bag_box_select","req","Please select bag or box number.");
  frmvalidator.addValidation("box_no_text","req","Please enter bag or box number.");
  frmvalidator.addValidation("post_place_select","req","Please select postal place.");
  frmvalidator.addValidation("phone_text","req","Please enter phone number.");
  frmvalidator.addValidation("contact_1_text","req","Please enter a contact.");
  frmvalidator.addValidation("cell_1_text","req","Please enter contact cell number.");
  </script>
  
  <?php } ?>
            
  <?php if ($_SESSION['type']=="private") { ?>
  
<form id="feedbackform" method="get" action="orderTilesWizbase.php">
  <table id="tableMain" width="595">
    <!--begin of tableMain-->
    <tr>
      <td><!--center of tableMain-->
        <table width=595 border="0" align="center" cellpadding="10" cellspacing="0" bordercolor="#0066FF" border-collapse="collapse">
          <tr>
            <td width="525" valign="top" >
            
            <div class="wizard_frame">
              <table width="630" id="table_display_wizard">
                <tr>
                  <td>Account:</td>
                  <td><?php echo $_SESSION['type']; ?></td>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
                <tr>
                  <td width="124">Last name:
&nbsp;&nbsp;
<label class="star">*</label></td>
                  <td width="216"><input name="comp_name_text" type="text" class="text200" id="comp_name_text" value="<?php echo $_SESSION['comp_name'] ?>" onKeyUp="ToLower(this)" onBlur="capitalize(this)"/></td>
                  <td width="92">First name:</td>
                  <td width="178"><input name="first_name_text" type="text" class="text150" id="first_name_text" value="<?php echo $_SESSION['name_2'] ?>" onKeyUp="ToLower(this)" onBlur="capitalize(this)"/></td>
                  </tr>
                <tr>
                  <td>Title:</td>
                  <td><label for="select"></label>
                    <select name="title_select" class="select80" id="title_select">
                      <option value="Mr">Mr</option>
                      <option value="Mrs">Mrs</option>
                      <option value="Miss">Miss</option>
                      <option value="Dr">Dr</option>
                      <option value="<?php echo $_SESSION['title']?>" selected><?php echo $_SESSION['title']?></option>
                    </select></td>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
              </table>
              <table width="630" id="table_display_wizard">
                <tr>
                  <td>Postal address:&nbsp;&nbsp;<label class="star">*</label></td>
                  <td><select name="bag_box_select" class="select80" id="bag_box_select">
                    <option value="PO Box">PO Box</option>
                    <option value="P Bag">P Bag</option>
                    <option value="<?php echo $_SESSION['bag_box'] ?>" selected="selected"><?php echo $_SESSION['bag_box'] ?></option>
                  </select>
                    <label class="label_std">
                      <input name="box_no_text" type="text" class="text100" id="box_no_text" value="<?php echo $_SESSION['box_no'] ?>" onKeyUp="ToUpper(this)"/>
                    </label></td>
                  <td>Place:&nbsp;&nbsp;<label class="star">*</label></td>
                  <td><select name="post_place_select" class="select120"  >
                    <option value="<?php echo $_SESSION['post_place'] ?>" selected="selected"><?php echo $_SESSION['post_place'] ?></option>
                    <?php
        	for ($j = 0; $j < count($arrId2); $j++) {
    		echo "<option value=" . "\"" . $arrId2[$j] . "\"" . ">" . $arrName2[$j] . "</option>";
	}
?>
                  </select></td>
                </tr>
                <tr>
                  <td>Physical address:</td>
                  <td><input name="phys_address_text" type="text" class="text200" id="phys_address_text"  onblur="capitalize(this)" onKeyUp="ToLower(this)" value="<?php echo $_SESSION['phys_address'] ?>"/></td>
                  <td>Place:</td>
                  <td><select name="phys_place_select" class="select120"  >
                    <option value="<?php echo $_SESSION['phys_place'] ?>" selected="selected"><?php echo $_SESSION['phys_place'] ?></option>
                    <?php
        	for ($j = 0; $j < count($arrId2); $j++) {
    		echo "<option value=" . "\"" . $arrId2[$j] . "\"" . ">" . $arrName2[$j] . "</option>";
	}
?>
                  </select></td>
                </tr>
                <tr>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                  <td>Country:</td>
                  <td><select name="country_select" class="select120"  >
                  <option value="<?php echo $_SESSION['country'] ?>" selected="selected"><?php echo $_SESSION['country'] ?></option>
                  <?php
        	for ($j = 0; $j < count($arrId1); $j++) {
    		echo "<option value=" . "\"" . $arrId1[$j] . "\"" . ">" . $arrName1[$j] . "</option>";
	}
?>
                </select></td>
                </tr>
                <tr>
                  <td>Phone 1:&nbsp;&nbsp;<label class="star">*</label></td>
                  <td><input name="phone_text" type="text" class="text100" id="phone_text" value="<?php echo $_SESSION['phone'] ?>" onKeyPress="return numbersonly(this, event)" /></td>
                  <td>Fax:</td>
                  <td><input name="fax_text" type="text" class="text100" id="fax_text" value="<?php echo $_SESSION['fax'] ?>" onKeyPress="return numbersonly(this, event)"/></td>
                </tr>
                <tr>
                  <td width="123">Contact 1:
                    &nbsp;&nbsp;
                    <label class="star">*</label></td>
                  <td width="216"><input name="contact_1_text" type="text" class="text200" id="contact_1_text" value="<?php echo $_SESSION['company_contact'] ?>" onKeyUp="ToLower(this)" onBlur="capitalize(this)"/></td>
                  <td width="92">Cell:&nbsp;&nbsp;
                    <label class="star">*</label></td>
                  <td width="179"><input name="cell_1_text" type="text" class="text100" id="cell_1_text" value="<?php echo $_SESSION['contact_phone'] ?>" onKeyPress="return numbersonly(this, event)" /></td>
                </tr>
                <tr>
                  <td>e-mail:</td>
                  <td><input name="email_1_text" type="text" class="text200" id="email_1_text" value="<?php echo $_SESSION['email_1'] ?>" onKeyUp="ToLower(this)"/></td>
                  <td>&nbsp;</td>
                  <td>&nbsp;</td>
                </tr>
              </table>
              <table width="630" align="left" id="table_display_wizard">
                <tr>
                  <td width="122" valign="top">Notes:</td>
                  <td width="488"> <textarea name="notes_text" cols="60" rows="3" class="text_box" id="notes_text"><?php echo $_SESSION['notes'] ?></textarea></td>
                </tr>
              </table>
              
            </div>
            <br />
            
            


            </td>
            <!--center of tableMain-->
          </tr>
          <tr>
            <td><!--center of tableMain-->
              <table width="590" height="50" align="left" id="table_button_bar">
                <tr>
                  <td width="117"><input type="button" name="lastprev_button2" class="imagebutton" value="Prev" onClick="needToConfirm = false;MM_showHideLayers('wait','','show');MM_goToURL('parent','orderTilesWizbase.php?s=&amp;p=2');return document.MM_returnValue" /></td>
                  <td width="115">&nbsp;</td>
                  <td width="99">
                    <input name="p" type="hidden" id="p" value="3" />
                    <input name="s" type="hidden" id="s" value="3" />
                  </td>
                  <td width="125" align="right"><input name="cancel_button" type="button" class="imagebutton" id="cancel_button" onClick="editwindow=dhtmlmodal.open('editBox', 'iframe', '../edit_windows/undo_quote.php?quote_no=<?php echo $_SESSION['quote_no'] ?>&status=cancel&p=2', 'Cancel create job', 'width=500px,height=125px,center=1,resize=0,scrolling=0')
needToConfirm = false;
editwindow.onclose=function(){return window}; return false; MM_showHideLayers('wait','','show');" value="Cancel" /></td>

                  <td width="110" align="right"><input type="submit" name="next_button" class="imagebutton" value="Next" onClick="needToConfirm = false; MM_showHideLayers('wait','','show');" /></td>
                </tr>
            </table></td>
          </tr>
        </table>
  </table>
  <!--end of tableMain-->
</form>
</div>
<!--form validation-->
  <script language="JavaScript" type="text/javascript" xml:space="preserve">
  var frmvalidator  = new Validator("feedbackform");
  frmvalidator.EnableMsgsTogether();
  frmvalidator.addValidation("comp_name_text","req","Please enter the name of the company.");
  frmvalidator.addValidation("bag_box_select","req","Please select bag or box number.");
  frmvalidator.addValidation("box_no_text","req","Please enter bag or box number.");
  frmvalidator.addValidation("post_place_select","req","Please select postal place.");
  frmvalidator.addValidation("phone_text","req","Please enter phone number.");
  frmvalidator.addValidation("contact_1_text","req","Please enter a contact.");
  frmvalidator.addValidation("cell_1_text","req","Please enter contact cell number.");
  </script>
  
  
  <?php 
  }
  ?>
</body>


