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

PHP getOptions函数代码示例

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

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



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

示例1: runQueryWithView

 private static function runQueryWithView($query, $fields, $printArray)
 {
     $_SESSION['tableData'] = array();
     $exec_time_row = array();
     $records = '';
     try {
         // turn on query profiling
         Flight::get('db')->query('SET profiling = 1;');
         $stmt = Flight::get('db')->query($query);
         // find out time above query was ran for
         $exec_time_result = Flight::get('db')->query('SELECT query_id, SUM(duration) FROM information_schema.profiling GROUP BY query_id ORDER BY query_id DESC LIMIT 1;');
         $exec_time_row = $exec_time_result->fetchAll(PDO::FETCH_NUM);
         // run query and fetch array
         $data = $stmt->fetchAll(PDO::FETCH_ASSOC);
         // store table fields/columns + data rows in session for exporting later
         $_SESSION['tableData'] = array_merge($fields, $data);
         $records = Presenter::listTableData($data);
     } catch (PDOException $e) {
         setFlashMessage('Error: ' . $e->getMessage());
     }
     Flight::render('table', array('title' => Flight::get('lastSegment'), 'icon' => self::$icon, 'table_data' => $records, 'fields' => getOptions($fields), 'query' => SqlFormatter::format($query), 'printArray' => $printArray, 'timetaken' => $exec_time_row[0][1]));
 }
开发者ID:bubach,项目名称:VisualQuery,代码行数:22,代码来源:table.php


示例2: getselectfields

 /**
  * Gets fields/columns from specified tables and generates dropdown options
  */
 public function getselectfields()
 {
     $tablesJSON = $_POST['tables'];
     if ($tablesJSON) {
         $html = '';
         $tables = json_decode($tablesJSON, true);
         foreach ($tables as $table) {
             // table columns
             $stmt = Flight::get('db')->query("DESCRIBE {$table}");
             $columns = $stmt->fetchAll(PDO::FETCH_ASSOC);
             //pretty_print($columns);
             $fields = array();
             foreach ($columns as $values) {
                 if (isset($values['Field'])) {
                     $fields[] = $values['Field'];
                 }
             }
             //pretty_print($fields);
             $html .= '<optgroup label="' . $table . '">' . "\n";
             $html .= getOptions($fields, false, $table);
             $html .= '</optgroup>' . "\n";
         }
         echo $html;
     }
 }
开发者ID:bubach,项目名称:VisualQuery,代码行数:28,代码来源:ajax.php


示例3: sendErrorReport

function sendErrorReport()
{
    $options = getOptions();
    $extra_vars = isset($options['params']) ? $options['params'] : false;
    $content = parseEmail($options['email'], $extra_vars);
    email_send($options['mailTo'], "Une erreur s'est produite sur OpenNAS", $content, $outError);
    exit($outError);
}
开发者ID:BillTheBest,项目名称:OpenNAS,代码行数:8,代码来源:repl_alert.php


示例4: getOptions

function getOptions($types, $typeids, $key = 0, $level = 0)
{
    $typeOptions = '';
    if (isset($types[$key])) {
        foreach ($types[$key] as $k => $v) {
            $typeOptions .= "\r\n<option value='{$v['id']}' class='btype'" . (in_array($v['id'], $typeids) ? ' selected' : '') . '>' . str_repeat('-', $level) . $v['name'] . '</option>';
            $typeOptions .= getOptions($types, $typeids, $v['id'], $level + 1);
        }
    }
    return $typeOptions;
}
开发者ID:puppylsy,项目名称:cms,代码行数:11,代码来源:sys_admin_user_add.php


