} if (!empty($_POST['thumbSize'])) { $thumbSize = $_POST['thumbSize']; if ($thumbSize < 32 || $thumbSize > 320) { $thumbSize = 96; } setcookie("thumbSize", $thumbSize, time() + 86400 * 365, "/"); } if (!empty($_POST['sortOrder'])) { $sortOrder = $_POST['sortOrder']; setcookie("sortOrder", $sortOrder, time() + 86400 * 365, "/"); } break; case 'zipSel': if (!empty($_POST['check_list'])) { $zipname = getZip($_POST['check_list']); } break; } } } } } } function getZip($files) { $zipname = MEDIA_PATH . '/cam_' . date("Ymd_His") . '.zip'; writeLog("Making zip {$zipname}"); $zipfiles = fopen($zipname . ".files", "w"); foreach ($files as $file) { $t = getFileType($file);
$form['charity_organization_id'] = array('#type' => 'hidden', '#default_value' => $charity_organization_id); $form['charity_organization_name'] = array('#title' => 'Charity Organizations Name', '#type' => 'textfield', '#maxlength' => 50, $required_disabled => 'true', '#value' => $charity_org_name, '#attributes' => array('placeholder' => t('Charity Organizations Name'), 'class' => array($input_class), 'onKeyPress' => array('return isAlphaNumeric(event, this);')), '#prefix' => '<span class="wrapper-w50">', '#suffix' => '</span>'); $form['number_501_c_3'] = array('#title' => '501 (c)(3) Number', '#type' => 'textfield', '#maxlength' => 10, $required_disabled => 'true', '#default_value' => $number_501_c_3, '#attributes' => array('placeholder' => t('Type Min 3 Chars'), 'class' => array($input_class), 'onKeyPress' => array('return isAlphaNumeric(event, this);')), '#prefix' => '<span class="wrapper-w50">', '#suffix' => '</span>'); $form['street_address'] = array('#title' => 'Street Address', '#type' => 'textfield', '#maxlength' => 100, $required_disabled => 'true', '#default_value' => $charity_org_address, '#attributes' => array('placeholder' => t('Street Address'), 'class' => array($input_class), 'onKeyPress' => array('return isAlphaNumeric(event, this);')), '#prefix' => '<span class="wrapper-w50">', '#suffix' => '</span>'); //-------------- Ajax CallBack for Cities and ZipCodes --------------------- $selected_state_id = isset($form_state['values']['state_id']) ? $form_state['values']['state_id'] : $charity_org_state; //drupal_set_message('state = '.$form_state['values']['state_id']); $form['state_id'] = array('#type' => 'select', '#title' => t('State'), '#options' => $state_options, '#default_value' => $selected_state_id, $required_disabled => 'true', '#attributes' => array('class' => array($select_class), 'autocomplete' => 'off'), '#ajax' => array('callback' => 'find_cities_callback', 'wrapper' => 'cities-wrapper'), '#prefix' => '<span class="wrapper-w16">', '#suffix' => '</span>'); $city_options = getCities($selected_state_id); if (isset($form_state['values']['city'])) { $selected_city = isset($form_state['values']['city']) ? $form_state['values']['city'] : key($city_options); } else { $selected_city = ''; } $form['city'] = array('#type' => 'select', '#title' => t('City'), $required_disabled => 'true', '#default_value' => $charity_org_city, '#options' => $city_options, '#attributes' => array('placeholder' => t(''), 'class' => array($select_class)), '#ajax' => array('callback' => 'find_zip_callback', 'wrapper' => 'zip-wrapper'), '#prefix' => '<div id="cities-wrapper"> <span class="wrapper-w16"> state = ' . $selected_state_id, '#suffix' => '</span></div>'); $zip = getZip($selected_city, $selected_state_id); $form['zip_code'] = array('#title' => 'Zip Code', '#type' => 'textfield', '#maxlength' => 25, $required_disabled => 'true', '#default_value' => $zip, '#attributes' => array('placeholder' => t('Zip Code'), 'class' => array($input_class), 'readonly' => 'readonly'), '#prefix' => '<div id="zip-wrapper"><span class="wrapper-w16">', '#suffix' => '</span></div>'); // ======================================================================== /* //-------------- Ajax CallBack for Cities and ZipCodes --------------------- if (isset($form_state['values']['state_id'])) { $selected_state_id = isset($form_state['values']['state_id']) ? $form_state['values']['state_id'] : key($state_options); }else{ $selected_state_id = ''; } $form['state_id'] = array( '#type' => 'select', '#title' => t('State'), '#options' => $state_options,
<!--CSS--> <link rel="stylesheet" type="text/css" href="css/shared.css" /> <link rel="stylesheet" href="css/lightbox.css" type="text/css" media="screen" /> <!--JavaScript--> <script src="js/prototype.js" type="text/javascript"></script> <script src="js/scriptaculous.js?load=effects,builder" type="text/javascript"></script> <script src="js/lightbox.js" type="text/javascript"></script> </head> <body> <?php include './sql/dbconnect.php'; include './sql/queries.php'; $userID = $_SESSION['myuserid']; $zipCode = getZip($userID); $result1 = getAreaCourses($zipCode); $result2 = courseActivity($userID); $result3 = friendsFeed($userID); ?> <!--Header--> <div id="banner"> <div id="navLogo"> <a href=./main.php><img src="./images/vitaal_logo.png" width="194" height="133" border="0"></a></div> <div id="bannerRightBox">LOGIN STUFF / SEARCH BOX?</div> <div id="navButtons"> <div id="button"><?php echo "<a href=./races.php?userID={$userID}>Races</a>"; ?> </div>
<?php $dir = getcwd(); list($b_cgibin, $a_cgibin) = strpos($dir, 'httpsdocs') !== false ? explode('httpsdocs', $dir) : explode('cgi-bin/', $dir); $cfg_folder = $b_cgibin; require_once $cfg_folder . "/cgi-bin/vars." . php_uname('n') . ".php"; require_once $cfg_folder . "/cgi-bin/shoppingcart2/functions.php"; switch ($_REQUEST['cmd']) { case 'zip': echo getZip(trim($_REQUEST['zip'])); break; case 'msi': echo getPriceMSI(); break; } function getPriceMSI() { global $cfg, $in, $cses, $sys; $cses['msi'] = $in['msi']; save_callsession(0); $msi = $cses['msi'] / 100 + 1; $nprecio = $cses['total_i'] * $msi + $cses['shipping_total']; //$json = array("PrecioMSI" => $nprecio); //$json = json_encode($json); return '$' . number_format($nprecio, 2); //print_r($cses); } function getZip($zip) { header('Content-Type: application/json'); connectDB();
$yearSelector = $yearSelector . "<option value='festivals_detail.php?FestivalID={$id}&archive=0' selected>{$year}</option>"; } } echo "<form style='margin-bottom:0;' name='form1'>"; echo "Select a year: "; echo "<select name='switch_year' onChange=\"MM_jumpMenu('parent',this,0)\" class='form_input'>"; echo "{$yearSelector}"; echo "</select></form>"; } echo "</td></tr></table><p></p>"; include './scores_indiv.inc2.php'; echo "<table border=0><tr><td valign='top' width='315'>"; echo "<h2>Contact Information:</h2>"; echo $contact . "<br>"; echo "<a href=\"" . $website . "\" target='_blank'>Festival Website</a><p>"; $zipcode = getZip($address); //if (($phpDate+86400) >= strtotime("now") && strtotime("now") >= ($phpDate-604800)) { echo "<h2>Weather:</h2>"; ?> <div id="wx_module_3967"> <a href="http://www.weather.com/weather/local/<?php echo $zipcode; ?> ">Weather Forecast for <?php echo $zipcode; ?> </a> </div> <?php //} echo "</td><td valign='top'>";