当前位置: 首页>>代码示例>>PHP>>正文


PHP get_age函数代码示例

本文整理汇总了PHP中get_age函数的典型用法代码示例。如果您正苦于以下问题:PHP get_age函数的具体用法?PHP get_age怎么用?PHP get_age使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了get_age函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: put_info_for_person

function put_info_for_person($person)
{
    ?>
		<div class="Person_content">
			<div class="Person_Category_Container">
				<?php 
    if (NULL != ($aliases = get_string_of_aliases($person['personid']))) {
        put_Separating("circular138.png", $aliases);
    }
    if ($person['birthday']) {
        put_Separating("birthday20.png", "" . date("d-m-Y", strtotime($person['birthday'])) . " (" . get_age($person['birthday']) . " χρονών)");
    }
    if (NULL != $person['imageBase64']) {
        //put_Separating( "camera44.png" , $person['photopath'] );
        ?>
					<div class="photo" style="background-image: url('<?php 
        echo "data:image;base64," . $person['imageBase64'];
        ?>
');"></div>
				<?php 
    }
    ?>
			</div>
		</div> 
	<?php 
}
开发者ID:kwstarikanos,项目名称:Contacts,代码行数:26,代码来源:person.php

示例2: getContent

    public function getContent()
    {
        global $sql;
        // $kio->disableRegion('left');
        if (u1 || LOGGED) {
            // TODO: Zamiast zapytania dla własnego konta dać User::toArray()
            $profile = $sql->query('
				SELECT u.*
				FROM ' . DB_PREFIX . 'users u
				WHERE u.id = ' . (ctype_digit(u1) ? u1 : UID))->fetch();
        }
        if ($profile) {
            Kio::addTitle(t('Users'));
            Kio::addBreadcrumb(t('Users'), 'users');
            Kio::addTitle($profile['nickname']);
            Kio::addBreadcrumb($profile['nickname'], 'profile/' . u1 . '/' . clean_url($profile['nickname']));
            Kio::setDescription(t('%nickname&apos;s profile', array('%nickname' => $profile['nickname'])) . ($profile['title'] ? ' - ' . $profile['title'] : ''));
            Kio::addTabs(array(t('Edit profile') => 'edit_profile/' . u1));
            if ($profile['birthdate']) {
                $profile['bd'] = $profile['birthdate'] ? explode('-', $profile['birthdate']) : '';
                // DD Month YYYY (Remaining days to next birthday)
                $profile['birthdate'] = $profile['bd'][2] . ' ' . Kio::$months[$profile['bd'][1]] . ' ' . $profile['bd'][0] . ' (' . day_diff(mktime(0, 0, 0, $profile['bd'][1], $profile['bd'][2] + 1, date('y')), t('%d days remaining')) . ')';
                $profile['age'] = get_age($profile['bd'][2], $profile['bd'][1], $profile['bd'][0]);
                if (Plugin::exists('zodiac')) {
                    require_once ROOT . 'plugins/zodiac/zodiac.plugin.php';
                    $profile['zodiac'] = Zodiac::get($profile['bd'][2], $profile['bd'][1]);
                }
            }
            if ($profile['http_agent'] && Plugin::exists('user_agent')) {
                require_once ROOT . 'plugins/user_agent/user_agent.plugin.php';
                $profile['os'] = User_Agent::getOS($profile['http_agent']);
                $profile['browser'] = User_Agent::getBrowser($profile['http_agent']);
            }
            $group = Kio::getGroup($profile['group_id']);
            $profile['group'] = $group['name'] ? $group['inline'] ? sprintf($group['inline'], $group['name']) : $group['name'] : '';
            if ($profile['gender']) {
                $profile['gender'] = $profile['gender'] == 1 ? t('Male') : t('Female');
            }
            try {
                // TODO: Zrobić modyfikator dla funkcji o wielu parametrach (teraz jest tylko jeden możliwy)
                $tpl = new PHPTAL('modules/profile/profile.tpl.html');
                $tpl->profile = $profile;
                return $tpl->execute();
            } catch (Exception $e) {
                return template_error($e);
            }
        } else {
            return not_found(t('Selected user doesn&apos;t exists.'), array(t('This person was deleted from database.'), t('Entered URL is invalid.')));
        }
    }
开发者ID:rafalenden,项目名称:KioCMS,代码行数:50,代码来源:profile.module.php

示例3: add_student

function add_student($db, $argv)
{
    if (sizeof($argv) == 3) {
        $login = $argv[2];
        if (preg_match("/^[a-zA-Z]{2,6}_[a-zA-Z0-9]\$/", $login) == 1) {
            $collection = $db->createCollection("students");
            $document = array("login" => $login, "name" => get_name(), "age" => intval(get_age()), "email" => get_email(), "phone" => get_number(), "rented_movies" => array());
            $collection->insert($document);
            echo "[32mUser registered ![0m\n";
        } else {
            echo "[31mError: Login invalide.\n[0m";
        }
    } else {
        echo "[31mInvalid arg number!\nUsage: ./etna_movies.php login.[0m\n";
    }
}
开发者ID:amira-s,项目名称:etna-projects,代码行数:16,代码来源:students.php

示例4: get_user_info_func

function get_user_info_func($xmlrpc_params)
{
    global $db, $lang, $theme, $plugins, $mybb, $session, $settings, $cache, $time, $mybbgroups, $parser, $displaygroupfields;
    $lang->load("member");
    $input = Tapatalk_Input::filterXmlInput(array('user_name' => Tapatalk_Input::STRING, 'user_id' => Tapatalk_Input::INT), $xmlrpc_params);
    if ($mybb->usergroup['canviewprofiles'] == 0) {
        error_no_permission();
    }
    if (isset($input['user_id']) && !empty($input['user_id'])) {
        $uid = $input['user_id'];
    } elseif (!empty($input['user_name'])) {
        $query = $db->simple_select("users", "uid", "username='{$input['user_name_esc']}'");
        $uid = $db->fetch_field($query, "uid");
    } else {
        $uid = $mybb->user['uid'];
    }
    if ($mybb->user['uid'] != $uid) {
        $memprofile = get_user($uid);
    } else {
        $memprofile = $mybb->user;
    }
    if (!$memprofile['uid']) {
        error($lang->error_nomember);
    }
    // Get member's permissions
    $memperms = user_permissions($memprofile['uid']);
    if (!$memprofile['displaygroup']) {
        $memprofile['displaygroup'] = $memprofile['usergroup'];
    }
    // Grab the following fields from the user's displaygroup
    $displaygroupfields = array("title", "usertitle", "stars", "starimage", "image", "usereputationsystem");
    $displaygroup = usergroup_displaygroup($memprofile['displaygroup']);
    // Get the user title for this user
    unset($usertitle);
    unset($stars);
    if (trim($memprofile['usertitle']) != '') {
        // User has custom user title
        $usertitle = $memprofile['usertitle'];
    } elseif (trim($displaygroup['usertitle']) != '') {
        // User has group title
        $usertitle = $displaygroup['usertitle'];
    } else {
        // No usergroup title so get a default one
        $query = $db->simple_select("usertitles", "*", "", array('order_by' => 'posts', 'order_dir' => 'DESC'));
        while ($title = $db->fetch_array($query)) {
            if ($memprofile['postnum'] >= $title['posts']) {
                $usertitle = $title['title'];
                $stars = $title['stars'];
                $starimage = $title['starimage'];
                break;
            }
        }
    }
    // User is currently online and this user has permissions to view the user on the WOL
    $timesearch = TIME_NOW - $mybb->settings['wolcutoffmins'] * 60;
    $query = $db->simple_select("sessions", "location,nopermission", "uid='{$uid}' AND time>'{$timesearch}'", array('order_by' => 'time', 'order_dir' => 'DESC', 'limit' => 1));
    $session = $db->fetch_array($query);
    if (($memprofile['invisible'] != 1 || $mybb->usergroup['canviewwolinvis'] == 1 || $memprofile['uid'] == $mybb->user['uid']) && !empty($session)) {
        // Fetch their current location
        $lang->load("online");
        require_once MYBB_ROOT . "inc/functions_online.php";
        $activity = fetch_wol_activity($session['location'], $session['nopermission']);
        /*unset($activity['tid']);
          unset($activity['fid']);
          unset($activity['pid']);
          unset($activity['eid']);
          unset($activity['aid']);*/
        $location = strip_tags(build_friendly_wol_location($activity));
        $location_time = my_date($mybb->settings['timeformat'], $memprofile['lastactive']);
        $online = true;
    } else {
        $online = false;
    }
    // Get custom fields start
    $custom_fields_list = array();
    if ($memprofile['birthday']) {
        $membday = explode("-", $memprofile['birthday']);
        if ($memprofile['birthdayprivacy'] != 'none') {
            if ($membday[0] && $membday[1] && $membday[2]) {
                $lang->membdayage = $lang->sprintf($lang->membdayage, get_age($memprofile['birthday']));
                if ($membday[2] >= 1970) {
                    $w_day = date("l", mktime(0, 0, 0, $membday[1], $membday[0], $membday[2]));
                    $membday = format_bdays($mybb->settings['dateformat'], $membday[1], $membday[0], $membday[2], $w_day);
                } else {
                    $bdayformat = fix_mktime($mybb->settings['dateformat'], $membday[2]);
                    $membday = mktime(0, 0, 0, $membday[1], $membday[0], $membday[2]);
                    $membday = date($bdayformat, $membday);
                }
                $membdayage = $lang->membdayage;
            } elseif ($membday[2]) {
                $membday = mktime(0, 0, 0, 1, 1, $membday[2]);
                $membday = date("Y", $membday);
                $membdayage = '';
            } else {
                $membday = mktime(0, 0, 0, $membday[1], $membday[0], 0);
                $membday = date("F j", $membday);
                $membdayage = '';
            }
        }
        if ($memprofile['birthdayprivacy'] == 'age') {
//.........这里部分代码省略.........
开发者ID:dthiago,项目名称:tapatalk-mybb,代码行数:101,代码来源:get_user_info.php

示例5: gmdate

 $memlocaltime = gmdate($mybb->settings['timeformat'], TIME_NOW + $memprofile['timezone'] * 3600);
 $localtime = $lang->sprintf($lang->local_time_format, $memlocaldate, $memlocaltime);
 if ($memprofile['lastactive']) {
     $memlastvisitdate = my_date($mybb->settings['dateformat'], $memprofile['lastactive']);
     $memlastvisitsep = $lang->comma;
     $memlastvisittime = my_date($mybb->settings['timeformat'], $memprofile['lastactive']);
 } else {
     $memlastvisitdate = $lang->lastvisit_never;
     $memlastvisitsep = '';
     $memlastvisittime = '';
 }
 if ($memprofile['birthday']) {
     $membday = explode("-", $memprofile['birthday']);
     if ($memprofile['birthdayprivacy'] != 'none') {
         if ($membday[0] && $membday[1] && $membday[2]) {
             $lang->membdayage = $lang->sprintf($lang->membdayage, get_age($memprofile['birthday']));
             if ($membday[2] >= 1970) {
                 $w_day = date("l", mktime(0, 0, 0, $membday[1], $membday[0], $membday[2]));
                 $membday = format_bdays($mybb->settings['dateformat'], $membday[1], $membday[0], $membday[2], $w_day);
             } else {
                 $bdayformat = fix_mktime($mybb->settings['dateformat'], $membday[2]);
                 $membday = mktime(0, 0, 0, $membday[1], $membday[0], $membday[2]);
                 $membday = date($bdayformat, $membday);
             }
             $membdayage = $lang->membdayage;
         } elseif ($membday[2]) {
             $membday = mktime(0, 0, 0, 1, 1, $membday[2]);
             $membday = date("Y", $membday);
             $membdayage = '';
         } else {
             $membday = mktime(0, 0, 0, $membday[1], $membday[0], 0);
开发者ID:nicopinto,项目名称:fantasitura.com,代码行数:31,代码来源:member.php

示例6: date_default_timezone_set

 date_default_timezone_set("America/Los_Angeles");
 $user = strip_tags(trim(mysql_prep($_POST['username'])));
 $email = strip_tags(trim(mysql_prep($_POST['email'])));
 $mcuser = strip_tags(trim(mysql_prep($_POST['mcuser'])));
 $validmcuser = false;
 /*$ch = curl_init();
 	curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
 	curl_setopt($ch, CURLOPT_URL, "http://www.minecraft.net/haspaid.jsp?user=".$mcuser);
 	$check = curl_exec($ch);
 	curl_close($ch);*/
 $phone = strip_tags(trim(mysql_prep($_POST['phone'])));
 $location = strip_tags(trim(mysql_prep($_POST['location'])));
 $gender = strip_tags(trim(mysql_prep($_POST['gender'])));
 $dob = $_POST['year'] . "-" . $_POST['month'] . "-" . $_POST['day'];
 $datejoined = date("Y/m/d H:i:s");
 $age = get_age($dob);
 $pass = $_POST['pass'];
 $confirmpass = $_POST['confirmpass'];
 $hashed_pass = sha1($pass);
 $verifcode = randstring();
 if (checkdate(intval($_POST['month']), intval($_POST['day']), intval($_POST['year']))) {
     if ($pass == $confirmpass) {
         if (!empty($user) && !empty($email) && !empty($pass) && !empty($mcuser) && $user != " " && $email != " " && $pass != " " && $mcuser != " ") {
             if ($age >= 13) {
                 if (checkstr($user) == false) {
                     if (filter_var($email, FILTER_VALIDATE_EMAIL)) {
                         if ($mcuser != "") {
                             $query = "SELECT id, username, email, minecraft_username FROM users\n\t\t\t\t\t\t\t\t\t\tWHERE username='{$user}' OR email='{$email}' OR minecraft_username='{$mcuser}'";
                         } else {
                             $query = "SELECT id, username, email, minecraft_username FROM users\n\t\t\t\t\t\t\t\t\t\tWHERE username='{$user}' OR email='{$email}'";
                         }
开发者ID:johnsondelbert1,项目名称:prj-illuminate,代码行数:31,代码来源:register.php

示例7: activity_export

 /**
  * 活动信息导出
  */
 public function activity_export()
 {
     $user_activity = M('user_activity');
     import('@.ORG.Page');
     $arr = "";
     $true_name = trim($this->_get('true_name'));
     #宝宝名称
     if (!empty($true_name)) {
         $arr['cms_user.true_name'] = array('LIKE', "%" . $true_name . "%");
         $this->assign("true_name", $this->_get('true_name'));
     }
     $region_id = intval($this->_get('region_id'));
     #城市
     if ($region_id > 0) {
         $region_list = $user_activity->query("SELECT id FROM `cms_region` where pid={$region_id} and status=1");
         foreach ($region_list as $rlist) {
             $arr_c1[] = $rlist['id'];
         }
         $str_c1 = implode(',', $arr_c1);
         $region_list = $user_activity->query("SELECT id FROM `cms_region` where pid in({$str_c1}) and status=1");
         foreach ($region_list as $rlist2) {
             $arr_c1[] = $rlist2['id'];
         }
         $str_c2 = implode(',', $arr_c1);
         $arr['cms_user.region_id'] = array('in', $str_c2);
         $this->assign("region_id", $this->_get('region_id'));
     }
     $admin_id = intval($this->_get('admin_id'));
     #所属客服
     if ($admin_id > 0) {
         $arr['cms_user.admin_id'] = array('eq', $admin_id);
         $this->assign("admin_id", $this->_get('admin_id'));
     }
     $pre_status = intval($this->_get('pre_status'));
     #预约状态
     if ($pre_status != 3) {
         $arr['cms_user_activity.pre_status'] = array('eq', $pre_status);
         $this->assign("pre_status", $this->_get('pre_status'));
     } else {
         $this->assign("pre_status", 3);
     }
     $to_status = intval($this->_get('to_status'));
     #到店状态
     if ($to_status != 3) {
         $arr['cms_user_activity.to_status'] = array('eq', $to_status);
         $this->assign("to_status", $this->_get('to_status'));
     } else {
         $this->assign("to_status", 3);
     }
     $source_id = intval($this->_get('source_id'));
     #到店状态
     if ($source_id != 100) {
         $arr['cms_user.source_id'] = array('eq', $source_id);
         $this->assign("source_id", $this->_get('source_id'));
     } else {
         $this->assign("source_id", 100);
     }
     //$arr['cms_user.status']=array('eq',1);
     $arr['cms_user_activity.type'] = array('eq', 2);
     $user_arr = $user_activity->field('cms_user_activity.*,cms_user.sex,cms_user.birthday,cms_user.phone,cms_user.true_name')->join('LEFT JOIN cms_user ON cms_user.user_id=cms_user_activity.user_id')->order('cms_user_activity.create_time DESC')->select();
     vendor('PHPExcel_1_7_8.Classes.PHPExcel');
     vendor('PHPExcel_1_7_8.Classes.PHPExcel.IOFactory');
     vendor('PHPExcel_1_7_8.Classes.PHPExcel.Worksheet');
     //创建Excel对象
     $objPHPExcel = new PHPExcel();
     //设置Excel数据缓存方式为磁盘文件缓存(适用于大数据量处理,以减少对PHP自身内存的占用)
     $cacheMethod = PHPExcel_CachedObjectStorageFactory::cache_to_discISAM;
     $cacheSettings = array('dir' => C('LEG_EXCEL_DATA_CACHE_DIR'));
     PHPExcel_Settings::setCacheStorageMethod($cacheMethod, $cacheSettings);
     //设置Excel元数据
     $objPHPExcel->getProperties()->setCreator("客服管理系统");
     $objPHPExcel->getProperties()->setLastModifiedBy("客服管理系统后台程序");
     $objPHPExcel->getProperties()->setTitle("客服管理系统后台导出客服活动列表");
     $objPHPExcel->getProperties()->setSubject("客服活动列表");
     $objPHPExcel->getProperties()->setDescription("Exported document for Office 2007 XLSX, generated using PHP classes.");
     $objPHPExcel->getProperties()->setKeywords("office 2007 php");
     $objPHPExcel->getProperties()->setCategory("Export result file");
     //填充数据到活动的电子表格中
     $objPHPExcel->setActiveSheetIndex(0);
     $objWorksheet = $objPHPExcel->getActiveSheet();
     $objWorksheet->setCellValueByColumnAndRow(0, 1, 'ID');
     $objWorksheet->setCellValueByColumnAndRow(1, 1, '宝宝名称');
     $objWorksheet->setCellValueByColumnAndRow(2, 1, '性别');
     $objWorksheet->setCellValueByColumnAndRow(3, 1, '宝宝年龄');
     $objWorksheet->setCellValueByColumnAndRow(4, 1, '课程名称');
     $objWorksheet->setCellValueByColumnAndRow(5, 1, '预约时间');
     $objWorksheet->setCellValueByColumnAndRow(6, 1, '电话号码');
     $objWorksheet->setCellValueByColumnAndRow(7, 1, '预约状态');
     $objWorksheet->setCellValueByColumnAndRow(8, 1, '到店状态');
     foreach ($user_arr as $key => $rs) {
         $key += 2;
         $objWorksheet->setCellValueByColumnAndRow(0, $key, $rs['id']);
         $objWorksheet->setCellValueByColumnAndRow(1, $key, $rs['true_name']);
         $objWorksheet->setCellValueByColumnAndRow(2, $key, $rs['sex'] == 1 ? '女' : '男');
         $objWorksheet->setCellValueByColumnAndRow(3, $key, get_age($rs['birthday']));
         $objWorksheet->setCellValueByColumnAndRow(4, $key, $rs['course']);
         $objWorksheet->setCellValueByColumnAndRow(5, $key, date("Y-m-d H:i:s", $rs['create_time']));
//.........这里部分代码省略.........
开发者ID:lz1988,项目名称:lejing,代码行数:101,代码来源:ActivityAction.class.php

示例8: string

<h2>date_range_string(<var>date1</var>, <var>date2</var>)</h2>
<p>Creates a date range string (e.g. January 1-10, 2010).</p>

<pre class="brush: php">
date_range_string('2010-08-01', '2010-08-05');
// returns <?php 
echo date_range_string(time() - 24 * 60 * 60, time());
?>
</pre>


<h2>pretty_date(<var>timestamp</var>, <var>use_gmt</var>)</h2>
<p>Creates a string based on how long from the current time the date provided.</p>

<pre class="brush: php">
pretty_date(time() - (60 * 60));
// returns <?php 
echo pretty_date(time() - 60 * 60);
?>
</pre>


<h2>get_age(<var>bday_ts</var>, <var>[at_time_ts]</var>)</h2>
<p>Returns an age based on a given date/timestamp. The second parameter is optional and by default will be the current date.</p>

<pre class="brush: php">
get_age('2000-01-01');
// returns <?php 
echo get_age('2000-01-01');
?>
</pre>
开发者ID:kieranklaassen,项目名称:FUEL-CMS,代码行数:31,代码来源:my_date_helper.php

示例9: CVD

    <p>
    Mi nombre es <? echo $result["name"];?>, vivo en <? echo $result["city"];?>, <? echo $result["country"];?>, soy deportista de <? echo $result["sport"];?> y quiero tener la posibilidad de realizar una prueba en su Instituci&oacute;n.
    </p>
    <p>
        Le hago llegar mi CVD (Curr&iacute;culum Vitae Deportivo) para que UD. pueda analizarlo y darme la oportunidad de poder 				ofrecer mis habilidades. 
    </p>
<!-- Fin Presentación-->
<!--Datos Personales -->
    <p>
        Mis Datos Personales son:
    </p>
    <p>
        Apellido/s y Nombre/s: <? echo $result["name"];?> <br />
        Pa&iacute;s, Ciudad: <? echo $result["country"];?>, <? echo $result["city"];?> (bandera del pais)<br />
        Edad: <?php 
echo get_age($result["birth"]);
?>
<br />
        <!--Peso: <input type="text" class="inputbox" name="txt_peso" onkeypress="ValidKey(event,'number','unsigned')" value=""/> <br />
        Altura: <input type="text" class="validator {v_required:true} inputbox" name="" onkeypress="ValidKey(event,'number','unsigned')" value=""/><br />-->
        Deporte: <? echo $result["sport"];?><br /> 
        <?php 
if (!empty($result["position"])) {
    ?>
Posici&oacute;n:<?php 
    echo utf8_encode($result["position"]);
    ?>
<br><?php 
}
?>
        Pasaporte: <? echo $result["passport"];?><br />
开发者ID:jsuarez,项目名称:Lexer,代码行数:31,代码来源:recomendarme_sport_club.php

示例10: foreach

$count = 0;
// plot the data points
foreach ($datapoints as $data) {
    list($date, $height, $weight, $head_circ) = explode('-', $data);
    if ($date == "") {
        continue;
    }
    // only plot if we have both weight and heights. Skip if either is 0.
    // Rational is only well visit will need both, sick visit only needs weight
    // for some clinic.
    if ($weight == 0 || $height == 0) {
        continue;
    }
    // get age of patient at this data-point
    // to get data from function get_age including $age, $ageinYMD
    extract(get_age($dob, $date));
    // exclude data points that do not belong on this chart
    // for example, a data point for a 18 month old can be excluded
    // from that patient's 2-20 yr chart
    $daysold = getPatientAgeInDays($dob, $date);
    if ($daysold > 365 * 2 && $charttype == "birth") {
        continue;
    }
    if ($daysold < 365 * 2 && $charttype == "2-20") {
        continue;
    }
    // calculate the x-axis (Age) value
    $x = $dot_x + $delta_x * ($age - $ageOffset);
    // Draw Height dot
    $y1 = $dot_y1 - $delta_y1 * ($height - $heightOffset);
    imagefilledellipse($im, $x, $y1, 10, 10, $color);
开发者ID:nickolasnikolic,项目名称:openemr,代码行数:31,代码来源:chart.php

示例11: header

<?php

include "../../configure.php";
include "../../connection/connection.php";
header('Content-type: text/html; charset=utf-8');
include "../../php/functions.php";
session_start();
$result = $data->get_result("SELECT Concat(`users_representatives`.`lastname`, ' ',\r\n\t\t\t\t\t\t\t\t\t\t  `users_representatives`.`firstname`) AS `name`,\r\n\t\t\t\t\t\t\t\t\t\t users_representatives.city,\r\n\t\t\t\t\t\t\t\t\t\t users_representatives.birth,\r\n\t\t\t\t\t\t\t\t\t\t users_representatives.nacionality,\r\n\t\t\t\t\t\t\t\t\t\t Concat('(',`users_representatives`.`phone_pref1`, ')',\r\n\t\t\t\t\t\t\t\t\t\t '(',`users_representatives`.`phone_pref2`, ')',\r\n\t\t\t\t\t\t\t\t\t\t  `users_representatives`.`phone`) AS `phone`,\r\n\t\t\t\t\t\t\t\t\t\t  Concat('(',`users_representatives`.`cel_pref1`, ')',\r\n\t\t\t\t\t\t\t\t\t\t '(',`users_representatives`.`cel_pref2`, ')',\r\n\t\t\t\t\t\t\t\t\t\t  `users_representatives`.`cel`) AS `cel`,\r\n\t\t\t\t\t\t\t\t\t\t  users_representatives.website,\r\n\t\t\t\t\t\t\t\t\t\t  users_representatives.work,\r\n\t\t\t\t\t\t\t\t\t (SELECT name FROM list_country WHERE codcountry=country) AS country\r\n\t\t\t\t\t\t\t\tFROM users_representatives\r\n\t\t\t\t\t\t\t\tWHERE coduser=" . $_SESSION["coduser"]);
$edad = get_age($result["birth"]);
?>
<div>
<!-- Asunto-->
    <p>
    	Asunto: <input name="txt_name" type="hidden" value="<? echo $result["name"];?>" /> <? echo $result["name"];?> te quiere contactar un Representante de lexersports.com!!!
    </p>
<!-- Fin Asunto-->
<!-- Saludo-->
    <p>
    	Hola 
        	<? $rst = $data->query("SELECT
									  `users`.`email`, Concat(`users_sports`.`lastname`, ' ',
									  `users_sports`.`firstname`) AS `name`
									FROM
									  `users` INNER JOIN
									  `users_sports` ON `users`.`coduser` = `users_sports`.`coduser`
									ORDER BY name");?>
            <select id="cbo_to" name="cbo_to">
            <option value="0">Seleccione un Deportista</option>
            <? while( $row=mysql_fetch_array($rst) ){?>
                <option value="<? echo $row["email"];?>"><? echo utf8_encode($row["name"]);?></option>
            <? }?>
开发者ID:jsuarez,项目名称:Lexer,代码行数:31,代码来源:recomendarme_repr_sport.php

示例12: get_age

            <h1>User Profile</h1>
        </div>	
		<div class="container col-md-9 pull-left">
			<div class="[ col-sm-6 col-md-offset-2 col-md-4 ]">
				<div class="[ info-card ]">
					<img style="width: 80%" height= "500px" src="./img/placeholder.jpg" />
					<div class="[ info-card-details ] animate">
						<div class="[ info-card-header ]">
							<h1> <?php 
echo $row_name['forename'];
?>
 <?php 
echo $row_name['surname'];
?>
 : <?php 
echo "" . get_age($row_name['dob']) . "";
?>
</h1>
							<h3> <?php 
echo $row_name['location'];
?>
 </h3>
						</div>
						<div class="[ info-card-detail ]">
							<!-- Description -->
							<p>My Qualifications go here please</p>
							<br></br>
							<table>
<tr>
	<td>
		<div name="textNo" value="1">1</div>
开发者ID:CFGLondon,项目名称:team-5,代码行数:31,代码来源:userprofile.php

示例13: ajaxGetUserInfo

 public function ajaxGetUserInfo()
 {
     $user = M('user');
     $word = $_REQUEST['q'];
     $map['status'] = array('eq', 1);
     $map['is_del'] = array('eq', 0);
     $map['true_name'] = array('like', '%' . $word . '%');
     $userList = $user->field('user_id,sex,birthday,phone,true_name')->where($map)->limit(0, 9)->select();
     foreach ($userList as $key => $value) {
         $userList[$key]['birthday'] = get_age($value['birthday']);
         if ($value['sex']) {
             $userList[$key]['sex'] = "女";
         } else {
             $userList[$key]['sex'] = "男";
         }
     }
     echo json_encode($userList);
 }
开发者ID:lz1988,项目名称:lejing,代码行数:18,代码来源:CommonAction.class.php

示例14: strip_tags

//--------------------
for ($i = 0; $i < count($record); $i++) {
    ?>
		<tr class=tr3 id=<?php 
    echo $record[$i]->id;
    ?>
 >
			<td style="text-align:left; text-indent:12px;"><a href="<?php 
    echo "/assistant/assistant.php?id={$record[$i]->id}";
    ?>
" target="_blank"><?php 
    echo strip_tags($record[$i]->title);
    ?>
</a></td>
			<td><?php 
    get_age($record[$i]->age);
    ?>
</td>
			<td><a href="?category=<?php 
    echo $record[$i]->category_id;
    ?>
" style="color:#0000FF"><?php 
    echo $category->find($record[$i]->category_id)->name;
    ?>
</a></td>
			<td><?php 
    echo $record[$i]->created_at;
    ?>
</td>
			<td>
					<a href="edit.php?id=<?php 
开发者ID:justin1986,项目名称:eachbb,代码行数:31,代码来源:index.php

示例15: implode

         }
         $player_details[$player->ID][$stat] = implode(', ', $player_teams);
     }
     break;
 case 'season':
     $seasons = get_the_terms($player->ID, 'wpcm_season');
     if (is_array($seasons)) {
         $player_seasons = array();
         foreach ($seasons as $season) {
             $player_seasons[] = $season->name;
         }
         $player_details[$player->ID][$stat] = implode(', ', $player_seasons);
     }
     break;
 case 'age':
     $player_details[$player->ID][$stat] = 'Varsta: ' . get_age(get_post_meta($player->ID, 'wpcm_dob', true));
     break;
 case 'dob':
     $player_details[$player->ID][$stat] = date_i18n(get_option('date_format'), strtotime(get_post_meta($player->ID, 'wpcm_dob', true)));
     break;
 case 'height':
     $player_details[$player->ID][$stat] = $height;
     break;
 case 'weight':
     $player_details[$player->ID][$stat] = $weight;
     break;
 case 'hometown':
     $player_details[$player->ID][$stat] = '<img class="flag" src="' . WPCM_URL . 'assets/images/flags/' . $natl . '.png" /> ' . $hometown;
     break;
 case 'joined':
     $player_details[$player->ID][$stat] = date_i18n(get_option('date_format'), strtotime($player->post_date));
开发者ID:salageansergiumarco,项目名称:academiadefotbalnapoca.ro,代码行数:31,代码来源:players.php


注:本文中的get_age函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。