示例5: __construct

 function __construct($ACTION = '', $data_filter = array(), $scopeSanitize = array(), $raw_scope_filter = array('ACTION', 'METHOD', 'id', 'scope', 'sc', 'hash', 'sessid', 'crm', 'agent', 'ip', 'city', 'Referer', 'http_referer'))
 {
     if (is_string($data_filter)) {
         $data_filter = explode(',', $data_filter);
     }
     if (is_string($raw_scope_filter)) {
         $raw_scope_filter = explode(',', $raw_scope_filter);
     }
     $this->raw_scope = array();
     defined('ACTION') or define('ACTION', $ACTION);
     RESTful::$filter = $data_filter;
     // Define method type
     if (empty($_SERVER['DOCUMENT_ROOT']) && !empty($_SERVER['SHELL'])) {
         define('METHOD', 'CONSOLE');
         //$this->private_name='CONSOLE';
     } else {
         $this->raw_scope['agent'] = $_SERVER['HTTP_USER_AGENT'];
         $this->raw_scope['ip'] = $ip = $_SERVER['REMOTE_ADDR'];
         if (isset($_SERVER['HTTP_REFERER'])) {
             $this->raw_scope['http_referer'] = $_SERVER['HTTP_REFERER'];
         }
         if (isset($_SERVER['REQUEST_METHOD'])) {
             define('METHOD', $_SERVER['REQUEST_METHOD']);
             //$this->private_name=$_SERVER['REQUEST_METHOD'];
         } else {
             define('METHOD', 'UNKNOWN');
         }
     }
     // Combine parameters
     if (METHOD == 'CONSOLE') {
         //$this->raw_scope = array_merge($this->raw_scope, $_SERVER['argv']);
         require API_CORE_PATH . '/class/rest/getoptions.php';
         $this->raw_scope = array_merge($this->raw_scope, getOptions());
     } else {
         $this->raw_scope = array_merge($this->raw_scope, $_REQUEST);
         $this->raw_scope = array_merge($this->raw_scope, $this->parseRequestHeaders());
     }
     // Расстановка значений
     $this->raw_scope['ACTION'] = $ACTION;
     $this->raw_scope['METHOD'] = METHOD;
     if (empty($this->raw_scope['scope']) && !empty($this->raw_scope['sc'])) {
         // sc - синоним scope
         $this->raw_scope['scope'] = $this->raw_scope['sc'];
         unset($this->raw_scope['sc']);
     }
     // Для дебага, возможность переопределять метод
     if (DEBUG && isset($_GET['METHOD'])) {
         $this->raw_scope['METHOD'] = $_GET['METHOD'];
     }
     $this->scope = $this->sanitize($this->filtrateScope($raw_scope_filter), $scopeSanitize);
     $this->data = $this->sanitize($this->filtrateScope(), $scopeSanitize);
     return $this->raw_scope;
 }
开发者ID:ershov-ilya,项目名称:restful.class.php,代码行数:53,代码来源:restful.class.php


示例6: testCurlPost

 public function testCurlPost()
 {
     try {
         $config = getHostConfig();
         $config['host'] = 'http://requestb.in/vqid8qvq';
         $j = new \JiraRestApi\JiraClient($config, getOptions());
         $post_data = array('name' => 'value');
         $http_status = 0;
         $ret = $j->exec('/', json_encode($post_data), $http_status);
         var_dump($ret);
         $this->assertTrue(true);
     } catch (HTTPException $e) {
         $this->assertTrue(false, $e->getMessage());
     }
 }
开发者ID:jeslopcru,项目名称:php-jira-rest-client,代码行数:15,代码来源:CurlTest.php


