本文整理汇总了PHP中UI::find_template方法的典型用法代码示例。如果您正苦于以下问题:PHP UI::find_template方法的具体用法?PHP UI::find_template怎么用?PHP UI::find_template使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UI
的用法示例。
在下文中一共展示了UI::find_template方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: display_home
/**
* display_home
* This display the module in home page
*/
public function display_home()
{
if (AmpConfig::get('sociable')) {
echo "<div id='shout_objects'>\n";
$shouts = Shoutbox::get_top($this->maxitems);
if (count($shouts)) {
require_once AmpConfig::get('prefix') . UI::find_template('show_shoutbox.inc.php');
}
echo "</div>\n";
}
}
示例2: Stream_Playlist
?>
</title>
<meta property="og:title" content="<?php
echo AmpConfig::get('site_title');
?>
" />
<meta property="og:image" content="<?php
echo AmpConfig::get('web_path');
?>
/themes/reborn/images/ampache.png"/>
<meta property="og:description" content="A web based audio/video streaming application and file manager allowing you to access your music & videos from anywhere, using almost any internet enabled device." />
<meta property="og:site_name" content="Ampache"/>
<?php
if (!$is_share) {
$playlist = new Stream_Playlist(scrub_in($_REQUEST['playlist_id']));
}
$isRadio = false;
$isVideo = false;
$radio = null;
if (isset($playlist)) {
if (WebPlayer::is_playlist_radio($playlist)) {
// Special stuff for web radio (to better handle Icecast/Shoutcast metadata ...)
// No special stuff for now
$isRadio = true;
$radio = $playlist->urls[0];
} else {
$isVideo = WebPlayer::is_playlist_video($playlist);
}
}
require_once AmpConfig::get('prefix') . UI::find_template('show_html5_player.inc.php');
示例3: ini_set
if (ini_get($ini_default_charset)) {
ini_set($ini_default_charset, "UTF-8");
}
mb_language("uni");
}
$mailer = new Mailer();
// Set the vars on the object
$mailer->subject = $_REQUEST['subject'];
$mailer->message = $_REQUEST['message'];
if ($_REQUEST['from'] == 'system') {
$mailer->set_default_sender();
} else {
$mailer->sender = $GLOBALS['user']->email;
$mailer->sender_name = $GLOBALS['user']->fullname;
}
if ($mailer->send_to_group($_REQUEST['to'])) {
$title = T_('E-mail Sent');
$body = T_('Your E-mail was successfully sent.');
} else {
$title = T_('E-mail Not Sent');
$body = T_('Your E-mail was not sent.');
}
$url = AmpConfig::get('web_path') . '/admin/mail.php';
show_confirmation($title, $body, $url);
break;
default:
require_once AmpConfig::get('prefix') . UI::find_template('show_mail_users.inc.php');
break;
}
// end switch
UI::show_footer();
示例4: foreach
</th>
</tr>
</thead>
<tbody>
<?php
foreach ($concerts as $libitem) {
?>
<tr id="concert_<?php
echo $libitem->id;
?>
" class="<?php
echo UI::flip_class();
?>
">
<?php
require AmpConfig::get('prefix') . UI::find_template('show_concert_row.inc.php');
?>
</tr>
<?php
}
?>
<?php
if (!$concerts || !count($concerts)) {
?>
<tr class="<?php
echo UI::flip_class();
?>
">
<td colspan="<?php
echo $thcount;
?>
示例5:
?>
" type="text/css" />
<?php
} else {
?>
<link rel="stylesheet" href="<?php
echo AmpConfig::get('web_path') . UI::find_template('jplayer.midnight.black.css');
?>
" type="text/css" />
<?php
}
if (!$iframed) {
require_once AmpConfig::get('prefix') . UI::find_template('stylesheets.inc.php');
?>
<link rel="stylesheet" href="<?php
echo AmpConfig::get('web_path') . UI::find_template('jquery-editdialog.css');
?>
" type="text/css" media="screen" />
<link rel="stylesheet" href="<?php
echo AmpConfig::get('web_path');
?>
/modules/jquery-ui-ampache/jquery-ui.min.css" type="text/css" media="screen" />
<script src="<?php
echo AmpConfig::get('web_path');
?>
/lib/components/jquery/jquery.min.js" language="javascript" type="text/javascript"></script>
<script src="<?php
echo AmpConfig::get('web_path');
?>
/lib/components/jquery-ui/jquery-ui.min.js" language="javascript" type="text/javascript"></script>
<script src="<?php
示例6: foreach
</th>
</tr>
</thead>
<tbody>
<?php
foreach ($object_ids as $wanted_id) {
$libitem = new Wanted($wanted_id);
$libitem->format();
?>
<tr id="walbum_<?php
echo $libitem->mbid;
?>
" class="<?php
echo UI::flip_class();
?>
">
<?php
require AmpConfig::get('prefix') . UI::find_template('show_wanted_album_row.inc.php');
?>
</tr>
<?php
}
?>
</tbody>
</table>
<script src="<?php
echo AmpConfig::get('web_path');
?>
/lib/javascript/tabledata.js" language="javascript" type="text/javascript"></script>
<?php
UI::show_box_bottom();
示例7:
}
}
UI::show_footer();
exit;
case 'create':
if (AmpConfig::get('demo_mode')) {
UI::access_denied();
exit;
}
if (!Core::form_verify('add_channel', 'post')) {
UI::access_denied();
exit;
}
$created = Channel::create($_REQUEST['name'], $_REQUEST['description'], $_REQUEST['url'], $_REQUEST['type'], $_REQUEST['id'], $_REQUEST['interface'], $_REQUEST['port'], $_REQUEST['admin_password'], $_REQUEST['private'] ?: 0, $_REQUEST['max_listeners'], $_REQUEST['random'] ?: 0, $_REQUEST['loop'] ?: 0, $_REQUEST['stream_type'], $_REQUEST['bitrate']);
if (!$created) {
require_once AmpConfig::get('prefix') . UI::find_template('show_add_channel.inc.php');
} else {
$title = T_('Channel Created');
show_confirmation($title, $body, AmpConfig::get('web_path') . '/browse.php?action=channel');
}
UI::show_footer();
exit;
case 'show_delete':
$id = $_REQUEST['id'];
$next_url = AmpConfig::get('web_path') . '/channel.php?action=delete&id=' . scrub_out($id);
show_confirmation(T_('Channel Delete'), T_('Confirm Deletion Request'), $next_url, 1, 'delete_channel');
UI::show_footer();
exit;
case 'delete':
if (AmpConfig::get('demo_mode')) {
UI::access_denied();
示例8: xoutput_from_array
echo xoutput_from_array(array('rfc3514' => '0x1'));
exit;
}
switch ($_REQUEST['action']) {
case 'show_edit_object':
ob_start();
require AmpConfig::get('prefix') . UI::find_template('show_edit_' . $type . '.inc.php');
$results = ob_get_contents();
break;
case 'refresh_updated':
require AmpConfig::get('prefix') . UI::find_template('show_' . $type . '.inc.php');
$results = ob_get_contents();
break;
case 'show_edit_playlist':
ob_start();
require AmpConfig::get('prefix') . UI::find_template('show_playlists_dialog.inc.php');
$results = ob_get_contents();
ob_end_clean();
break;
case 'edit_object':
// Scrub the data, walk recursive through array
$entities = function (&$data) use(&$entities) {
foreach ($data as $key => $value) {
$data[$key] = is_array($value) ? $entities($value) : unhtmlentities(scrub_in($value));
}
return $data;
};
$entities($_POST);
$libitem = new $object_type($_POST['id']);
if ($libitem->get_user_owner() == $GLOBALS['user']->id && AmpConfig::get('upload_allow_edit') && !Access::check('interface', 50)) {
// TODO: improve this uniqueless check
示例9: define
* (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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
define('NO_SESSION', '1');
require_once 'lib/init.php';
// Avoid form login if still connected
if (AmpConfig::get('use_auth') && !isset($_GET['force_display'])) {
$auth = false;
if (Session::exists('interface', $_COOKIE[AmpConfig::get('session_name')])) {
$auth = true;
} else {
if (Session::auth_remember()) {
$auth = true;
}
}
if ($auth) {
header("Location: " . AmpConfig::get('web_path'));
exit;
}
}
require_once 'lib/login.php';
require AmpConfig::get('prefix') . UI::find_template('show_login_form.inc.php');
示例10: show
/**
* show
* This takes an id and a type and displays the rating if ratings are
* enabled. If $static is true, the rating won't be editable.
*/
public static function show($object_id, $type, $static = false)
{
// If ratings aren't enabled don't do anything
if (!AmpConfig::get('ratings')) {
return false;
}
$rating = new Rating($object_id, $type);
if ($static) {
require AmpConfig::get('prefix') . UI::find_template('show_static_object_rating.inc.php');
} else {
require AmpConfig::get('prefix') . UI::find_template('show_object_rating.inc.php');
}
}
示例11: T_
<th class="cel_description"><?php
echo T_('Description');
?>
</th>
<th class="cel_action"><?php
echo T_('Action');
?>
</th>
</tr>
</thead>
<tbody>
<?php
foreach ($object_ids as $license_id) {
$libitem = new License($license_id);
$libitem->format();
require AmpConfig::get('prefix') . UI::find_template('show_license_row.inc.php');
?>
<?php
}
if (!count($object_ids)) {
?>
<tr class="<?php
echo UI::flip_class();
?>
">
<td colspan="6" class="error"><?php
echo T_('No Licenses Found');
?>
</td>
</tr>
<?php
示例12:
<?php
/* vim:set softtabstop=4 shiftwidth=4 expandtab: */
/**
*
* LICENSE: GNU Affero General Public License, version 3 (AGPLv3)
* Copyright 2001 - 2015 Ampache.org
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
UI::show_box_top(T_('Information'));
require_once AmpConfig::get('prefix') . UI::find_template('show_stats_recent.inc.php');
UI::show_box_bottom();
示例13: License
if (isset($_POST['license_id'])) {
$license = new License($_POST['license_id']);
if ($license->id) {
$license->update($_POST);
}
$text = T_('License Updated');
} else {
License::create($_POST);
$text = T_('License Created');
}
show_confirmation($text, '', AmpConfig::get('web_path') . '/admin/license.php');
break;
case 'show_edit':
$license = new License($_REQUEST['license_id']);
case 'show_create':
require_once AmpConfig::get('prefix') . UI::find_template('show_edit_license.inc.php');
break;
case 'delete':
License::delete($_REQUEST['license_id']);
show_confirmation(T_('License Deleted'), '', AmpConfig::get('web_path') . '/admin/license.php');
break;
default:
$browse = new Browse();
$browse->set_type('license');
$browse->set_simple_browse(true);
$license_ids = $browse->get_objects();
$browse->show_objects($license_ids);
$browse->store();
break;
}
UI::show_footer();
示例14: T_
<?php
echo T_('Queries:');
echo Dba::$stats['query'];
?>
<?php
echo T_('Cache Hits:');
echo database_object::$cache_hit;
?>
<?php
$load_time_end = microtime(true);
$load_time = number_format($load_time_end - AmpConfig::get('load_time_begin'), 4);
?>
| <?php
echo T_('Load time:');
echo $load_time;
?>
<?php
}
?>
</div>
<?php
if (AmpConfig::get('ajax_load') && (!isset($_SESSION['login']) || !$_SESSION['login'])) {
?>
<div id="webplayer"></div>
<?php
require_once AmpConfig::get('prefix') . UI::find_template('uberviz.inc.php');
}
?>
</body>
</html>
示例15: scrub_out
?>
" lang="<?php
echo $htmllang;
?>
" dir="<?php
echo $dir;
?>
">
<head>
<!-- Propulsed by Ampache | ampache.org -->
<meta http-equiv="Content-Type" content="text/html; charset=<?php
echo AmpConfig::get('site_charset');
?>
" />
<?php
require_once AmpConfig::get('prefix') . UI::find_template('stylesheets.inc.php');
?>
<title> <?php
echo scrub_out(AmpConfig::get('site_title'));
?>
</title>
<script type="text/javascript" language="javascript">
function focus(){ document.login.username.focus(); }
</script>
</head>
<body id="loginPage" onload="focus();">
<div id="maincontainer">
<div id="header"><!-- This is the header -->
<a href="<?php
echo $web_path;