function style($style) { $reset = '/style/reset.css'; $style = '/style/style.css'; return ' <link type="text/css" rel="stylesheet" href="' . address() . $reset . '"> <link type="text/css" rel="stylesheet" href="' . address() . $style . '"> '; }
<?php if ($_REQUEST['type'] == "followup") { followup(); } elseif ($_REQUEST['type'] == "address") { address(); } elseif ($_REQUEST['type'] == "contacts") { contacts(); } function contacts() { echo <<<EOF nitobi.loadComponent('gridcontacts'); function search(){ var grid = nitobi.getGrid("gridcontacts"); //reload grid data \tgrid.dataBind(); } //optional function to generate primary key value, ignore this function because we use autogen method function GetNewRecordID() { return 0; } //after grid html render properly, set focus on it. It is important when use choose particular cell but // immediately press search again. From screen we won't detect cell is selected infact from javascript // detect selected
function refresh($page = 'none', $dbpage = 'none', $seconds = 0) { $address = address(); switch (TRUE) { case $page != 'none' && $dbpage != 'none': return header('refresh: ' . $seconds . '; url=' . $address . $page . '?page=' . $dbpage . ''); break; case $page != 'none': return header('refresh: ' . $seconds . '; url=' . $address . $page . ''); break; case $dbpage != 'none': return header('refresh: ' . $seconds . '; url=' . $address . this_page() . '?page=' . $dbpage . ''); break; case $page == 'none': return header('refresh: ' . $seconds . '; url=' . $address . this_page() . ''); break; } }
<label class="field large-text fine-black"> <div class="align-div">Name</div><?php echo $result_LI['FirstName'] . ' ' . $result_LI['LastName']; ?> </label> <label class="field large-text fine-black"> <div class="align-div">Email</div><?php echo $result_LI['EmailAddress']; ?> </label> </div> <!-- program director info --> <div class="colm colm6"> <label class="field large-text fine-black"> <?php echo address($result_LI); ?> </label> </div> </div> <div class="frm-row"> <div class="colm colm12"><br /> <label style="width:20%" class="align-div field large-text fine-black">Order Placed By</label> <label class="field large-text fine-black"> <?php echo $result_LI['OrderPlacedByAddress']; ?> </label> </div>
function composeTweet() { $titles = file('data-titles.txt', FILE_IGNORE_NEW_LINES); $camps = file('data-camps.txt', FILE_IGNORE_NEW_LINES); $TWITTER_CHARACTER_LIMIT = 140; $markov = new Markov(); $markov->init($titles); $title = $markov->generate(4); $markov = new Markov(); $markov->init($camps); $camp = $markov->generate(4); $chain = "{$title} @ {$camp} (" . address() . ") #burningman #bot"; if (strlen($chain) >= $TWITTER_CHARACTER_LIMIT) { // try again composeTweet(); } else { return $chain; } }
header("Content-type: text/plain"); switch ($_REQUEST['action']) { case "switch": $student = $_REQUEST['student']; $value = $_REQUEST['repeat']; $response = switch_repeating($student, $value, $db); if ($response) { print $value == 1 ? "SI" : "NO"; } else { print "ko;" . $db->error(); } break; case "address": $student = $_REQUEST['student']; $value = $_REQUEST['address']; $response = address($student, $value, $db); if (!$response) { print "Errore"; } else { print "<a href='#' id='row" . $student . "_field3' onclick='change_address(this, " . $student . ")' style='font-weight: normal; color: #303030'>{$value}</a>"; } break; case "phone": $student = $_REQUEST['student']; $value = $_REQUEST['phone']; $response = phone($student, $value, $db); if (!$response) { print "Errore"; } else { print "<a href='#' id='row" . $student . "_field4' onclick='change_phone(this, " . $student . ")' style='font-weight: normal; color: #303030'>{$value}</a>"; }
function format_address($title, $address, $editurl = FALSE) { extract($address); return html_dl(dt($title) . dd(address("{$name}<br />" . nl2br($address) . "<br\n\t\t/>{$phone}")) . ($editurl ? hyperlink($editurl, "Change") : "")); }
$method = $_SERVER['REQUEST_METHOD']; $resource = isset($_REQUEST['api_data']) ? trim($_REQUEST['api_data']) : 'profile'; /* 未登录处理 */ if (empty($_SESSION['user_id'])) { api_return($resource, 'No login!'); } /* 登陆成功后处理 */ /* 根据不同的API_RESOURCE来做不同的处理 */ switch ($resource) { case 'profile': include_once 'includes/controller/user/lib_controller_profile.php'; api_return($resource, profile()); break; case 'address': include_once 'includes/controller/user/lib_controller_address.php'; api_return($resource, address()); break; case 'idcard': include_once 'includes/controller/user/lib_controller_idcard.php'; api_return($resource, idcard()); break; case 'secret': include_once 'includes/controller/user/lib_controller_secret.php'; api_return($resource, secret()); break; case 'order': //api_data=order&page=1&limit=10&type=all include_once 'includes/controller/user/lib_controller_order.php'; api_return($resource, order()); break; default:
<?php $footer .= ' <ul> <li><a href="' . address() . '/">Home</a></li> <li><a href="http://github.com/ram327/Acero-Framework/tree/master">Git it!</a></li> </ul> ';
function address_array() { $address[1] = address(); $address[1]['atyp_code'] = 'PS'; $address[2] = address(); $address[2]['atyp_code'] = 'PR'; $address[3]['atyp_code'] = 'AB'; $address[3]['line1'] = 'ASU Box ' . mt_rand(1000, 40000); $address[3]['city'] = 'Boone'; $address[3]['county'] = '095'; $address[3]['state'] = 'NC'; $address[3]['zip'] = '28608'; return $address; }
} ?> <?php if (email()) { ?> <p><strong>Email Address : </strong><?php echo email(); ?> </p> <?php } ?> <?php if (address()) { ?> <p><strong>Address : </strong><?php echo address(); ?> </p> <?php } ?> </div> <input type="hidden" class="emailaddress_admin" value="<?php echo email(); ?> " /> <div class="loader_mail" style="position: absolute;">Sending the Email. Please Wait. . .</div> <div class="Cotactform"> <div class="personal_info"> <p>