當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Contacts::getContactsTypeList方法代碼示例

本文整理匯總了PHP中Contacts::getContactsTypeList方法的典型用法代碼示例。如果您正苦於以下問題:PHP Contacts::getContactsTypeList方法的具體用法?PHP Contacts::getContactsTypeList怎麽用?PHP Contacts::getContactsTypeList使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Contacts的用法示例。


在下文中一共展示了Contacts::getContactsTypeList方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: Contacts

$gBitSystem->verifyPackage('contacts');
$gBitSystem->verifyPermission('p_contacts_view');
$gContent = new Contacts();
/*
if($feature_listContacts != 'y') {
  $gBitSmarty->assign('msg',tra("This feature is disabled"));
  $gBitSystem->display( 'error.tpl' , NULL, array( 'display_mode' => 'list' ));
  die;
}
*/
/*
// Now check permissions to access this page
if(!$gBitUser->( 'contact_p_view' )) {
  $gBitSmarty->assign('msg',tra("Permission denied you cannot view contacts"));
  $gBitSystem->display( 'error.tpl' , NULL, array( 'display_mode' => 'list' ));
  die;
}
*/
if (empty($_REQUEST["sort_mode"])) {
    $_REQUEST["sort_mode"] = 'surname_asc';
}
$contact_type = $gContent->getContactsTypeList();
$gBitSmarty->assign_by_ref('contact_type', $contact_type);
$listHash = $_REQUEST;
// Get a list of matching contact entries
$listcontacts = $gContent->getList($listHash);
$gBitSmarty->assign_by_ref('listcontacts', $listcontacts);
$gBitSmarty->assign_by_ref('listInfo', $listHash['listInfo']);
$gBitSystem->setBrowserTitle("View Contacts List");
// Display the template
$gBitSystem->display('bitpackage:contacts/list.tpl', NULL, array('display_mode' => 'list'));
開發者ID:bitweaver,項目名稱:contacts,代碼行數:31,代碼來源:list.php

示例2: header

    } else {
        header("Location: " . CONTACTS_PKG_URL);
    }
    die;
} elseif (isset($_REQUEST["fSaveContact"])) {
    if ($gContent->store($_REQUEST)) {
        if ($gBitSystem->isFeatureActive('contact_watch_author')) {
            $gBitUser->storeWatch("contact_entry_changed", $gContent->mContentId, $gContent->mContentTypeGuid, $_REQUEST['title'], $gContent->getDisplayUrl());
        }
        header("Location: " . $gContent->getDisplayUrl());
    } else {
        $formInfo = $_REQUEST;
        $formInfo['data'] =& $_REQUEST['edit'];
    }
}
// Configure quicktags list
if ($gBitSystem->isPackageActive('quicktags')) {
    include_once QUICKTAGS_PKG_PATH . 'quicktags_inc.php';
}
// WYSIWYG and Quicktag variable
$gBitSmarty->assign('textarea_id', 'editwiki');
// formInfo might be set due to a error on submit
if (empty($formInfo)) {
    $formInfo =& $gContent->mInfo;
}
$formInfo['contact_type_list'] = $gContent->getContactsTypeList();
$gBitSmarty->assign_by_ref('contactInfo', $formInfo);
$gBitSmarty->assign_by_ref('errors', $gContent->mErrors);
$gBitSmarty->assign((!empty($_REQUEST['tab']) ? $_REQUEST['tab'] : 'body') . 'TabSelect', 'tdefault');
$gBitSmarty->assign('show_page_bar', 'y');
$gBitSystem->display('bitpackage:contacts/edit.tpl', 'Edit: ', array('display_mode' => 'edit'));
開發者ID:bitweaver,項目名稱:contacts,代碼行數:31,代碼來源:edit.php


注:本文中的Contacts::getContactsTypeList方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。