Esempio n. 1
0
$zone_string .= '<option value="-1"' . setSelected('-1', $_POST['store_zone']) . '>' . '-- Please Select --' . '</option>';
$zone_string .= '<option value="0"' . setSelected('0', $_POST['store_zone']) . '>' . '-None-' . '</option>';
while (!$zone->EOF) {
    $zone_string .= '<option value="' . $zone->fields['zone_id'] . '"' . setSelected($zone->fields['zone_id'], $_POST['store_zone']) . '>' . $zone->fields['zone_name'] . '</option>';
    $zone->MoveNext();
}
$sql = "select code, name from " . DB_PREFIX . "languages";
$store_language = $db->Execute($sql);
$language_string = '';
while (!$store_language->EOF) {
    $language_string .= '<option value="' . $store_language->fields['code'] . '"' . setSelected($store_language->fields['code'], $_POST['store_default_language']) . '>' . $store_language->fields['name'] . '</option>';
    $store_language->MoveNext();
}
$sql = "select title, code from " . DB_PREFIX . "currencies";
$currency = $db->Execute($sql) or die("error in {$sql}" . $db->ErrorMsg());
$currency_string = '';
while (!$currency->EOF) {
    $currency_string .= '<option value="' . $currency->fields['code'] . '"' . setSelected($currency->fields['code'], $_POST['store_default_currency']) . '>' . $currency->fields['title'] . '</option>';
    $currency->MoveNext();
}
$db->Close();
if (!isset($_POST['demo_install'])) {
    $_POST['demo_install'] = false;
}
setInputValue($_POST['store_name'], 'STORE_NAME_VALUE', '');
setInputValue($_POST['store_owner'], 'STORE_OWNER_VALUE', '');
setInputValue($_POST['store_owner_email'], 'STORE_OWNER_EMAIL_VALUE', '');
setInputValue($_POST['store_address'], 'STORE_ADDRESS_VALUE', STORE_ADDRESS_DEFAULT_VALUE);
setRadioChecked($_POST['demo_install'], 'DEMO_INSTALL', 'false');
// this sets the first field to email address on login - setting in /common/tpl_main_page.php
$zc_first_field = 'onload="document.getElementById(\'store_name\').focus()"';