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


PHP country::GetCountryName方法代码示例

本文整理汇总了PHP中country::GetCountryName方法的典型用法代码示例。如果您正苦于以下问题:PHP country::GetCountryName方法的具体用法?PHP country::GetCountryName怎么用?PHP country::GetCountryName使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在country的用法示例。


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

示例1: completeData

 public function completeData($type_role = 1)
 {
     if ($this->isDisable()) {
         header("Location: /wizard/registration/?step=1");
         exit;
     }
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/employer.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/freelancer.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/city.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/country.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/blogs.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/commune.php";
     $themes_blogs = blogs::getRandomThemes(5);
     $themes_commune = commune::getRandomCommunes(3);
     $month = array('1' => 'января', '2' => 'февраля', '3' => 'марта', '4' => 'апреля', '5' => 'мая', '6' => 'июня', '7' => 'июля', '8' => 'августа', '9' => 'сентября', '10' => 'октября', '11' => 'ноября', '12' => 'декабря');
     if ($type_role == step_wizard_registration::TYPE_WIZARD_EMP) {
         $user = new employer();
         $checkPRO = $this->checkWizardPRO(array(step_employer::OP_CODE_PRO));
         $pro_emp = $checkPRO['id'] > 0 ? 1 : 0;
         if ($pro_emp) {
             $week_pro = round($checkPRO['ammount'] / 10);
         }
     } else {
         $user = new freelancer();
         $checkPRO = $this->checkWizardPRO(step_freelancer::getOperationCodePRO());
         $pro_frl = $checkPRO['id'] > 0 ? 1 : 0;
         if ($pro_frl) {
             $op_code = $checkPRO['op_code'];
         }
     }
     $user->GetUserByUID(wizard::getUserIDReg());
     $info_for_reg = unserialize($user->info_for_reg);
     $uname = $user->uname;
     $usurname = $user->usurname;
     $sex = $user->sex == 't' ? 1 : ($user->sex == 'f' ? 0 : -1);
     $birthday = strtotime($user->birthday);
     if ($birthday) {
         $bday = date('d', $birthday);
         $bmonth = (int) date('m', $birthday);
         $bmonth_value = $month[$bmonth];
         $byear = date('Y', $birthday);
     } else {
         $bday = '';
         $bmonth = (int) date('m', $birthday);
         $bmonth_value = $month[$bmonth];
         $byear = '';
     }
     $city = $user->city;
     if ($city) {
         $city_value = city::GetCityName($city);
     }
     $country = $user->country;
     if ($country) {
         $country_value = country::GetCountryName($country);
     }
     if ($type_role == step_wizard_registration::TYPE_WIZARD_EMP) {
         $company = $user->compname;
         $about_company = $user->company;
         $logo_name = $user->logo;
         $dir = "users/" . substr($user->login, 0, 2) . "/" . $user->login . "/logo/";
         $logo_path = WDCPREFIX . "/" . $dir . $user->logo;
     }
     $info['site'] = $this->loadMultiVal('site', 'site', $user);
     $info['email'] = $this->loadMultiVal('second_email', 'email', $user);
     $info['phone'] = $this->loadMultiVal('phone', 'phone', $user);
     $info['icq'] = $this->loadMultiVal('icq', 'icq', $user);
     $info['skype'] = $this->loadMultiVal('skype', 'skype', $user);
     $info['jabber'] = $this->loadMultiVal('jabber', 'jabber', $user);
     $info['lj'] = $this->loadMultiVal('ljuser', 'lj', $user);
     $action = __paramInit('string', null, 'action');
     if ($action == 'upd_info') {
         $info_for_reg = $_POST['info_for_reg'];
         if ($info_for_reg['email_0'] !== null) {
             $info_for_reg['second_email'] = $info_for_reg['email_0'];
             unset($info_for_reg['email_0']);
         }
         if ($info_for_reg['phone_0'] !== null) {
             $info_for_reg['phone'] = $info_for_reg['phone_0'];
             unset($info_for_reg['phone_0']);
         }
         if ($info_for_reg['site_0'] !== null) {
             $info_for_reg['site'] = $info_for_reg['site_0'];
             unset($info_for_reg['site_0']);
         }
         if ($info_for_reg['lj_0'] !== null) {
             $info_for_reg['ljuser'] = $info_for_reg['lj_0'];
             unset($info_for_reg['lj_0']);
         }
         if ($info_for_reg['jabber_0'] !== null) {
             $info_for_reg['jabber'] = $info_for_reg['jabber_0'];
             unset($info_for_reg['jabber_0']);
         }
         if ($info_for_reg['skype_0'] !== null) {
             $info_for_reg['skype'] = $info_for_reg['skype_0'];
             unset($info_for_reg['skype_0']);
         }
         if ($info_for_reg['icq_0'] !== null) {
             $info_for_reg['icq'] = $info_for_reg['icq_0'];
             unset($info_for_reg['icq_0']);
         }
//.........这里部分代码省略.........
开发者ID:Nikitian,项目名称:fl-ru-damp,代码行数:101,代码来源:step_wizard_registration.php

示例2: elseif

if (!($info_for_reg['country'] && !$uid) && $user->country) {
    ?>
    <div class="b-layout__hover_bg_f0ffdf b-layout_padlr_10  b-layout_pad_3">
       <div class="b-layout__txt b-layout__txt_padleft_35 b-layout__txt_lineheight_1 b-layout__txt_padtop_1">
            <span class="b-icon b-icon__cont b-icon__cont_map b-icon_margleft_-35"></span>
            <?php 
    if ($info_for_reg['country'] && !$uid) {
        ?>
                <?php 
        echo $reg_string;
        ?>
            <?php 
    } elseif ($user->country) {
        ?>
                <?php 
        echo country::GetCountryName($user->country);
        if ($user->city && !($info_for_reg['city'] && !$uid)) {
            ?>
, <?php 
            echo city::GetCityName($user->city);
        }
        ?>
            <?php 
    }
    ?>
       </div>
    </div>
<?php 
}
?>
开发者ID:kapai69,项目名称:fl-ru-damp,代码行数:30,代码来源:contacts_info.php

示例3: view_mark_user

</a><?php 
            echo view_mark_user(array('login' => $dContent['login'], 'is_pro' => true, 'role' => $dContent['role'], 'is_team' => $dContent['is_team']));
            ?>
                        &#160;<?php 
            echo $dContent['completed_sbr_cnt'] ? view_sbr_shield() : '';
            ?>
</h4>
                        <p>На сайте: <?php 
            echo ElapsedMnths(strtotime($dContent['reg_date']));
            ?>
</p>
                        <p>
                        <?php 
            if (!$info_for_reg['country'] || get_uid(false)) {
                if (intval($dContent['country']) != 0) {
                    print country::GetCountryName($dContent['country']);
                    if ($dContent['city'] && !$info_for_reg['city'] || get_uid(false)) {
                        if (intval($dContent['city']) != 0) {
                            print ", " . city::GetCityName($dContent['city']);
                        }
                    }
                }
            }
            //else
            ?>
					    </p>
                    </div>
                    <?php 
            if ($n == 3) {
                echo '<div style="clear:both;">&nbsp;</div>';
                $n = 0;
开发者ID:Nikitian,项目名称:fl-ru-damp,代码行数:31,代码来源:content.php

示例4: getInformationUser

 public function getInformationUser($uid = false)
 {
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/employer.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/freelancer.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/country.php";
     require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/city.php";
     if (!$uid) {
         $uid = $_SESSION['uid'];
     }
     if (is_emp()) {
         $user = new employer();
     } else {
         $user = new freelancer();
     }
     $user->GetUserByUID($uid);
     $this->setFieldInfo('uname', $user->uname);
     $this->setFieldInfo('usurname', $user->usurname);
     $this->setFieldInfo('birthday', $user->birthday);
     $this->setFieldInfo('country', $user->country);
     $this->setFieldInfo('country_name', country::GetCountryName($user->country));
     $this->setFieldInfo('city', $user->city);
     $this->setFieldInfo('city_name', city::GetCityName($user->city));
     $this->setFieldInfo('sex', $user->sex == 't' ? 1 : ($user->sex == 'f' ? 0 : -1));
     $this->setFieldInfo('info_for_reg', unserialize($user->info_for_reg));
 }
开发者ID:Nikitian,项目名称:fl-ru-damp,代码行数:25,代码来源:registration.php

示例5: header_location_exit

        $content = "new/tpl.step_1.php";
        break;
        //------------------------------------------------------------------------------
    //------------------------------------------------------------------------------
    case 0:
    default:
        header_location_exit('/public/?step=1&kind=1');
        break;
}
// Все изменения $tmpPrj->_project переносим в переменную.
$project = $tmpPrj->getProject();
if (trim($project['contacts']) != '') {
    $contacts = unserialize($project['contacts']) ? unserialize($project['contacts']) : $contacts;
}
if ($project['country']) {
    $location = country::GetCountryName($project['country']);
    if ($project['city']) {
        $location .= ': ' . city::GetCityName($project['city']);
    }
    $project['location'] = $location;
}
$prj_categories = $tmpPrj->getCategories();
if ($prj_categories) {
    foreach ($prj_categories as $ind => $category) {
        $prj_categories[$ind]['prof_name'] = $category['subcategory_id'] ? professions::GetProfNameWP($category['subcategory_id'], ': ', '', false) : professions::GetGroupName($category['category_id']);
    }
}
if ($step > 0) {
    $tmpPrj->fix();
}
if (!$additional_header) {
开发者ID:Nikitian,项目名称:fl-ru-damp,代码行数:31,代码来源:index.php

示例6: initTServicesCard

 /**
  * Заполняет значения в зависимости от услуги.
  * 
  * @param array  $tservice Массив с данными услуги
  * @param string $user     Массив с данными пользователя
  */
 public function initTServicesCard($tservice, $user)
 {
     $prof_id = $this->getRealProfId($tservice['category_id']);
     $this->seo_value = new SeoValues();
     $this->seo_value->initCard($prof_id);
     $title50 = LenghtFormatEx(trim(strip_tags($tservice['title'])), 50);
     $title100 = LenghtFormatEx(trim(strip_tags($tservice['title'])), 100);
     //Получаем названия страны и города
     $country_name = $city_name = '';
     if ($user->country > 0) {
         $country = new country();
         $country_name = $country->GetCountryName($user->country);
     }
     if ($user->city > 0) {
         $city = new city();
         $city_name = $city->GetCityName($user->city);
     }
     $fullname = trim("{$user->uname} {$user->usurname} [{$user->login}]");
     $this->title = sprintf(SeoText::TUC_TITLE, $title50, $tservice['price'], $fullname, $country_name, $city_name);
     $this->description = sprintf(SeoText::TUC_DESC, $fullname, $title100);
     $this->keywords = sprintf(SeoText::TUC_KEY, $fullname, $this->seo_value->getTUTitle(1), $this->seo_value->getKeysString());
     $this->image_name = $title50;
     $this->image_description = sprintf(SeoText::TUC_IMG_DESC, $title50, $this->seo_value->getKey(1));
     $this->footer_text = sprintf(SeoText::TUC_TAGS, $this->seo_value->getTUTitle(1), $this->seo_value->getKeysString());
 }
开发者ID:kapai69,项目名称:fl-ru-damp,代码行数:31,代码来源:SeoTags.php

示例7: ElapsedMnths

</div>
					</div>
					<div class="b-freelancer__txt b-freelancer__txt_fontsize_11 b-freelancer__txt_padbot_5">
						<div class="b-freelancer__txt b-freelancer__txt_valign_top b-freelancer__txt_inline-block b-freelancer__txt_width_120 b-freelancer__txt_bordbot_dot_e5"> <span class="b-freelancer__txt b-freelancer__txt_top_3 b-freelancer__txt_bg_fff">На сайте</span> </div>
						<div class="b-freelancer__txt b-freelancer__txt_inline-block b-freelancer__txt_width_320 b-freelancer__txt_top_3"><?php 
    echo ElapsedMnths(strtotime($offer['reg_date']));
    ?>
</div>
					</div>
					<?php 
    if ($offer['country'] && !($info_for_reg['country'] && !get_uid(false))) {
        ?>
					<div class="b-freelancer__txt b-freelancer__txt_fontsize_11 b-freelancer__txt_padbot_5">
						<div class="b-freelancer__txt b-freelancer__txt_valign_top b-freelancer__txt_inline-block b-freelancer__txt_width_120 b-freelancer__txt_bordbot_dot_e5"> <span class="b-freelancer__txt b-freelancer__txt_top_3 b-freelancer__txt_bg_fff">Местонахождение</span> </div>
						<div class="b-freelancer__txt b-freelancer__txt_inline-block b-freelancer__txt_width_320 b-freelancer__txt_top_3"><?php 
        echo country::GetCountryName($offer['country']);
        if ($offer['city'] && !($info_for_reg['city'] && !get_uid(false))) {
            print ", " . city::GetCityName($offer['city']);
        }
        ?>
</div>
					</div>
					<?php 
    }
    //if
    ?>
					<?php 
    if ($user_ago && !($info_for_reg['birthday'] && !get_uid(false))) {
        ?>
					<div class="b-freelancer__txt b-freelancer__txt_fontsize_11 b-freelancer__txt_padbot_5">
						<div class="b-freelancer__txt b-freelancer__txt_valign_top b-freelancer__txt_inline-block b-freelancer__txt_width_120 b-freelancer__txt_bordbot_dot_e5"> <span class="b-freelancer__txt b-freelancer__txt_top_3 b-freelancer__txt_bg_fff">Возраст</span> </div>
开发者ID:Nikitian,项目名称:fl-ru-damp,代码行数:31,代码来源:tpl.offers-item.php

示例8: country

 public function country($options)
 {
     extract($options);
     if (!$reqv || !$reqv['form_type']) {
         return false;
     }
     if ($reqv['country']) {
         return $reqv['country'];
     } elseif (in_array($reqv['rez_type'], array(sbr::RT_RU, sbr::RT_REFUGEE, sbr::RT_RESIDENCE))) {
         return 'Россия';
     } else {
         require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/country.php';
         return country::GetCountryName($user_country_id);
     }
 }
开发者ID:kapai69,项目名称:fl-ru-damp,代码行数:15,代码来源:DocGenReservesFormatter.php

示例9: actionProjects


//.........这里部分代码省略.........
                     $error['logo_link'] = 'Не верно введен адрес';
                 }
             } else {
                 $data['logo_id'] = null;
             }
             $price = 0;
             // закрепление на верху
             if ($option['top'] == 1 && $option['top_count'] > 0) {
                 if ($option['top_count'] > 999) {
                     $option['top_count'] = 999;
                 }
                 $price = (int) $option['top_count'] * ($data['kind'] == 7 ? $cTopPrice : $pTopPrice);
                 $data['top_count'] = (int) $option['top_count'];
                 $pay_option[] = array('wiz_uid' => $this->getWizardUserID(), 'op_code' => new_projects::OPCODE_PAYED, 'option' => self::PROJECT_OPTION_TOP, 'type' => $data['kind'] == 7 ? self::BILL_TYPE_CONTEST : self::BILL_TYPE_PROJECT, 'ammount' => $price);
             } else {
                 $data['top_count'] = 0;
             }
             // выделение цветом
             if ($option['color'] == 1) {
                 $price += (int) $colorPrc;
                 $data['is_color'] = true;
                 $pay_option[] = array('wiz_uid' => $this->getWizardUserID(), 'op_code' => new_projects::OPCODE_PAYED, 'option' => self::PROJECT_OPTION_COLOR, 'type' => $data['kind'] == 7 ? self::BILL_TYPE_CONTEST : self::BILL_TYPE_PROJECT, 'ammount' => $colorPrc);
             } else {
                 $data['is_color'] = false;
             }
             // выделение жирным
             if ($option['bold'] == 1) {
                 $price += (int) $boldPrc;
                 $data['is_bold'] = true;
                 $pay_option[] = array('wiz_uid' => $this->getWizardUserID(), 'op_code' => new_projects::OPCODE_PAYED, 'option' => self::PROJECT_OPTION_BOLD, 'type' => $data['kind'] == 7 ? self::BILL_TYPE_CONTEST : self::BILL_TYPE_PROJECT, 'ammount' => $boldPrc);
             } else {
                 $data['is_bold'] = false;
             }
             if ($option['logo'] == 1) {
                 $price += (int) $logoPrc;
                 $pay_option[] = array('wiz_uid' => $this->getWizardUserID(), 'op_code' => new_projects::OPCODE_PAYED, 'option' => self::PROJECT_OPTION_LOGO, 'type' => $data['kind'] == 7 ? self::BILL_TYPE_CONTEST : self::BILL_TYPE_PROJECT, 'ammount' => $logoPrc);
             }
             if ($price > 0) {
                 $data['payed'] = (int) $price;
             }
             if (!$error) {
                 $data['wiz_uid'] = $this->getWizardUserID();
                 // если проект уже есть
                 if ($existPrjID) {
                     // то просто обновляем его
                     $prj_id = $this->updateProject($data, $existPrjID);
                     // и очищаем все платные опции для этого проекта
                     wizard_billing::clearPayedOptions($prj_id);
                 } else {
                     $prj_id = $this->createProject($data);
                 }
                 if ($prj_id && $_POST['attachedfiles_session']) {
                     $attachedfiles = new attachedfiles($_POST['attachedfiles_session']);
                     $files = $attachedfiles->getFiles(array(1, 2, 3, 4));
                     $this->parent->addAttachedFiles($files, $prj_id);
                     $attachedfiles->clear();
                 }
                 if ($prj_id && $data['kind'] == 7) {
                     $insert = array('wiz_uid' => $data['wiz_uid'], 'op_code' => new_projects::OPCODE_KON_NOPRO, 'type' => self::BILL_TYPE_CONTEST, 'ammount' => new_projects::getKonkursPrice(), 'parent' => $prj_id);
                     wizard_billing::addPaidOption($insert);
                 }
                 if ($price > 0 && $prj_id) {
                     foreach ($pay_option as $k => $opt) {
                         $opt['parent'] = $prj_id;
                         wizard_billing::addPaidOption($opt);
                     }
                 }
                 if ($prj_id) {
                     $_SESSION['view_wizard_project'] = $prj_id;
                     header('Location: /wizard/registration/');
                     exit;
                 } else {
                     $error['project'] = 'Ошибка записи проекта';
                 }
             }
             $currency_name = __paramInit('string', null, 'currency');
             $priceby_name = __paramInit('string', null, 'priceby');
         }
         // Генерируем данные для вывода ошибок и заполнения полей
         $loc[] = country::GetCountryName($data['country']);
         if ($data['city']) {
             $loc[] = city::GetCityName($data['city']);
         }
         $location_name = implode(': ', $loc);
         $cat[] = professions::GetGroupName($category);
         if ($subcategory) {
             $cat[] = professions::GetProfName($subcategory);
         }
         $category_name = implode(': ', $cat);
         if ($data['logo_id']) {
             $file = new CFile($data['logo_id']);
             $logo_path = WDCPREFIX . '/' . $file->path . $file->name;
         }
         include $_SERVER['DOCUMENT_ROOT'] . '/wizard/registration/steps/tpl.step.project.php';
     } else {
         $project = $this->getProjectById($prj_id);
         $attached = $this->getProjectAttach($prj_id);
         include $_SERVER['DOCUMENT_ROOT'] . '/wizard/registration/steps/tpl.step.project.view.php';
     }
 }
开发者ID:kapai69,项目名称:fl-ru-damp,代码行数:101,代码来源:step_employer.php


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