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


PHP Language::DirectTranslateHtml方法代码示例

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


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

示例1: display

 public function display()
 {
     $form = new Form(2);
     $form->submit();
     $GLOBALS['editinglanguage'] = new Language($_GET['language']);
     $table = new Table();
     $token = new TableColumn("token", "Token");
     $translation = new TableFunctionColumn("token", Language::DirectTranslate("TRANSLATION"));
     $translation->functionName = "TranslationEditor_GetString";
     $translation->autoWidth = true;
     $languagetoken = new TableColumn("'" . DataBase::Current()->EscapeString($_GET['language']) . "' as language", "Language");
     $languagetoken->value = $_GET['language'];
     $languagetoken->visible = false;
     $table->columns->add($token);
     $table->columns->add($translation);
     $table->columns->add($languagetoken);
     $table->name = "{'dbprefix'}language_tokens";
     $table->actions = "translation_tokens";
     $table->orderBy = "token";
     $table->size = -1;
     $table->display();
     $newModule = Language::DirectTranslateHtml("NEW_MODULE");
     echo "<h2>" . $newModule . "</h2>";
     $form->display();
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:25,代码来源:translationeditor.php

示例2: display

 public function display()
 {
     $template = new Template();
     $template->load("plugins");
     $plugins = new PluginList();
     $plugins->loadAll();
     foreach ($plugins->plugins as $plugin) {
         $index = $template->add_loop_item("PLUGINS");
         if (isset($_GET['activate']) && $_GET['activate'] == $plugin->path) {
             $plugin->activate();
         } elseif (isset($_GET['deactivate']) && $_GET['deactivate'] == $plugin->path) {
             $plugin->deactivate();
         }
         $template->assign_loop_var("PLUGINS", $index, "NAME", htmlentities($plugin->name));
         $template->assign_loop_var("PLUGINS", $index, "PATH", htmlentities($plugin->path));
         $template->assign_loop_var("PLUGINS", $index, "DESCRIPTION", htmlentities($plugin->getDescription()));
         $template->assign_loop_var("PLUGINS", $index, "VERSION", $plugin->version);
         $template->assign_loop_var("PLUGINS", $index, "AUTHORLINK", $plugin->authorLink);
         $template->assign_loop_var("PLUGINS", $index, "AUTHORNAME", htmlentities($plugin->authorName));
         $template->assign_loop_var("PLUGINS", $index, "LICENSE", htmlentities($plugin->license));
         $template->assign_loop_var("PLUGINS", $index, "LICENSEURL", htmlentities($plugin->licenseUrl));
         if ($plugin->isActivated()) {
             $myurl = UrlRewriting::GetUrlByAlias($this->page->alias, "deactivate=" . urlencode($plugin->path));
             $disable = Language::DirectTranslateHtml("DISABLE");
             $template->assign_loop_var("PLUGINS", $index, "ACTIVATIONLINK", "<a href=\"" . $myurl . "\">" . $disable . "</a>");
         } else {
             $myurl = UrlRewriting::GetUrlByAlias($this->page->alias, "activate=" . urlencode($plugin->path));
             $enable = Language::DirectTranslateHtml("ENABLE");
             $template->assign_loop_var("PLUGINS", $index, "ACTIVATIONLINK", "<a href=\"" . $myurl . "\">" . $enable . "</a>");
         }
     }
     $template->assign_var("HOST", Settings::getValue("host"));
     $template->assign_var("APIKEY", Settings::getValue("apikey"));
     $template->output();
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:35,代码来源:pluginpage.php

示例3: __construct

 /**
  *
  * @param string $message
  * @param int $code 
  */
 public function __construct($message, $code = 0)
 {
     parent::__construct($message, $code);
     header("HTTP/1.0 404 Not Found");
     $page = new Page();
     $page->setEditor(new BlankEditor($page));
     $page->getEditor()->setContent("<h2>" . Language::DirectTranslateHtml("PAGE_NOT_FOUND") . "</h2><p>" . Language::DirectTranslateHtml("PAGE_NOT_FOUND_LONG") . "!</p>");
     parent::setErrorPage($page);
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:14,代码来源:filenotfoundexception.php

示例4: getHeaderCode

 /**
  *
  * @return string 
  */
 public function getHeaderCode()
 {
     $res = "<thead><tr>";
     foreach ($this->columns as $column) {
         $res .= $column->getHeaderCode();
     }
     if (strlen($this->actions) > 0) {
         $actions = Language::DirectTranslateHtml("ACTIONS");
         $res .= "<td><strong>" . $actions . "</strong></td>";
     }
     $res .= "</tr></thead>";
     return $res;
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:17,代码来源:tablecolumnlist.php

示例5: display

 public function display()
 {
     if (isset($_POST['create'])) {
         $share = new DataTypeShare();
         $share->SetApiKey($_POST['apikey']);
         $share->SetDataType(new DataType($_GET['datatype']));
         $share->SetName($_POST['name']);
         $share->Insert();
         echo "Die Freigabe wurde erteilt.";
     } else {
         echo "<form method=\"POST\">\n                      <table>\n                          <tr>\n                              <td>Name:</td>\n                              <td><input name=\"name\" /></td>\n                          </tr>\n                          <tr>\n                              <td>API-Key:</td>\n                              <td><input name=\"apikey\" /></td>\n                          </tr>\n                      </table>\n                      <input name=\"create\" type=\"submit\" value=\"" . Language::DirectTranslateHtml("CREATE") . "\" />\n                  </form>";
     }
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:13,代码来源:datasharingpage.php

示例6: display

 public function display()
 {
     $userlist = new Template();
     $userlist->load("user_list");
     $userlist->assign_var("URL", $this->page->GetUrl());
     if (isset($_POST['insert'])) {
         $user = new User();
         $user->name = $_POST['name'];
         $user->role = $_POST['new_user_role'];
         $user->email = $_POST['email'];
         if (!$user->insert($_POST['password'])) {
             $userlist->assign_var("MSG", Language::DirectTranslateHtml("USER_NOT_CREATED"));
         }
     }
     if (isset($_GET['delete'])) {
         $user = new User();
         $user->id = $_GET['delete'];
         if (!$user->delete()) {
             $userlist->assign_var("MSG", Language::DirectTranslateHtml("USER_NOT_DELETED"));
         }
     }
     $userlist->assign_var("MSG", "");
     Cache::clear("tables", "userlist");
     $table = new Table();
     $id = new TableColumn("id", Language::DirectTranslate("ID"));
     $id->autoWidth = true;
     $name = new TableColumn("name", Language::DirectTranslate("NAME"));
     $role = new TableColumn("role", Language::DirectTranslate("ROLE"), "IFNULL((SELECT name FROM {'dbprefix'}roles WHERE id = {'dbprefix'}user.role),'')");
     $email = new TableColumn("email", Language::DirectTranslate("EMAIL"));
     $created = new TableColumn("create_timestamp", Language::DirectTranslate("CREATED_ON"));
     $created->autoWidth = true;
     $access = new TableColumn("last_access_timestamp", Language::DirectTranslate("LAST_ACCESS"));
     $access->autoWidth = true;
     $table->columns->add($id);
     $table->columns->add($name);
     $table->columns->add($role);
     $table->columns->add($email);
     $table->columns->add($created);
     $table->columns->add($access);
     $table->name = "{'dbprefix'}user";
     $table->actions = "userlist";
     $table->orderBy = "name";
     $table->cacheName = "userlist";
     $userlist->assign_var("TABLE", $table->getCode());
     $roles = new RoleSelector();
     $roles->hideSpecialRoles = true;
     $roles->name = "new_user_role";
     $userlist->assign_var("ROLES", $roles->getCode());
     $userlist->output();
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:50,代码来源:userlist.php

示例7: getEditableCode

 /**
  *
  * @return string
  */
 public function getEditableCode()
 {
     $selected_301 = "";
     $selected_302 = "";
     if ($this->data['type'] == 301) {
         $selected_301 = " selected=\"selected\"";
     }
     if ($this->data['type'] == 302) {
         $selected_302 = " selected=\"selected\"";
     }
     $res = "\n            <table style=\"width:80%\">\n                <tr>\n                    <td style=\"width:100px\">" . Language::DirectTranslateHtml("TYPE") . ":</td>\n                    <td>\n                        <select name=\"redirect_type\">\n                            <option value=\"301\"" . $selected_301 . ">301 - " . Language::DirectTranslateHtml("MOVED_PERMANENTLY") . "</option>\n                            <option value=\"302\"" . $selected_302 . ">302 - " . Language::DirectTranslateHtml("MOVED_TEMPORARY") . "</option>\n                        </select>\n                    </td>\n                </tr>\n                <tr>\n                    <td>Ziel:</td>\n                    <td>\n                        <input type=\"url\" name=\"redirect_location\" style=\"width:80%\" value=\"" . $this->data['location'] . "\" />\n                    </td>\n                </tr>\n            </table>";
     $change = htmlentities(Language::GetGlobal()->getString("CHANGE"));
     return $res . "<input name=\"save\" type=\"submit\" value=\"" . $change . "\" target='_self' ; return true\" />";
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:18,代码来源:redirectpage.php

示例8: display

 public function display()
 {
     $template = new Template();
     $template->load("message");
     if (ImageServer::insert($_POST['path'], $_POST['name'], $_POST['description'])) {
         $template->assign_var("MESSAGE", Language::DirectTranslateHtml("IMAGE_ADDED"));
         $redirect = UrlRewriting::GetUrlByAlias("admin/home", "dir=" . urlencode($_SESSION['dir']));
         if (isset($_POST['referrer'])) {
             $redirect = $_POST['referrer'];
         }
         echo "<script type='text/javascript'>setTimeout('window.location.href= \\'" . $redirect . "\\'', 1000)</script>";
     } else {
         $template->assign_var("MESSAGE", Language::DirectTranslateHtml("IMAGE_NOT_ADDED"));
     }
     $template->output();
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:16,代码来源:addimagepage.php

示例9: display

 public function display()
 {
     $form = new Form(1);
     $form->submit();
     $table = new Table();
     $token = new TableColumn("token", "Token");
     $token->autoWidth = true;
     $name = new TableColumn("name", Language::DirectTranslate("NAME"));
     $table->columns->add($token);
     $table->columns->add($name);
     $table->name = "{'dbprefix'}languages";
     $table->actions = "translations";
     $table->orderBy = "name";
     $table->display();
     $newTranslation = Language::DirectTranslateHtml("NEW_TRANSLATION");
     echo "<h2>" . $newTranslation . "</h2>";
     $form->display();
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:18,代码来源:translationpage.php

示例10: display

    public function display()
    {
        $contentpath = Settings::getInstance()->get("root") . "content/articles/" . $_SESSION['dir'] . "/";
        if (isset($_POST['name'])) {
            if (FileServer::IsValidFoldername($_POST['name'])) {
                FileServer::createFolder($contentpath, $_POST['name']);
                ?>
            <script language="JavaScript"><!--
                window.location.href="<?php 
                echo UrlRewriting::GetUrlByAlias("admin/home", "dir=" . $_SESSION['dir'] . "/" . $_POST['name']);
                ?>
";
            // --></script> 
            <?php 
            } else {
                echo Language::DirectTranslateHtml("INVALID_FOLDERNAME");
            }
        }
        $template = new Template();
        $template->load("new_folder");
        $template->output();
    }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:22,代码来源:newfolderpage.php

示例11: display

    public function display()
    {
        ?>
            <h2><?php 
        echo Language::DirectTranslateHtml("SIGN_UP");
        ?>
</h2>
        <?php 
        if (User::Current()->isGuest()) {
            ?>
            <form action="<?php 
            echo $_SERVER['REQUEST_URI'];
            ?>
" method="POST">
                <table>
                    <tr>
                        <td><?php 
            Language::DirectTranslateHtml("USERNAME");
            ?>
:</td>
                        <td><input name="name" /></td>
                    </tr>
                    <tr>
                        <td><?php 
            Language::DirectTranslateHtml("EMAIL");
            ?>
:</td>
                        <td> <input name="email" /></td>
                    </tr>
                </table>
                <input type="submit" value="<?php 
            echo Language::DirectTranslateHtml("SIGN_UP");
            ?>
" />
            </form>
            <?php 
        }
    }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:38,代码来源:register.php

示例12: getEditableCode

 /**
  *
  * @return string 
  */
 public function getEditableCode()
 {
     $change = Language::DirectTranslateHtml("CHANGE");
     return "<input name=\"save\" type=\"submit\" value=\"" . $change . "\" onclick=\"form.action='" . $_SERVER['PHP_SELF'] . "?" . $_SERVER['QUERY_STRING'] . "' ; target='_self' ; return true\" />";
 }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:9,代码来源:datacenter.php

示例13: display

    public function display()
    {
        if (isset($_POST['plugin_submit'])) {
            $to = "support@contentlion.org";
            $subject = "Neues Plugin! " . Settings::getValue("apikey");
            $message = print_r($_POST, true);
            $headers = "From:" . $_POST['email'];
            if (@mail($to, $subject, $message, $headers)) {
                echo "<p>" . Language::DirectTranslateHtml("_PLUGIN_SUBMITTED") . "</p>";
            } else {
                echo "<p>" . Language::DirectTranslate("_PLUGIN_NOT_SUBMITTED") . "</p>";
            }
        } else {
            echo Language::DirectTranslate("SUBMIT_PLUGIN_PLEASE");
            ?>
            <form method="POST">
                <table>
                    <tr>
                        <td><?php 
            echo Language::DirectTranslateHtml("COMPANY_OPTIONAL");
            ?>
:</td>
                        <td><input name="company" /></td>
                    </tr>
                    <tr>
                        <td><?php 
            echo Language::DirectTranslateHtml("FIRSTNAME");
            ?>
:</td>
                        <td><input name="firstname" /></td>
                    </tr>
                    <tr>
                        <td><?php 
            echo Language::DirectTranslateHtml("LASTNAME");
            ?>
:</td>
                        <td><input name="lastname" /></td>
                    </tr>
                    <tr>
                        <td><?php 
            echo Language::DirectTranslateHtml("EMAIL_ADDRESS");
            ?>
:</td>
                        <td><input name="email" /></td>
                    </tr>
                    <tr>
                        <td><?php 
            echo Language::DirectTranslateHtml("URL_OF_ZIP");
            ?>
:</td>
                        <td><input type="url" name="zip" /></td>
                    </tr>
                    <tr>
                        <td><?php 
            echo Language::DirectTranslateHtml("COMMENT");
            ?>
</td>
                        <td>
                            <textarea name="comment"></textarea>
                            
                        </td>
                    </tr>
                </table>
                <input name="plugin_submit" type="submit" value="<?php 
            echo Language::DirectTranslateHtml("SUBMIT_PLUGIN");
            ?>
" />
            </form>

          <?php 
        }
    }
开发者ID:srueegger,项目名称:1zu12bB,代码行数:72,代码来源:pluginsubmitpage.php


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