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


PHP Assets_View::render方法代码示例

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


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

示例1: page_access_level

function page_access_level($level)
{
    $session_logic = Session_Logic::getInstance();
    if ($level > $session_logic->currentLevel()) {
        $header = new Assets_Header("Privileges");
        $header->setLogin();
        $header->run();
        $view = new Assets_View(__FILE__);
        $view->render("privileges.php");
        Assets_Page::footer();
        die;
    }
}
开发者ID:alerque,项目名称:bibledit,代码行数:13,代码来源:bootstrap.php

示例2:

        echo "{$key}\n";
    }
    die;
}
@($id = $_GET['id']);
if (isset($id)) {
    // Get the and passage for this identifier.
    $passage = Filter_Books::integer2passage($id);
    $book = $passage[0];
    $chapter = $passage[1];
    $verse = $passage[2];
    // Get the plain text.
    $text = $database_search->getBibleVerseText($bible, $book, $chapter, $verse);
    // Format it.
    $link = Filter_Books::linkForOpeningEditorAt($book, $chapter, $verse);
    $output = "<div>{$link} {$text}</div>";
    // Output to browser.
    echo $output;
    // Done.
    die;
}
$header = new Assets_Header(Locale_Translate::_("Search"));
$header->run();
$view = new Assets_View(__FILE__);
$view->view->bible = $bible;
$script = <<<EOD
var searchBible = "{$bible}";
EOD;
$view->view->script = $script;
$view->render("originals.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:31,代码来源:originals.php

示例3:

<?php

/*
Copyright (©) 2003-2014 Teus Benschop.

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once "../bootstrap/bootstrap.php";
page_access_level(Filter_Roles::GUEST_LEVEL);
Assets_Page::header(Locale_Translate::_("Navigation"));
$view = new Assets_View(__FILE__);
$view->render("navigation.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:25,代码来源:navigation.php

示例4: explode

$database_bibles = Database_Bibles::getInstance();
$bible = Access_Bible::clamp($_GET['bible']);
$view->view->bible = Filter_Html::sanitize($bible);
@($reset = $_GET["reset"]);
if (isset($reset)) {
    $database_config_bible->setBookOrder($bible, "");
}
@($order = $_POST['order']);
if (isset($order)) {
    $order = explode(",", $order);
    $ids = array();
    foreach ($order as $english) {
        $id = $database_books->getIdFromEnglish($english);
        $ids[] = $id;
    }
    $order = implode(" ", $ids);
    $database_config_bible->setBookOrder($bible, $order);
    die;
}
$script = <<<EOD
var orderBible = '{$bible}';
EOD;
$view->view->script = $script;
$names = array();
$books = Filter_Books::getOrdered($bible);
foreach ($books as $book) {
    $names[] = $database_books->getEnglishFromId($book);
}
$view->view->names = $names;
$view->render("order.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:31,代码来源:order.php

示例5: array

Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once "../bootstrap/bootstrap.php";
page_access_level(Filter_Roles::MANAGER_LEVEL);
Assets_Page::header(Locale_Translate::_("Changes"));
$view = new Assets_View(__FILE__);
$database_modifications = Database_Modifications::getInstance();
$config_general = Database_Config_General::getInstance();
$database_logs = Database_Logs::getInstance();
@($clear = $_GET['clear']);
if (isset($clear)) {
    // Just in case there are many change notifications to clear, be sure the script does not time out or abort.
    ignore_user_abort(true);
    set_time_limit(0);
    $database_modifications->clearNotificationsUser($clear);
}
$users = Access_User::assignees();
$pendingUsers = array();
$pendingCount = array();
foreach ($users as $user) {
    $ids = $database_modifications->getNotificationIdentifiers($user);
    $count = count($ids);
    if ($count > 0) {
        $pendingUsers[] = $user;
        $pendingCount[] = $count;
    }
}
$view->view->users = $pendingUsers;
$view->view->count = $pendingCount;
$view->render("manage.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:31,代码来源:manage.php

示例6:

<?php

/*
Copyright (©) 2003-2014 Teus Benschop.

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once "../bootstrap/bootstrap.php";
page_access_level(Filter_Roles::MANAGER_LEVEL);
Assets_Page::header(Locale_Translate::_("Import"));
$file = $_GET['file'];
$folder = Filter_Archive::uncompress($file, true);
$view = new Assets_View(__FILE__);
$view->view->folder = $folder;
$view->render("import3.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:28,代码来源:import3.php

示例7: catch

    $config_general->setMailSendSecurity($sendsecurity);
    $config_general->setMailSendPort($sendport);
    @($send_success .= " " . Locale_Translate::_("The details were saved."));
    try {
        $mail = new Mail_Send($config_general->getSiteMailAddress(), $config_general->getSiteMailName(), "Test", "This is to try out whether Bibledit-Web can send email.");
        $send_success .= " " . Locale_Translate::_("For the purpose of trying whether Bibledit-Web can send email, a test email was sent out to the account above:") . " " . $config_general->getSiteMailAddress();
    } catch (Exception $e) {
        $send_error .= " " . $e->getMessage();
    }
    @($view->view->send_success = $send_success);
    @($view->view->send_error = $send_error);
}
/**
* Normal page display.
*/
$config_general = Database_Config_General::getInstance();
$view->view->sitename = $config_general->getSiteMailName();
$view->view->sitemail = $config_general->getSiteMailAddress();
$view->view->storagehost = $config_general->getMailStorageHost();
$view->view->storageusername = $config_general->getMailStorageUsername();
$view->view->storagepassword = $config_general->getMailStoragePassword();
$view->view->storagesecurity = $config_general->getMailStorageSecurity();
$view->view->storageport = $config_general->getMailStoragePort();
$view->view->sendhost = $config_general->getMailSendHost();
$view->view->sendauthentication = $config_general->getMailSendAuthentication();
$view->view->sendusername = $config_general->getMailSendUsername();
$view->view->sendpassword = $config_general->getMailSendPassword();
$view->view->sendsecurity = $config_general->getMailSendSecurity();
$view->view->sendport = $config_general->getMailSendPort();
$view->render("mail.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:31,代码来源:mail.php

示例8: footer

 public static function footer()
 {
     $view = new Assets_View(__FILE__);
     $view->render('footer.php');
     $view->render('xhtml_finish.php');
 }
开发者ID:alerque,项目名称:bibledit,代码行数:6,代码来源:page.php

示例9:

<?php

/*
Copyright (©) 2003-2014 Teus Benschop.

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once "../bootstrap/bootstrap.php";
page_access_level(Filter_Roles::MANAGER_LEVEL);
$database_notes = Database_Notes::getInstance();
$header = new Assets_Header(Locale_Translate::_("Notes status"));
$header->run();
$view = new Assets_View(__FILE__);
$statuses = $database_notes->getPossibleStatuses();
$view->view->statuses = $statuses;
$view->render("status-n.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:29,代码来源:status-n.php

示例10: array

$object = $_GET['object'];
$view->view->object = $object;
$database_config_bible = Database_Config_Bible::getInstance();
$url = $database_config_bible->getRemoteRepositoryUrl($object);
$view->view->url = $url;
$ready = false;
$database_shell = Database_Shell::getInstance();
$output = "";
$contents = array();
switch ($database_shell->logic("collaboration_take_repo", 0, $output)) {
    case 1:
        $workingdirectory = dirname(__FILE__);
        $object = escapeshellarg($object);
        shell_exec("cd {$workingdirectory}; php collaboration_take_repo-cli.php {$object} > {$output} 2>&1 &");
        break;
    case 0:
        $contents = file($output, FILE_IGNORE_NEW_LINES);
        break;
    case -1:
        $contents = file($output, FILE_IGNORE_NEW_LINES);
        $ready = true;
        break;
}
$view->view->contents = $contents;
Assets_Page::header(Locale_Translate::_("Collaboration"));
// Display the page(s).
$view->render("collaboration_take_repo1.php");
if ($ready) {
    $view->render("collaboration_take_repo2.php");
}
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:31,代码来源:collaboration_take_repo.php

示例11: array

$view->view->bibles = $bibles;
$view->view->oldTexts = $oldTexts;
$view->view->modifications = $modifications;
$view->view->newTexts = $newTexts;
// Data for going back and forward in the pager.
$back = $start;
if ($back > 0) {
    $back -= 50;
}
if ($back < 0) {
    $back = 0;
}
$forward = $start + 50;
$view->view->back = http_build_query(array_merge($state, array('start' => $back)));
$view->view->forward = http_build_query(array_merge($state, array('start' => $forward)));
// Data for the passage filter.
$view->view->bible = http_build_query(array_merge($state, array('passage' => 0)));
$view->view->book = http_build_query(array_merge($state, array('passage' => 1)));
$view->view->chapter = http_build_query(array_merge($state, array('passage' => 2)));
$view->view->verse = http_build_query(array_merge($state, array('passage' => 3)));
// Data for the author filter.
$author_names = $database_history->authors($myBibles);
array_unshift($author_names, Locale_Translate::_("everybody"));
$view->view->author_names = $author_names;
$author_queries = array();
foreach ($author_names as $offset => $dummy) {
    $author_queries[] = http_build_query(array_merge($state, array('author' => $offset)));
}
$view->view->author_queries = $author_queries;
$view->render("history.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:31,代码来源:history.php

示例12: array

$timestamps = array();
foreach ($notes as $note) {
    $timestap = $database_notes->getModified($note);
    $timestamps[] = $timestap;
}
array_multisort($timestamps, SORT_DESC, $notes);
// Details for the notes.
$summaries = array();
$subscriptions = array();
$assignments = array();
foreach ($notes as $note) {
    $summary = $database_notes->getSummary($note);
    $summary = Filter_Html::sanitize($summary);
    $summaries[] = $summary;
    $subscriptions[] = $database_notes->isSubscribed($note, $username);
    $assignments[] = $database_notes->isAssigned($note, $username);
}
$view->view->notes = $notes;
$view->view->summaries = $summaries;
$view->view->subscriptions = $subscriptions;
$view->view->assignments = $assignments;
// Time stamp.
$timestamp = $database_modifications->getNotificationTimeStamp($id);
$timestamp = date('j F Y', $timestamp);
$view->view->timestamp = $timestamp;
// Whether there's a live notes editor available.
$live_notes_editor = $ipc_notes->alive();
$view->view->live_notes_editor = $live_notes_editor;
// Display page.
$view->render("change.php");
开发者ID:alerque,项目名称:bibledit,代码行数:30,代码来源:change.php

示例13:

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once "../bootstrap/bootstrap.php";
page_access_level(Filter_Roles::CONSULTANT_LEVEL);
$database_notes = Database_Notes::getInstance();
$notes_logic = Notes_Logic::getInstance();
$id = $_GET['id'];
if (isset($_POST['submit'])) {
    $summary = $_POST['entry'];
    $notes_logic->setSummary($id, $summary);
    Filter_Url::redirect("note.php?id={$id}");
    die;
}
$header = new Assets_Header(Locale_Translate::_("Note summary"));
$header->setBodyOnload('document.form.entry.focus();');
$header->run();
$view = new Assets_View(__FILE__);
$view->view->id = $id;
$summary = $database_notes->getSummary($id);
$summary = Filter_Html::sanitize($summary);
$view->view->summary = $summary;
$view->render("summary.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:30,代码来源:summary.php

示例14:

GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once "../bootstrap/bootstrap.php";
page_access_level(Filter_Roles::MANAGER_LEVEL);
Assets_Page::header(Locale_Translate::_("Verse mappings"));
$view = new Assets_View(__FILE__);
$database_mappings = Database_Mappings::getInstance();
$session_logic = Session_Logic::getInstance();
$username = $session_logic->currentUser();
$userlevel = $session_logic->currentLevel();
$name = $_GET['name'];
$view->view->name = Filter_Html::sanitize($name);
//$write = $database_styles->hasWriteAccess ($username, $name);
$write = true;
if ($userlevel >= Filter_Roles::ADMIN_LEVEL) {
    $write = true;
}
if (isset($_POST['submit'])) {
    $data = $_POST['data'];
    if ($write) {
        $database_mappings->import($name, $data);
    }
}
$data = $database_mappings->export($name);
$view->view->data = $data;
$view->render("map.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:31,代码来源:map.php

示例15:

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
require_once "../bootstrap/bootstrap.php";
page_access_level(Filter_Roles::ADMIN_LEVEL);
$database_resources = Database_Resources::getInstance();
$database_offlineresources = Database_OfflineResources::getInstance();
@($add = $_POST['entry']);
if (isset($add)) {
    $database_resources->save($add, '<?php $output = "dummy"; ?>');
}
@($delete = $_GET['delete']);
if (isset($delete)) {
    // User cannot delete Resources in an open demo.
    include "config/open.php";
    if (!$open_installation) {
        $database_resources->delete($delete);
        $database_offlineresources->delete($delete);
    }
}
$database_resources = Database_Resources::getInstance();
$header = new Assets_Header(Locale_Translate::_("Resources"));
$header->jQueryUIOn("dialog");
$header->run();
$view = new Assets_View(__FILE__);
$resources = $database_resources->getNames();
$view->view->resources = $resources;
$view->render("admin.php");
Assets_Page::footer();
开发者ID:alerque,项目名称:bibledit,代码行数:30,代码来源:admin.php


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