示例7: search

 public function search($offset = 0)
 {
     $options = $this->m_places->array_from_post(array('title_s', 'type', 'city', 'minbed', 'maxbed', 'minbath', 'maxbath', 'minprice', 'maxprice', 'minfloor', 'maxfloor'));
     if ($this->form_validation->run('search')) {
         $count = $this->m_places->search($options, $status = FALSE);
         $perpage = getOptions('paging');
         if (count($count) > $perpage) {
             $this->load->library('pagination');
             $config['base_url'] = site_url('admin/places/search');
             $config['total_rows'] = count($count);
             $config['per_page'] = $perpage;
             $config['uri_segment'] = 4;
             $q = $this->pagination->initialize($config);
             $offset = $this->uri->segment(4) ? $this->uri->segment(4) : 0;
         } else {
             $this->data['pagination'] = '';
             $offset = 0;
         }
         $status = $this->m_places->status_place;
         $telo = $this->m_places->search($options, $status = FALSE, $perpage, $offset);
         $str = '';
         if ($telo) {
             $str .= '<section class="col-xs-12 col-sm-6 col-md-12">';
             foreach ($telo as $s) {
                 $str .= '<article class="search-result row">';
                 $str .= $s->image ? '<div class="col-xs-12 col-sm-12 col-md-3"><img class="img-responsive thumbnail" src="' . base_url('assets/img/timthumb.php') . '?src=' . base_url($s->image) . '&zc=0&h=140&w=180"></div>' : '<div class="col-xs-12 col-sm-12 col-md-3"><img class="img-responsive thumbnail" src="http://placehold.it/250x140&text=no+primary+image"></div>';
                 $str .= '<div class="col-xs-12 col-sm-12 col-md-2"><ul class="meta-search">';
                 $str .= '<ul><i class="fa fa-money"></i><span> ' . ($s->prices === null ? 'Not Set' : $this->data['currency'][getOptions('currency')] . ' ' . currency($s->prices)) . '</span></li>';
                 $str .= '<ul><li><i class="glyphicon glyphicon-home"></i> <span>' . ($s->title_type === null ? 'Not Set' : $s->title_type) . '</span></li>';
                 $str .= '<ul><li><i class="fa fa-arrows"></i> <span>' . ($s->floor_dim === null ? 'Not Set' : $s->floor_dim . ' ' . $this->data['floor'][getOptions('floor_metric')]) . '</span></li>';
                 $str .= '<ul><li><i class="fa fa-table"></i> <span>' . ($s->bedrooms === null ? 'Not Set' : $s->bedrooms . ' bedrooms') . '</span></li>';
                 $str .= '<ul><li><a href=' . site_url('front/places/details') . '/' . $s->id_places . ' class="btn btn-primary btn-xs">View Details</a></li>';
                 $str .= '</ul></div>';
                 $str .= '<div class="col-xs-12 col-sm-12 col-md-7 excerpet">';
                 $str .= '<h3>' . $s->title_places . ' / ' . $this->data['status'][$s->status] . '</h3>';
                 $str .= '<p>' . limit_to_numwords(strip_tags($s->desc), 50) . '</p></div>';
                 //                    $str .= '<td>' . ($s->title_type === null ? 'Not Set' : $s->title_type) . '</td>';
                 //                    $str .= '<td>' . ($s->prices === null ? 'Not Set' : $this->data['currency'][getOptions('currency')] . ' ' . currency($s->prices)) . '</td>';
                 $str .= '<span class="clearfix borda"></span></article>';
             }
             $str .= '<div>' . $this->pagination->create_links() . '</div>';
             $str .= '</section>';
         } else {
             $str .= 'No Data Found';
         }
         echo $str;
     }
 }
开发者ID:JamesWuChina,项目名称:CI-Property,代码行数:48,代码来源:places.php


示例8: getTargetDir

/**
 * Get target directory
 *
 * @return string|bool Return false when the target directory is not exists.
 */
function getTargetDir()
{
    $options = getOptions();
    $folderName = 'WebIde' . str_pad($options['ide-version'], 2, 0);
    $os = php_uname();
    if (preg_match('#^Windows#i', $os)) {
        // Windows path
        $configPath = getenv('HOMEDRIVE') . getenv("HOMEPATH") . '\\.' . $folderName;
    } elseif (preg_match('#^Linux#i', $os)) {
        // Linux path
        $configPath = '~/.' . $folderName;
    } else {
        // Mac OSX path
        $configPath = '~/Library/Preferences/' . $folderName;
    }
    return $configPath;
}
开发者ID:asika32764,项目名称:sms-phpstorm-config-installer,代码行数:22,代码来源:main.php


示例9: drawOptions

function drawOptions($translator)
{
    $options = getOptions($translator);
    $html = null;
    foreach ($options as $option) {
        $html .= '<tr>
                    <td>
                        <a href="' . $option['url'] . '">' . $option['name'] . '</a>
                    </td>
                    <td>
                        ' . $option['recommended'] . '
                    </td>
                    <td>
                        ' . $option['current'] . '
                    </td>
                  </tr>';
    }
    return $html;
}
开发者ID:ragebat,项目名称:chamilo-lms,代码行数:19,代码来源:install.lib.php


