本文整理汇总了PHP中Browse::set_show_header方法的典型用法代码示例。如果您正苦于以下问题:PHP Browse::set_show_header方法的具体用法?PHP Browse::set_show_header怎么用?PHP Browse::set_show_header使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Browse
的用法示例。
在下文中一共展示了Browse::set_show_header方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Playlist
require_once '../lib/init.php';
debug_event('refresh_reordered.server.php', 'Called for action: {' . $_REQUEST['action'] . '}', '5');
/* Switch on the action passed in */
switch ($_REQUEST['action']) {
case 'refresh_playlist_medias':
$playlist = new Playlist($_REQUEST['id']);
$playlist->format();
$object_ids = $playlist->get_items();
$browse = new Browse();
$browse->set_type('playlist_media');
$browse->add_supplemental_object('playlist', $playlist->id);
$browse->set_static_content(true);
$browse->show_objects($object_ids);
$browse->store();
break;
case 'refresh_album_songs':
$browse = new Browse();
$browse->set_show_header(true);
$browse->set_type('song');
$browse->set_simple_browse(true);
$browse->set_filter('album', $_REQUEST['id']);
$browse->set_sort('track', 'ASC');
$browse->get_objects();
echo "<div id='browse_content_song' class='browse_content'>";
$browse->show_objects(null, true);
// true argument is set to show the reorder column
$browse->store();
echo "</div>";
break;
}
// switch on the action
示例2: Browse
require_once '../lib/init.php';
if (!Core::is_session_started()) {
session_start();
}
if (!defined('AJAX_INCLUDE')) {
exit;
}
if (isset($_REQUEST['browse_id'])) {
$browse_id = $_REQUEST['browse_id'];
} else {
$browse_id = null;
}
debug_event('browse.ajax.php', 'Called for action: {' . $_REQUEST['action'] . '}', '5');
$browse = new Browse($browse_id);
if (isset($_REQUEST['show_header']) && $_REQUEST['show_header']) {
$browse->set_show_header($_REQUEST['show_header'] == 'true');
}
$argument = null;
if ($_REQUEST['argument']) {
$argument = scrub_in($_REQUEST['argument']);
}
$results = array();
switch ($_REQUEST['action']) {
case 'browse':
$object_ids = array();
// Check 'value' with isset because it can null
//(user type a "start with" word and deletes it)
if ($_REQUEST['key'] && (isset($_REQUEST['multi_alpha_filter']) or isset($_REQUEST['value']))) {
// Set any new filters we've just added
$browse->set_filter($_REQUEST['key'], $_REQUEST['multi_alpha_filter']);
$browse->set_catalog($_SESSION['catalog']);
示例3: Browse
', '<?php
echo T_('Album edit');
?>
', '')">
<?php
echo UI::get_icon('edit', T_('Edit'));
?>
</a>
<?php
}
?>
</div>
<div id='reordered_list_<?php
echo $album_id;
?>
'>
<?php
$browse = new Browse();
$browse->set_show_header(false);
$browse->set_type('song');
$browse->set_simple_browse(true);
$browse->set_filter('album', $album_id);
$browse->set_sort('track', 'ASC');
$browse->get_objects();
$browse->show_objects(null, true);
// true argument is set to show the reorder column
$browse->store();
?>
</div><br />
<?php
}