• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

PHP get_features函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: get_feature_default

/**
 * @brief check if feature is enabled or disabled by default
 * 
 * @param string $feature
 * @return boolean
 */
function get_feature_default($feature)
{
    $f = get_features();
    foreach ($f as $cat) {
        foreach ($cat as $feat) {
            if (is_array($feat) && $feat[0] === $feature) {
                return $feat[3];
            }
        }
    }
    return false;
}
开发者ID:vinzv,项目名称:friendica,代码行数:18,代码来源:features.php


示例2: get

 function get()
 {
     $arr = array();
     $features = get_features();
     foreach ($features as $fname => $fdata) {
         $arr[$fname] = array();
         $arr[$fname][0] = $fdata[0];
         foreach (array_slice($fdata, 1) as $f) {
             $arr[$fname][1][] = array('feature_' . $f[0], $f[1], intval(feature_enabled(local_channel(), $f[0])) ? "1" : '', $f[2], array(t('Off'), t('On')));
         }
     }
     $tpl = get_markup_template("settings_features.tpl");
     $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_features"), '$title' => t('Additional Features'), '$features' => $arr, '$submit' => t('Submit')));
     return $o;
 }
开发者ID:phellmes,项目名称:hubzilla,代码行数:15,代码来源:Features.php


示例3: defaultfeatures_plugin_admin

function defaultfeatures_plugin_admin(&$a, &$o)
{
    $t = get_markup_template("admin.tpl", "addon/defaultfeatures/");
    $token = get_form_security_token("defaultfeaturessave");
    $arr = array();
    $features = get_features();
    foreach ($features as $fname => $fdata) {
        $arr[$fname] = array();
        $arr[$fname][0] = $fdata[0];
        foreach (array_slice($fdata, 1) as $f) {
            $arr[$fname][1][] = array('feature_' . $f[0], $f[1], intval(get_config('defaultfeatures', $f[0])) ? "1" : "0", $f[2], array(t('Off'), t('On')));
        }
    }
    //logger("Features: " . print_r($arr,true));
    $o = replace_macros($t, array('$submit' => t('Save Settings'), '$features' => $arr, '$form_security_token' => $token));
}
开发者ID:ZerGabriel,项目名称:friendica-addons,代码行数:16,代码来源:defaultfeatures.php


示例4: foreach

    foreach ($wp_properties['taxonomies'] as $tax_slug => $tax_data) {
        ?>
          <?php 
        if (get_features("type={$tax_slug}&format=count")) {
            ?>
          <div class="<?php 
            echo $tax_slug;
            ?>
_list">
          <h2><?php 
            echo $tax_data['label'];
            ?>
</h2>
          <ul class="clearfix">
          <?php 
            get_features("type={$tax_slug}&format=list&links=true");
            ?>
          </ul>
          </div>
          <?php 
        }
        ?>
        <?php 
    }
}
?>

        <?php 