示例10: anchor

     if ($ChildCategories != '') {
         $ChildCategories .= ', ';
     }
     $ChildCategories .= anchor(Gdn_Format::text($Category->Name), CategoryUrl($Category));
 } else {
     if ($Category->DisplayAs === 'Heading') {
         $CatList .= '<li id="Category_' . $CategoryID . '" class="CategoryHeading ' . $CssClass . '">
        <div class="ItemContent Category"><div class="Options">' . getOptions($Category, $this) . '</div>' . Gdn_Format::text($Category->Name) . '</div>
     </li>';
         $Alt = FALSE;
     } else {
         $LastComment = UserBuilder($Category, 'Last');
         $AltCss = $Alt ? ' Alt' : '';
         $Alt = !$Alt;
         $CatList .= '<li id="Category_' . $CategoryID . '" class="' . $CssClass . '">
        <div class="ItemContent Category">' . '<div class="Options">' . getOptions($Category, $this) . '</div>' . CategoryPhoto($Category) . '<div class="TitleWrap">' . anchor(Gdn_Format::text($Category->Name), CategoryUrl($Category), 'Title') . '</div>
           <div class="CategoryDescription">' . $Category->Description . '</div>
           <div class="Meta">
              <span class="MItem RSS">' . anchor(img('applications/dashboard/design/images/rss.gif', array('alt' => T('RSS Feed'))), '/categories/' . $Category->UrlCode . '/feed.rss', '', array('title' => T('RSS Feed'))) . '</span>
              <span class="MItem DiscussionCount">' . sprintf(PluralTranslate($Category->CountDiscussions, '%s discussion html', '%s discussions html', t('%s discussion'), t('%s discussions')), BigPlural($Category->CountDiscussions, '%s discussion')) . '</span>
              <span class="MItem CommentCount">' . sprintf(PluralTranslate($Category->CountComments, '%s comment html', '%s comments html', t('%s comment'), t('%s comments')), BigPlural($Category->CountComments, '%s comment')) . '</span>';
         if ($Category->LastTitle != '') {
             $CatList .= '<span class="MItem LastDiscussionTitle">' . sprintf(t('Most recent: %1$s by %2$s'), anchor(Gdn_Format::text(sliceString($Category->LastTitle, 40)), $Category->LastUrl), userAnchor($LastComment)) . '</span>' . '<span class="MItem LastCommentDate">' . Gdn_Format::date($Category->LastDateInserted) . '</span>';
         }
         // If this category is one level above the max display depth, and it
         // has children, add a replacement string for them.
         if ($MaxDisplayDepth > 0 && $Category->Depth == $MaxDisplayDepth - 1 && $Category->TreeRight - $Category->TreeLeft > 1) {
             $CatList .= '{ChildCategories}';
         }
         $CatList .= '</div>
        </div>
开发者ID:R-J,项目名称:vanilla,代码行数:31,代码来源:all.php


示例11: get_ajax

 public function get_ajax($offset = 0)
 {
     $count = $this->m_places->get_place();
     $perpage = getOptions('paging');
     if (count($count) > $perpage) {
         $this->load->library('pagination');
         $config['base_url'] = site_url('admin/places/get_ajax');
         $config['total_rows'] = count($count);
         $config['per_page'] = $perpage;
         $config['uri_segment'] = 4;
         $q = $this->pagination->initialize($config);
         $offset = $this->uri->segment(4) ? $this->uri->segment(4) : 0;
     } else {
         $this->data['pagination'] = '';
         $offset = 0;
     }
     $telo = $this->m_places->get_place($perpage, $offset);
     $str = '';
     if ($telo) {
         $str .= '<table class="table table-bordered table-condensed"">
                     <thead>
                         <tr class="active">
                             <th class="text-center">Image</th>
                             <th class="text-center">Title</th>
                             <th class="text-center">Type</th>
                             <th class="text-center">Price</th>
                             <th class="text-center">Action</th>
                         </tr>
                     </thead>
                     <tbody>';
         foreach ($telo as $s) {
             $str .= '<tr class="text-center">';
             $str .= $s->image ? '<td class="col-md-1"><img src="' . base_url('assets/img/timthumb.php') . '?src=' . base_url($s->image) . '&zc=0&h=140&w=180"></td>' : '<td class="col-md-1"><img class="img-responsive" src="http://placehold.it/100x100&text=no+primary+image"></td>';
             $str .= '<td>' . $s->title_places . '</td>';
             $str .= '<td>' . ($s->title_type === null ? 'Not Set' : $s->title_type) . '</td>';
             $str .= '<td>' . ($s->prices === null ? 'Not Set' : $this->data['currency'][getOptions('currency')] . ' ' . currency($s->prices)) . '</td>';
             $str .= '<td><a href="' . site_url('admin/places/edit') . '/' . $s->id_places . '" class="btn btn-default">Edit</a>';
             $str .= '<a id="del-' . $s->id_places . '" href="' . site_url('admin/places/del_places') . '/' . $s->id_places . '" class="btn btn-default del-in">Delete</a></td>';
             $str .= '</tr>';
         }
         $str .= '<tbody></table>';
         $str .= '<div>' . $this->pagination->create_links() . '</div>';
     } else {
         $str .= 'No Data Found';
     }
     echo $str;
 }
开发者ID:JamesWuChina,项目名称:CI-Property,代码行数:47,代码来源:places.php


示例12: writeTableRow

    function writeTableRow($Row, $Depth = 1)
    {
        $Children = $Row['Children'];
        $WriteChildren = FALSE;
        $maxDisplayDepth = c('Vanilla.Categories.MaxDisplayDepth');
        if (!empty($Children)) {
            if ($maxDisplayDepth > 0 && $Depth + 1 >= $maxDisplayDepth) {
                $WriteChildren = 'list';
            } else {
                $WriteChildren = 'rows';
            }
        }
        $H = 'h' . ($Depth + 1);
        ?>
        <tr class="<?php 
        echo CssClass($Row);
        ?>
">
            <td class="CategoryName">
                <div class="Wrap">
                    <?php 
        echo '<div class="Options">' . getOptions($Row) . '</div>';
        echo CategoryPhoto($Row);
        echo "<{$H}>";
        $safeName = htmlspecialchars($Row['Name']);
        echo $Row['DisplayAs'] === 'Heading' ? $safeName : anchor($safeName, $Row['Url']);
        Gdn::controller()->EventArguments['Category'] = $Row;
        Gdn::controller()->fireEvent('AfterCategoryTitle');
        echo "</{$H}>";
        ?>
                    <div class="CategoryDescription">
                        <?php 
        echo $Row['Description'];
        ?>
                    </div>
                    <?php 
        if ($WriteChildren === 'list') {
            ?>
                        <div class="ChildCategories">
                            <?php 
            echo wrap(t('Child Categories') . ': ', 'b');
            echo CategoryString($Children, $Depth + 1);
            ?>
                        </div>
                    <?php 
        }
        ?>
                </div>
            </td>
            <td class="BigCount CountDiscussions">
                <div class="Wrap">
                    <?php 
        //            echo "({$Row['CountDiscussions']})";
        echo BigPlural($Row['CountAllDiscussions'], '%s discussion');
        ?>
                </div>
            </td>
            <td class="BigCount CountComments">
                <div class="Wrap">
                    <?php 
        //            echo "({$Row['CountComments']})";
        echo BigPlural($Row['CountAllComments'], '%s comment');
        ?>
                </div>
            </td>
            <td class="BlockColumn LatestPost">
                <div class="Block Wrap">
                    <?php 
        if ($Row['LastTitle']) {
            ?>
                        <?php 
            echo userPhoto($Row, array('Size' => 'Small', 'Px' => 'Last'));
            echo anchor(SliceString(Gdn_Format::text($Row['LastTitle']), 100), $Row['LastUrl'], 'BlockTitle LatestPostTitle', array('title' => html_entity_decode($Row['LastTitle'])));
            ?>
                        <div class="Meta">
                            <?php 
            echo userAnchor($Row, 'UserLink MItem', 'Last');
            ?>
                            <span class="Bullet">•</span>
                            <?php 
            echo anchor(Gdn_Format::date($Row['LastDateInserted'], 'html'), $Row['LastUrl'], 'CommentDate MItem');
            if (isset($Row['LastCategoryID'])) {
                $LastCategory = CategoryModel::categories($Row['LastCategoryID']);
                echo ' <span>', sprintf('in %s', anchor($LastCategory['Name'], CategoryUrl($LastCategory, '', '//'))), '</span>';
            }
            ?>
                        </div>
                    <?php 
        }
        ?>
                </div>
            </td>
        </tr>
        <?php 
        if ($WriteChildren === 'rows') {
            foreach ($Children as $ChildRow) {
                WriteTableRow($ChildRow, $Depth + 1);
            }
        }
    }
开发者ID:vanilla,项目名称:vanilla,代码行数:100,代码来源:helper_functions.php


示例13: stdClass

$name = $app->input->getString('e_name', '');
$form = 'text';
$html = '';
if (!$elem) {
    return;
}
$item = new stdClass();
$item->client = $elem == 'type' ? 'site' : 'search';
$item->id = JCckDatabase::loadResult('SELECT id FROM #__cck_core_' . $elem . 's WHERE name = "' . (string) $name . '"');
if (!$item->id) {
    return;
}
$live = $app->input->getString('live', '');
$variat = $app->input->getString('variat', '');
$values = getOptions($live);
$variations = getOptions($variat);
// Variations
$opts = array(JHtml::_('select.option', '', '- ' . JText::_('COM_CCK_INHERITED') . ' -'), JHtml::_('select.option', 'clear', JText::_('COM_CCK_CLEAR')), JHtml::_('select.option', 'hidden', JText::_('COM_CCK_HIDDEN')), JHtml::_('select.option', 'value', JText::_('COM_CCK_VALUE')), JHtml::_('select.option', '<OPTGROUP>', JText::_('COM_CCK_FORM')), JHtml::_('select.option', 'form', JText::_('COM_CCK_DEFAULT')), JHtml::_('select.option', 'form_filter', JText::_('COM_CCK_FORM_FILTER')), JHtml::_('select.option', 'disabled', JText::_('COM_CCK_FORM_DISABLED')), JHtml::_('select.option', '</OPTGROUP>', ''));
// Process
require_once JPATH_ADMINISTRATOR . '/components/' . CCK_COM . '/helpers/helper_workshop.php';
$fields = Helper_Workshop::getFields($elem, $item, 'AND (( c.live = "" AND c.live_value = "" ) OR ( c.live = "" AND c.live_value != "" AND c.variation != "hidden" ) OR ( c.live != "" AND c.live != "stage" ))', false, true);
if (count($fields)) {
    foreach ($fields as $pos) {
        foreach ($pos as $field) {
            $value = isset($values[$field->name]) ? htmlspecialchars($values[$field->name]) : '';
            $variat = isset($variations[$field->name]) ? $variations[$field->name] : '';
            $variat = $variat == 'none' ? $variat = 'hidden' : $variat;
            // TODO: FIX TO REMOVE AFTER GA
            $variation = Jhtml::_('select.genericlist', $opts, 'variation_' . $field->name, 'size="1" class="inputbox variation_values" onchange="CCK_setOptions(\'variation\');"', 'value', 'text', $variat);
            $html .= '<label style="padding-left: 10px;">' . $field->title . '</label>' . '<input class="live_values inputbox" type="text" id="live_' . $field->name . '" name="live_' . $field->name . '" value="' . $value . '" onchange="CCK_setOptions(\'live\');" />' . $variation . '<div class="clear"></div>';
        }
开发者ID:olafzieger,项目名称:joomla3.x-seblod-test,代码行数:31,代码来源:list_live.php


示例14: trim

            break;
        case 1:
            echo "Enter CSV File full path with name HERE: ";
            $file_name = trim(fgets(STDIN));
            // Input from user and save it in a variable
            $file_name = str_replace("\n", '', $file_name);
            // Remove extra Line Entery
            checkFile($file_name);
            //  Check whether FIle Exists or Not
            $option = getOptions();
            break;
        case 2:
            if (checkFile($file_name)) {
                echo "Processsing File here \n\n\n";
                //------------------- Start Processing File
                ProcessDataDigging($file_name);
            } else {
            }
            $option = getOptions();
            // General Options
            break;
        case 3:
            exit;
            break;
        default:
            $option = getOptions();
            // General Options
            break;
    }
}
//ProcessDataDigging();
开发者ID:eduify,项目名称:crawler,代码行数:31,代码来源:csv_system_illinois.php


示例15: get_category

function get_category($type, $option)
{
    return getOptions();
}
开发者ID:rodhoff,项目名称:MNW,代码行数:4,代码来源:shortcodes-func.php


示例16: getOptions

        case "persName":
        case "orgName":
        case "title":
        case "name":
        case "term":
            getOptions($label);
            break;
            //subtype from tei files and namedEntities.xml
        //subtype from tei files and namedEntities.xml
        case "present":
        case "expéditeur":
        case "destinataire":
        case "invité":
        case "secrétaire":
        case "président":
            getOptions("persName", $label);
            break;
        case "type":
            break;
    }
}
function array_msort($array, $cols)
{
    $colarr = array();
    foreach ($cols as $col => $order) {
        $colarr[$col] = array();
        foreach ($array as $k => $row) {
            $colarr[$col]['_' . $k] = strtolower($row[$col]);
        }
    }
    $eval = 'array_multisort(';
开发者ID:marcdouguet,项目名称:difdepo,代码行数:31,代码来源:options.php


示例17: login_init

/* 修改个人参数,从 wForum 偷来的。atppp 20040524 */
require "www2-funcs.php";
login_init();
bbs_session_modify_user_mode(BBS_MODE_USERDEF);
toolbox_header("个人参数修改");
assert_login();
define('SHOWTELNETPARAM', 0);
//是否显示 telnet 选项
/* 格式:每项五个参数,第一个 0 表示 telnet 下专用参数;第二个是参数名称;第三个是参数具体解释;第四五是参数 ON 和 OFF 所代表的具体含义 */
$user_define = array(array(0, "显示活动看版", "是否显示活动看板", "显示", "不显示"), array(0, "使用彩色", "是否使用彩色显示", "使用", "不使用"), array(0, "编辑时显示状态栏", "编辑文章时是否显示状态栏", "显示", "不显示"), array(0, "分类讨论区以 New 显示", "是否以未读方式阅读分类讨论区", "是", "否"), array(0, "选单的讯息栏", "是否显示选单讯息栏", "显示", "不显示"), array(0, "上站时显示好友名单", "上站时是否显示好友在线名单", "显示", "不显示"), array(0, "让好友呼叫", "当呼叫器关闭时是否允许好友呼叫", "是", "否"), array(0, "使用自己的离站画面", "是否使用自己的离站画面", "是", "否"), array(0, "进站时显示备忘录", "进站时是否显示备忘录", "是", "否"), array(0, "离站时显示备忘录", "离站时是否显示备忘录", "是", "否"), array(0, "讯息栏模式", "讯息栏的显示内容", "呼叫器状态", "在线人数"), array(0, "菜单模式选择", "telnet的菜单模式", "缺省模式", "精简模式"), array(0, "阅读文章是否使用绕卷选择", "阅读文章是否绕卷选择", "是", "否"), array(0, "阅读文章游标停於第一篇未读", "文章列表时光标自动定位的位置", "第一篇未读文章", "最新一篇文章"), array(0, "屏幕标题色彩", "屏幕标题色彩显示模式", "标准", "自动变换"), array(1, "接受所有人的讯息", "是否允许所有人给您发短消息", "是", "否"), array(1, "接受好友的讯息", "是否允许好友给您发短消息", "是", "否"), array(0, "收到讯息发出声音", "收到短信后是否以声音提醒您", "是", "否"), array(0, "离站後寄回所有讯息", "退出登录时是否把短信息寄回信箱", "是", "否"), array(0, "发文章时实时显示讯息", "编辑文章时是否实时显示短消息", "是", "否"), array(0, "菜单上显示帮助信息", "是否在菜单上显示帮助信息", "是", "否"), array(0, "进站时显示十大新闻", "进站时是否显示十大热门话题", "显示", "不显示"), array(0, "进站时观看留言版", "进站时是否显示留言板", "显示", "不显示"), array(0, "忽略讯息功能键", "用哪个键忽略短信", "Enter键", "Esc键"), array(0, "使用高亮界面", "是否使用高亮界面", "使用", "不使用"), array(0, "进站时观看上站人数统计图", "进站时是否显示上站人数统计图", "显示", "不显示"), array(0, "未读标记字符", "用哪个字符作为未读标记", "*", "N"), array(0, "使用GB码阅读", "用GB码阅读", "是", "否"), array(0, "对汉字进行整字处理", "是否对汉字进行整字处理", "是", "否"), array(0, "显示详细用户信息(wForum)", "是否允许他人看到您的用户资料", "允许", "不允许"), array(0, "显示真实用户信息(wForum)", "是否允许他人看到您的真实资料", "允许", "不允许"));
$user_define1 = array(array(1, "隐藏 IP", "是否隐藏自己的 IP 信息", "隐藏", "不隐藏"));
$mailbox_prop = array(array(1, "发信时保存信件到发件箱", "是否发信时自动选择保存到发件箱", "保存", "不保存"), array(1, "删除信件时不保存到垃圾箱", "是否删除信件时不保存到垃圾箱", "不保存", "保存"), array(0, "快捷邮箱键", "版面按 'v' 时进入什么界面", "信箱主界面", "收件箱"), array(1, "自动清除过期垃圾邮件", "是否自动清除过期垃圾邮件", "是", "否"));
if (isset($_GET['do'])) {
    $userdefine0 = getOptions("user_define", $currentuser['userdefine0']);
    $userdefine1 = getOptions("user_define1", $currentuser['userdefine1']);
    $mailbox_prop = getOptions("mailbox_prop", $currentuinfo['mailbox_prop']);
    bbs_setuserparam($userdefine0, $userdefine1, $mailbox_prop);
    html_success_quit("参数修改成功");
    exit;
}
showOptionsForm();
page_footer();
function getOptions($var_name, $oldvalue)
{
    global ${$var_name};
    $userdefine = ${$var_name};
    $ccc = count($userdefine);
    $flags = $oldvalue;
    for ($i = 0; $i < $ccc; $i++) {
        if (isset($_POST[$var_name . "_" . $i])) {
            if ($_POST[$var_name . "_" . $i] == 1) {
开发者ID:bianle,项目名称:www2,代码行数:31,代码来源:bbsparm.php


示例18: getopt

        if (!empty($option['long'])) {
            $long[] = $option['long'] . $req;
        }
        if (!empty($option['short']) && !empty($option['long'])) {
            $map[$option['short']] = $option['long'];
        }
    }
    $arguments = getopt($short, $long);
    foreach ($map as $s => $l) {
        if (isset($arguments[$s]) && isset($arguments[$l])) {
            unset($arguments[$s]);
            continue;
        }
        if (isset($arguments[$s])) {
            $arguments[$l] = $arguments[$s];
            unset($arguments[$s]);
            continue;
        }
    }
    return $arguments;
}
function out($message, $pre = '  ')
{
    echo "{$pre}{$message}\n";
}
/**
 * Script options
 */
$options = array(array('short' => 'i', 'long' => 'install-dir', 'desc' => 'Installation folder', 'required' => true));
exit(main(getOptions($options)));
开发者ID:hoborglabs,项目名称:dashboard,代码行数:30,代码来源:install.php


示例19: str_pad

    $res .= "<option value='{$ver}-r'>Release Notes</option>";
    $res .= "<option value='{$ver}-s'>Samples</option>";
    $res .= "</optgroup>";
    return $res;
}
for ($mj = $major; $mj >= 9; --$mj) {
    for ($mn = $minor; $mn >= 66; --$mn) {
        $minver = str_pad("{$mn}", 2, "0", STR_PAD_LEFT);
        $ver = "{$mj}.{$minver}";
        if ($ver == $currentVersion) {
            continue;
        }
        print getOptions($ver);
    }
}
print getOptions("8.91");
?>
</select>
<script type="text/javascript">
$(document).ready(function() {
   $("#verOper").change(function() {
       var v = $("#verOper option:selected").val();
       var ver = v.substr(0, 4);
       var oper = v.substr(5, 1);
       var site = window.location.protocol + "//" + window.location.hostname + "/";
       var link;
       switch (oper) {
       case 'd':
           link = "https://github.com/easylogging/easyloggingpp/releases/download/v" + ver + "/easyloggingpp_v" + ver + ".zip";
           break;
       case 'm':
开发者ID:rggjan,项目名称:homepage,代码行数:31,代码来源:version-operations.php


示例20: jsAnswer

if ($interval < 1) {
    // интервал отправки (сек)
    jsAnswer("error", "c_error", "", "Сообщение уже было отправлено.");
} else {
    //$get_data = gF('os');
    $get_data = $_POST["cs"];
    if (count($get_data) > 1) {
        // data to send
        $os = $_POST["os"];
        $cs = $_POST["cs"];
        $ip = $_SERVER["REMOTE_ADDR"];
        $title = "Новый клиент с сайта soapland";
        $title = "=?UTF-8?B?" . base64_encode($title) . "?=";
        $mess = "";
        $mess .= getOptions(1);
        $mess = $mess . "<div style=\"background:#bfd4ac;border:1px solid #999;padding:10px;margin: 10px 0;\">IP: " . $ip . " / <a href='http://dedushka.org/whois/#" . $ip . "'>Определить город</a></div>";
        $headers = "Content-type: text/html; charset=utf-8\r\n";
        $headers .= "From: soapland <" . $from . ">\r\n";
        $sms['msg'] = translit(getOptions(0));
        $sms['msg'] = substr($sms['msg'], 0, 160);
        if ($to != '[email protected]') {
            mail($to, $title, $mess, $headers);
        }
        if ($sms['id'] != '' || $sms['key'] != '' || $sms['log'] != '') {
            @sendSMS($num, $sms['msg']);
        }
        jsAnswer('success', 'c_success', '', 'Спасибо, мы свяжемся с Вами в течении 30 минут!');
    } else {
        jsAnswer('error', 'c_error', '', 'Ошибка');
    }
}
开发者ID:Xsorter,项目名称:xsorter.github.io,代码行数:31,代码来源:send.php



注:本文中的getOptions函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
PHP getOrder函数代码示例发布时间:2022-05-15
下一篇:
PHP getOption函数代码示例发布时间: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