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


PHP Rank::create方法代碼示例

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


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

示例1: unlink

 if (file_exists(DB_NAME)) {
     unlink(DB_NAME);
 }
 //Instanciation des managers d'entités
 $user = new User();
 $configuration = new Configuration();
 $right = new Right();
 $rank = new Rank();
 $section = new Section();
 $event = new Event();
 $client = new Client();
 //Création des tables SQL
 $configuration->create();
 $user->create();
 $right->create();
 $rank->create();
 $section->create();
 $event->create();
 $client->create();
 $configuration->put('UPDATE_URL', 'http://update.idleman.fr/yana?callback=?');
 $configuration->put('DEFAULT_THEME', 'default');
 $configuration->put('COOKIE_NAME', 'yana');
 $configuration->put('COOKIE_LIFETIME', '7');
 $configuration->put('VOCAL_ENTITY_NAME', 'YANA');
 $configuration->put('PROGRAM_VERSION', '3.0.6');
 $configuration->put('HOME_PAGE', 'index.php');
 $configuration->put('VOCAL_SENSITIVITY', '0.0');
 //Création du rang admin
 $rank = new Rank();
 $rank->setLabel('admin');
 $rank->save();
開發者ID:thib3113,項目名稱:yana-server,代碼行數:31,代碼來源:install.php

示例2: run

 public function run()
 {
     DB::table('ranks')->delete();
     Rank::create(array('caca' => 1, 'corazon' => 0, 'idPerfil' => 1, 'idAlias' => 1));
     Rank::create(array('caca' => 0, 'corazon' => 1, 'idPerfil' => 1, 'idAlias' => 1));
 }
開發者ID:Arvumti,項目名稱:unmask_ultimo,代碼行數:6,代碼來源:DatabaseSeeder.php

示例3: extract

                </tr>
                <tr>
                    <td colspan="2">
                        <button id="create" name="create" class="btn btn-primary" type="button" onclick="createRank()">Create</button>
                    </td>
                </tr>
            </table>
        </form>
        <div id="loading" class="alert alert-info" role="alert" style="display: none">

        </div>
        <?php 
            } else {
                if ($do == 'create') {
                    extract($_POST);
                    Rank::create($name, $division, $abbrev, $paygrade);
                    Event::addEvent('Rank ' . $name . ' has been created.', $_SESSION['user'], 1);
                }
            }
        } else {
            if ($action == 'delete') {
                if ($do == 'none') {
                    ?>
        <a onclick="load('ranks', 'delete', 'delete', {id: '<?php 
                    echo $_GET['id'];
                    ?>
'})">Continue?</a> (<b>NOTE:</b> This action cannot be reversed!)
        <?php 
                } else {
                    if ($do == 'delete') {
                        $ranks = new Rank($_GET['id']);
開發者ID:Keshaun1222,項目名稱:IRIN,代碼行數:31,代碼來源:ranks.php


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