if (is_array($wp_properties['property_meta'])) {
    ?>
        <?php 
开发者ID:ksan5835,项目名称:rankproperties,代码行数:31,代码来源:property.php


示例5: settings_content

function settings_content(&$a)
{
    $o = '';
    nav_set_selected('settings');
    if (!local_channel() || $_SESSION['delegate']) {
        notice(t('Permission denied.') . EOL);
        return login();
    }
    $channel = $a->get_channel();
    if ($channel) {
        head_set_icon($channel['xchan_photo_s']);
    }
    $yes_no = array(t('No'), t('Yes'));
    if (argc() > 1 && argv(1) === 'oauth') {
        if (argc() > 2 && argv(2) === 'add') {
            $tpl = get_markup_template("settings_oauth_edit.tpl");
            $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_oauth"), '$title' => t('Add application'), '$submit' => t('Submit'), '$cancel' => t('Cancel'), '$name' => array('name', t('Name'), '', t('Name of application')), '$key' => array('key', t('Consumer Key'), random_string(16), t('Automatically generated - change if desired. Max length 20')), '$secret' => array('secret', t('Consumer Secret'), random_string(16), t('Automatically generated - change if desired. Max length 20')), '$redirect' => array('redirect', t('Redirect'), '', t('Redirect URI - leave blank unless your application specifically requires this')), '$icon' => array('icon', t('Icon url'), '', t('Optional'))));
            return $o;
        }
        if (argc() > 3 && argv(2) === 'edit') {
            $r = q("SELECT * FROM clients WHERE client_id='%s' AND uid=%d", dbesc(argv(3)), local_channel());
            if (!count($r)) {
                notice(t("You can't edit this application."));
                return;
            }
            $app = $r[0];
            $tpl = get_markup_template("settings_oauth_edit.tpl");
            $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_oauth"), '$title' => t('Add application'), '$submit' => t('Update'), '$cancel' => t('Cancel'), '$name' => array('name', t('Name'), $app['name'], ''), '$key' => array('key', t('Consumer Key'), $app['client_id'], ''), '$secret' => array('secret', t('Consumer Secret'), $app['pw'], ''), '$redirect' => array('redirect', t('Redirect'), $app['redirect_uri'], ''), '$icon' => array('icon', t('Icon url'), $app['icon'], '')));
            return $o;
        }
        if (argc() > 3 && argv(2) === 'delete') {
            check_form_security_token_redirectOnErr('/settings/oauth', 'settings_oauth', 't');
            $r = q("DELETE FROM clients WHERE client_id='%s' AND uid=%d", dbesc(argv(3)), local_channel());
            goaway($a->get_baseurl(true) . "/settings/oauth/");
            return;
        }
        $r = q("SELECT clients.*, tokens.id as oauth_token, (clients.uid=%d) AS my \n\t\t\t\tFROM clients\n\t\t\t\tLEFT JOIN tokens ON clients.client_id=tokens.client_id\n\t\t\t\tWHERE clients.uid IN (%d,0)", local_channel(), local_channel());
        $tpl = get_markup_template("settings_oauth.tpl");
        $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_oauth"), '$baseurl' => $a->get_baseurl(true), '$title' => t('Connected Apps'), '$add' => t('Add application'), '$edit' => t('Edit'), '$delete' => t('Delete'), '$consumerkey' => t('Client key starts with'), '$noname' => t('No name'), '$remove' => t('Remove authorization'), '$apps' => $r));
        return $o;
    }
    if (argc() > 1 && argv(1) === 'featured') {
        $settings_addons = "";
        $o = '';
        $r = q("SELECT * FROM `hook` WHERE `hook` = 'feature_settings' ");
        if (!$r) {
            $settings_addons = t('No feature settings configured');
        }
        call_hooks('feature_settings', $settings_addons);
        $tpl = get_markup_template("settings_addons.tpl");
        $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_featured"), '$title' => t('Feature/Addon Settings'), '$settings_addons' => $settings_addons));
        return $o;
    }
    /*
     * ACCOUNT SETTINGS
     */
    if (argc() > 1 && argv(1) === 'account') {
        $account_settings = "";
        call_hooks('account_settings', $account_settings);
        $email = $a->account['account_email'];
        $tpl = get_markup_template("settings_account.tpl");
        $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_account"), '$title' => t('Account Settings'), '$password1' => array('npassword', t('Enter New Password:'), '', ''), '$password2' => array('confirm', t('Confirm New Password:'), '', t('Leave password fields blank unless changing')), '$submit' => t('Submit'), '$email' => array('email', t('Email Address:'), $email, ''), '$removeme' => t('Remove Account'), '$removeaccount' => t('Remove this account including all its channels'), '$account_settings' => $account_settings));
        return $o;
    }
    if (argc() > 1 && argv(1) === 'features') {
        $arr = array();
        $features = get_features();
        foreach ($features as $fname => $fdata) {
            $arr[$fname] = array();
            $arr[$fname][0] = $fdata[0];
            foreach (array_slice($fdata, 1) as $f) {
                $arr[$fname][1][] = array('feature_' . $f[0], $f[1], intval(feature_enabled(local_channel(), $f[0])) ? "1" : '', $f[2], array(t('Off'), t('On')));
            }
        }
        $tpl = get_markup_template("settings_features.tpl");
        $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_features"), '$title' => t('Additional Features'), '$features' => $arr, '$submit' => t('Submit')));
        return $o;
    }
    if (argc() > 1 && argv(1) === 'connectors') {
        $settings_connectors = "";
        call_hooks('connector_settings', $settings_connectors);
        $r = null;
        $tpl = get_markup_template("settings_connectors.tpl");
        $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_connectors"), '$title' => t('Connector Settings'), '$submit' => t('Submit'), '$settings_connectors' => $settings_connectors));
        call_hooks('display_settings', $o);
        return $o;
    }
    /*
     * DISPLAY SETTINGS
     */
    if (argc() > 1 && argv(1) === 'display') {
        $default_theme = get_config('system', 'theme');
        if (!$default_theme) {
            $default_theme = 'default';
        }
        $default_mobile_theme = get_config('system', 'mobile_theme');
        if (!$mobile_default_theme) {
            $mobile_default_theme = 'none';
        }
        $allowed_themes_str = get_config('system', 'allowed_themes');
//.........这里部分代码省略.........
开发者ID:Gillesq,项目名称:hubzilla,代码行数:101,代码来源:settings.php


示例6: settings_content

 function settings_content(&$a)
 {
     $o = '';
     nav_set_selected('settings');
     if (!local_user()) {
         #notice( t('Permission denied.') . EOL );
         return;
     }
     if (x($_SESSION, 'submanage') && intval($_SESSION['submanage'])) {
         notice(t('Permission denied.') . EOL);
         return;
     }
     if ($a->argc > 1 && $a->argv[1] === 'oauth') {
         if ($a->argc > 2 && $a->argv[2] === 'add') {
             $tpl = get_markup_template("settings_oauth_edit.tpl");
             $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_oauth"), '$title' => t('Add application'), '$submit' => t('Save Settings'), '$cancel' => t('Cancel'), '$name' => array('name', t('Name'), '', ''), '$key' => array('key', t('Consumer Key'), '', ''), '$secret' => array('secret', t('Consumer Secret'), '', ''), '$redirect' => array('redirect', t('Redirect'), '', ''), '$icon' => array('icon', t('Icon url'), '', '')));
             return $o;
         }
         if ($a->argc > 3 && $a->argv[2] === 'edit') {
             $r = q("SELECT * FROM clients WHERE client_id='%s' AND uid=%d", dbesc($a->argv[3]), local_user());
             if (!count($r)) {
                 notice(t("You can't edit this application."));
                 return;
             }
             $app = $r[0];
             $tpl = get_markup_template("settings_oauth_edit.tpl");
             $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_oauth"), '$title' => t('Add application'), '$submit' => t('Update'), '$cancel' => t('Cancel'), '$name' => array('name', t('Name'), $app['name'], ''), '$key' => array('key', t('Consumer Key'), $app['client_id'], ''), '$secret' => array('secret', t('Consumer Secret'), $app['pw'], ''), '$redirect' => array('redirect', t('Redirect'), $app['redirect_uri'], ''), '$icon' => array('icon', t('Icon url'), $app['icon'], '')));
             return $o;
         }
         if ($a->argc > 3 && $a->argv[2] === 'delete') {
             check_form_security_token_redirectOnErr('/settings/oauth', 'settings_oauth', 't');
             $r = q("DELETE FROM clients WHERE client_id='%s' AND uid=%d", dbesc($a->argv[3]), local_user());
             goaway($a->get_baseurl(true) . "/settings/oauth/");
             return;
         }
         $r = q("SELECT clients.*, tokens.id as oauth_token, (clients.uid=%d) AS my\n\t\t\t\tFROM clients\n\t\t\t\tLEFT JOIN tokens ON clients.client_id=tokens.client_id\n\t\t\t\tWHERE clients.uid IN (%d,0)", local_user(), local_user());
         $tpl = get_markup_template("settings_oauth.tpl");
         $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_oauth"), '$baseurl' => $a->get_baseurl(true), '$title' => t('Connected Apps'), '$add' => t('Add application'), '$edit' => t('Edit'), '$delete' => t('Delete'), '$consumerkey' => t('Client key starts with'), '$noname' => t('No name'), '$remove' => t('Remove authorization'), '$apps' => $r));
         return $o;
     }
     if ($a->argc > 1 && $a->argv[1] === 'addon') {
         $settings_addons = "";
         $r = q("SELECT * FROM `hook` WHERE `hook` = 'plugin_settings' ");
         if (!count($r)) {
             $settings_addons = t('No Plugin settings configured');
         }
         call_hooks('plugin_settings', $settings_addons);
         $tpl = get_markup_template("settings_addons.tpl");
         $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_addon"), '$title' => t('Plugin Settings'), '$settings_addons' => $settings_addons));
         return $o;
     }
     if ($a->argc > 1 && $a->argv[1] === 'features') {
         $arr = array();
         $features = get_features();
         foreach ($features as $fname => $fdata) {
             $arr[$fname] = array();
             $arr[$fname][0] = $fdata[0];
             foreach (array_slice($fdata, 1) as $f) {
                 $arr[$fname][1][] = array('feature_' . $f[0], $f[1], intval(get_pconfig(local_user(), 'feature', $f[0])) ? "1" : '', $f[2], array(t('Off'), t('On')));
             }
         }
         $tpl = get_markup_template("settings_features.tpl");
         $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_features"), '$title' => t('Additional Features'), '$features' => $arr, '$submit' => t('Save Settings')));
         return $o;
     }
     if ($a->argc > 1 && $a->argv[1] === 'connectors') {
         $settings_connectors = "";
         call_hooks('connector_settings', $settings_connectors);
         if (is_site_admin()) {
             $diasp_enabled = sprintf(t('Built-in support for %s connectivity is %s'), t('Diaspora'), get_config('system', 'diaspora_enabled') ? t('enabled') : t('disabled'));
             $ostat_enabled = sprintf(t('Built-in support for %s connectivity is %s'), t('StatusNet'), get_config('system', 'ostatus_disabled') ? t('disabled') : t('enabled'));
         } else {
             $diasp_enabled = "";
             $ostat_enabled = "";
         }
         $mail_disabled = function_exists('imap_open') && !get_config('system', 'imap_disabled') ? 0 : 1;
         if (get_config('system', 'dfrn_only')) {
             $mail_disabled = 1;
         }
         if (!$mail_disabled) {
             $r = q("SELECT * FROM `mailacct` WHERE `uid` = %d LIMIT 1", local_user());
         } else {
             $r = null;
         }
         $mail_server = count($r) ? $r[0]['server'] : '';
         $mail_port = count($r) && intval($r[0]['port']) ? intval($r[0]['port']) : '';
         $mail_ssl = count($r) ? $r[0]['ssltype'] : '';
         $mail_user = count($r) ? $r[0]['user'] : '';
         $mail_replyto = count($r) ? $r[0]['reply_to'] : '';
         $mail_pubmail = count($r) ? $r[0]['pubmail'] : 0;
         $mail_action = count($r) ? $r[0]['action'] : 0;
         $mail_movetofolder = count($r) ? $r[0]['movetofolder'] : '';
         $mail_chk = count($r) ? $r[0]['last_check'] : '0000-00-00 00:00:00';
         $tpl = get_markup_template("settings_connectors.tpl");
         if (!service_class_allows(local_user(), 'email_connect')) {
             $mail_disabled_message = upgrade_bool_message();
         } else {
             $mail_disabled_message = $mail_disabled ? t('Email access is disabled on this site.') : '';
         }
         $o .= replace_macros($tpl, array('$form_security_token' => get_form_security_token("settings_connectors"), '$title' => t('Social Networks'), '$diasp_enabled' => $diasp_enabled, '$ostat_enabled' => $ostat_enabled, '$h_imap' => t('Email/Mailbox Setup'), '$imap_desc' => t("If you wish to communicate with email contacts using this service (optional), please specify how to connect to your mailbox."), '$imap_lastcheck' => array('imap_lastcheck', t('Last successful email check:'), $mail_chk, ''), '$mail_disabled' => $mail_disabled_message, '$mail_server' => array('mail_server', t('IMAP server name:'), $mail_server, ''), '$mail_port' => array('mail_port', t('IMAP port:'), $mail_port, ''), '$mail_ssl' => array('mail_ssl', t('Security:'), strtoupper($mail_ssl), '', array('notls' => t('None'), 'TLS' => 'TLS', 'SSL' => 'SSL')), '$mail_user' => array('mail_user', t('Email login name:'), $mail_user, ''), '$mail_pass' => array('mail_pass', t('Email password:'), '', ''), '$mail_replyto' => array('mail_replyto', t('Reply-to address:'), $mail_replyto, 'Optional'), '$mail_pubmail' => array('mail_pubmail', t('Send public posts to all email contacts:'), $mail_pubmail, ''), '$mail_action' => array('mail_action', t('Action after import:'), $mail_action, '', array(0 => t('None'), 2 => t('Mark as seen'), 3 => t('Move to folder'))), '$mail_movetofolder' => array('mail_movetofolder', t('Move to folder:'), $mail_movetofolder, ''), '$submit' => t('Save Settings'), '$settings_connectors' => $settings_connectors));
//.........这里部分代码省略.........
开发者ID:strk,项目名称:friendica,代码行数:101,代码来源:settings.php


示例7: widget_settings_menu

function widget_settings_menu($arr)
{
    if (!local_channel()) {
        return;
    }
    $a = get_app();
    $channel = $a->get_channel();
    $abook_self_id = 0;
    // Retrieve the 'self' address book entry for use in the auto-permissions link
    $role = get_pconfig(local_channel(), 'system', 'permissions_role');
    $abk = q("select abook_id from abook where abook_channel = %d and abook_self = 1 limit 1", intval(local_channel()));
    if ($abk) {
        $abook_self_id = $abk[0]['abook_id'];
    }
    $tabs = array(array('label' => t('Account settings'), 'url' => $a->get_baseurl(true) . '/settings/account', 'selected' => argv(1) === 'account' ? 'active' : ''), array('label' => t('Channel settings'), 'url' => $a->get_baseurl(true) . '/settings/channel', 'selected' => argv(1) === 'channel' ? 'active' : ''));
    if (get_features()) {
        $tabs[] = array('label' => t('Additional features'), 'url' => $a->get_baseurl(true) . '/settings/features', 'selected' => argv(1) === 'features' ? 'active' : '');
    }
    $tabs[] = array('label' => t('Feature/Addon settings'), 'url' => $a->get_baseurl(true) . '/settings/featured', 'selected' => argv(1) === 'featured' ? 'active' : '');
    $tabs[] = array('label' => t('Display settings'), 'url' => $a->get_baseurl(true) . '/settings/display', 'selected' => argv(1) === 'display' ? 'active' : '');
    $tabs[] = array('label' => t('Connected apps'), 'url' => $a->get_baseurl(true) . '/settings/oauth', 'selected' => argv(1) === 'oauth' ? 'active' : '');
    $tabs[] = array('label' => t('Export channel'), 'url' => $a->get_baseurl(true) . '/uexport', 'selected' => '');
    if ($role === false || $role === 'custom') {
        $tabs[] = array('label' => t('Connection Default Permissions'), 'url' => $a->get_baseurl(true) . '/connedit/' . $abook_self_id, 'selected' => '');
    }
    if (feature_enabled(local_channel(), 'premium_channel')) {
        $tabs[] = array('label' => t('Premium Channel Settings'), 'url' => $a->get_baseurl(true) . '/connect/' . $channel['channel_address'], 'selected' => '');
    }
    if (feature_enabled(local_channel(), 'channel_sources')) {
        $tabs[] = array('label' => t('Channel Sources'), 'url' => $a->get_baseurl(true) . '/sources', 'selected' => '');
    }
    $tabtpl = get_markup_template("generic_links_widget.tpl");
    return replace_macros($tabtpl, array('$title' => t('Settings'), '$class' => 'settings-widget', '$items' => $tabs));
}
开发者ID:royalterra,项目名称:hubzilla,代码行数:34,代码来源:widgets.php


示例8: display_features

/**
 * Display features
 */
function display_features()
{
    $features = get_features();
    $max_name_len = 32;
    foreach ($features as $feature) {
        if (($len = strlen($feature['name'])) > $max_name_len) {
            $max_name_len = $len;
        }
    }
    echo "Enabled\t" . str_pad('Name', $max_name_len) . "\tDescription\n";
    foreach ($features as $feature) {
        echo ($feature['enabled'] ? 'yes' : 'no') . "\t" . str_pad($feature['name'], $max_name_len) . "\t{$feature['description']}\n";
    }
}
开发者ID:CalConnect,项目名称:caldavtester-tools,代码行数:17,代码来源:caldavtests.php


示例9: get_features

					</div>
				</div>
			</div>
			<script src="js/grid.js"></script>
			<script>
				$(function() {
					Grid.init();
				});
			</script>
		</div>
		<!--===================================== New game [end] =====================================-->

        <!--===================================== Feature [start] =====================================-->
		<div class="col-mn">
            <?php 
$result = get_features();
if (mysqli_num_rows($result) > 0) {
    $games = mysqli_fetch_array($result, MYSQLI_ASSOC);
    $content = excerpt_features($games['content']);
    ?>
			<div class="container">
                <div class="col-mn2">
                    <h3><?php 
    echo $games['title'];
    ?>
</h3>
                    <p><?php 
    echo $content;
    ?>
...</p>
                    <a class=" more-in" href="single.php?nid=<?php 
开发者ID:BeoSagittarius,项目名称:gamecenter,代码行数:31,代码来源:index.php


示例10: widget_settings_menu

function widget_settings_menu($arr)
{
    if (!local_channel()) {
        return;
    }
    $channel = App::get_channel();
    $abook_self_id = 0;
    // Retrieve the 'self' address book entry for use in the auto-permissions link
    $role = get_pconfig(local_channel(), 'system', 'permissions_role');
    $abk = q("select abook_id from abook where abook_channel = %d and abook_self = 1 limit 1", intval(local_channel()));
    if ($abk) {
        $abook_self_id = $abk[0]['abook_id'];
    }
    $hublocs = q("select count(*) as total from hubloc where hubloc_hash = '%s'", dbesc($channel['channel_hash']));
    $hublocs = $hublocs[0]['total'] > 1 ? true : false;
    $tabs = array(array('label' => t('Account settings'), 'url' => z_root() . '/settings/account', 'selected' => argv(1) === 'account' ? 'active' : ''), array('label' => t('Channel settings'), 'url' => z_root() . '/settings/channel', 'selected' => argv(1) === 'channel' ? 'active' : ''));
    if (get_features()) {
        $tabs[] = array('label' => t('Additional features'), 'url' => z_root() . '/settings/features', 'selected' => argv(1) === 'features' ? 'active' : '');
    }
    $tabs[] = array('label' => t('Feature/Addon settings'), 'url' => z_root() . '/settings/featured', 'selected' => argv(1) === 'featured' ? 'active' : '');
    $tabs[] = array('label' => t('Display settings'), 'url' => z_root() . '/settings/display', 'selected' => argv(1) === 'display' ? 'active' : '');
    if ($hublocs) {
        $tabs[] = array('label' => t('Manage locations'), 'url' => z_root() . '/locs', 'selected' => argv(1) === 'locs' ? 'active' : '');
    }
    // IF can go away when UNO export and import is fully functional
    if (!UNO) {
        $tabs[] = array('label' => t('Export channel'), 'url' => z_root() . '/uexport', 'selected' => '');
    }
    $tabs[] = array('label' => t('Connected apps'), 'url' => z_root() . '/settings/oauth', 'selected' => argv(1) === 'oauth' ? 'active' : '');
    if (!UNO) {
        $tabs[] = array('label' => t('Guest Access Tokens'), 'url' => z_root() . '/settings/tokens', 'selected' => argv(1) === 'tokens' ? 'active' : '');
    }
    if ($role === false || $role === 'custom') {
        $tabs[] = array('label' => t('Connection Default Permissions'), 'url' => z_root() . '/connedit/' . $abook_self_id, 'selected' => '');
    }
    if (feature_enabled(local_channel(), 'premium_channel')) {
        $tabs[] = array('label' => t('Premium Channel Settings'), 'url' => z_root() . '/connect/' . $channel['channel_address'], 'selected' => '');
    }
    if (feature_enabled(local_channel(), 'channel_sources')) {
        $tabs[] = array('label' => t('Channel Sources'), 'url' => z_root() . '/sources', 'selected' => '');
    }
    $tabtpl = get_markup_template("generic_links_widget.tpl");
    return replace_macros($tabtpl, array('$title' => t('Settings'), '$class' => 'settings-widget', '$items' => $tabs));
}
开发者ID:einervonvielen,项目名称:hubzilla,代码行数:44,代码来源:widgets.php


示例11: version_get_features

/**
 * FEATURES:
 */
function version_get_features($language)
{
    if (get_row_layout() == 'feature_box') {
        $feature_id = get_sub_field('feature_box_input');
        $fbox_args = array('post_type' => 'ultraschall_features', 'post_status' => 'publish', 'posts_per_page' => 1, 'p' => $feature_id);
        $fbox_query = null;
        $fbox_query = new WP_Query($fbox_args);
        while ($fbox_query->have_posts()) {
            $fbox_query->the_post();
            get_features($language);
        }
        wp_reset_query();
    }
}
开发者ID:McCouman,项目名称:ultraschall-plugin,代码行数:17,代码来源:versions-functions.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP get_fee函数代码示例发布时间:2022-05-15
下一篇:
PHP get_featured_photo_by_id函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap