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


PHP get_videos函数代码示例

本文整理汇总了PHP中get_videos函数的典型用法代码示例。如果您正苦于以下问题:PHP get_videos函数的具体用法?PHP get_videos怎么用?PHP get_videos使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: json_encode

             echo json_encode(array("error" => "Nothing Found"));
         }
     }
     break;
 case "channelObjects":
     $contentType = strtolower(mysql_clean($_POST['content']));
     $u = $userquery->get_user_details($_POST['user']);
     $assign = $_POST['assign'];
     if (is_array($assign)) {
         foreach ($assign as $var => $value) {
             assign($var, $value);
         }
     }
     switch ($contentType) {
         case "videos":
             $videos = get_videos(array("user" => $u['userid'], "order" => " date_added DESC", "limit" => config('videos_item_channel_page')));
             if ($videos) {
                 foreach ($videos as $video) {
                     assign('video', $video);
                     assign('channelVideo', true);
                     $content['html'] .= Fetch("/blocks/video.html");
                 }
                 $content['html'] .= '<div align="right" class="clearfix channelAjaxMoreLink videosMoreLink" style="clear:both; display:block;">';
                 $content['html'] .= '<a href="' . cblink(array("name" => "user_videos")) . $u['username'] . '">' . lang('more') . '</a> | <a href="' . cblink(array("name" => "user_favorites")) . $u['username'] . '">' . lang('Favorites') . '</a>';
                 $content['html'] .= '</div>';
             } else {
                 $content['html'] = '<div align="center"><em>' . lang('user_have_no_vide') . '</em></div>';
             }
             break;
         case "photos":
             $photos = get_photos(array("user" => $u['userid'], "order" => " date_added DESC", "limit" => config('photo_channel_page')));
开发者ID:yukisky,项目名称:clipbucket,代码行数:31,代码来源:ajax.php

示例2: get_videos

        $videos = get_videos(array('limit' => $limit, 'order' => 'last_viewed DESC'));
        $title = "Videos Being Watched";
        break;
    case 'user':
        $user = mysql_clean($_GET['username']);
        //Get userid from username
        $uid = $userquery->get_user_field_only($user, 'userid');
        $uid = $uid ? $uid : 'x';
        $videos = get_videos(array('limit' => $limit, 'user' => $uid, 'order' => 'date_added DESC'));
        //Count Total Videos of this user
        $total_vids = get_videos(array('count_only' => true, 'user' => $uid));
        $title = "Videos uploaded by " . $user;
        break;
    case 'featured':
    default:
        $videos = get_videos(array('limit' => $limit, 'order' => 'featured_date DESC', 'featured' => 'yes'));
        $title = "Featured Videos";
        break;
}
subtitle($title);
?>

<rss version="2.0" xmlns:media="http://search.yahoo.com/mrss/">
<channel>
<title><?php 
echo cbtitle();
?>
</title>
<link><?php 
echo BASEURL;
?>
开发者ID:yukisky,项目名称:clipbucket,代码行数:31,代码来源:rss.php

示例3: e

if (!$details) {
    e(lang("grp_exist_error"));
} elseif (!$cbgroup->is_viewable($details)) {
    $Cbucket->show_page = false;
} elseif (!$cbgroup->is_member(userid(), $details['group_id'])) {
    e(lang("you_not_allowed_add_grp_vids"));
} else {
    ///Getting User Videos
    $page = mysql_clean($_GET['page']);
    $get_limit = create_query_limit($page, 28);
    $array = array('user' => userid(), 'limit' => $get_limit);
    $usr_vids = get_videos($array);
    //echo $db->db_query;
    assign('usr_vids', $usr_vids);
    $array['count_only'] = true;
    $total_rows = get_videos($array);
    $total_pages = count_pages($total_rows, 28);
    //Pagination
    $pages->paginate($total_pages, $page);
    //Adding videos to group
    if (isset($_POST['add_videos'])) {
        $total = count($usr_vids);
        for ($i = 0; $i < $total; $i++) {
            $videoid = $usr_vids[$i]['videoid'];
            if ($_POST['check_video_' . $videoid] == 'yes') {
                $cbgroup->add_group_video($videoid, $details['group_id'], false);
            } else {
                $cbgroup->remove_group_video($videoid, $details['group_id'], false);
            }
        }
        //Update Group Total Videos
开发者ID:Coding110,项目名称:cbvideo,代码行数:31,代码来源:add_group_videos.php

示例4: p_r

function p_r($array)
{
    echo "<pre>";
    print_r($array);
    echo "</pre>";
}
$start_index = $_GET['start_index'] ? $_GET['start_index'] : 0;
$loop_size = $_GET['loop_size'];
$loop_size = $loop_size ? $loop_size : 5;
assign('loop_size', $loop_size);
$next_index = $start_index + $loop_size;
assign('next_index', $next_index);
//Reindex Videos
if (isset($_GET['index_vids'])) {
    $videos = get_videos(array("active" => "yes", "status" => "Successful", "limit" => $start_index . "," . $loop_size));
    $total_videos = get_videos(array("count_only" => true, "active" => "yes", "status" => "Successful"));
    $percent = number_format(50 * $total_videos / 100);
    $i = 0;
    assign('total', $total_videos);
    assign('from', $start_index + 1);
    $to = $start_index + $loop_size;
    if ($to > $total_videos) {
        $to = $total_videos;
        e($total_videos . " videos have been reindexed successfully.", "m");
        assign("stop_loop", "yes");
    }
    assign('to', $to);
    while ($i < $total_videos) {
        if ($videos[$i]['videoid']) {
            $params = array("video_id" => $videos[$i]['videoid'], "video_comments" => true, "favs_count" => true, "playlist_count" => true);
            $indexes = $cbindex->count_index("vid", $params);
开发者ID:Coding110,项目名称:cbvideo,代码行数:31,代码来源:reindex_cb.php

示例5: get_text

<div id="gallery" class="row">
    <div id="content" class="row">
        <header class="content">
            <h3><?php 
get_text($gallery_title);
?>
</h3>
            <p><?php 
get_text($gallery_description);
?>
</p>
        </header>
        
        <div id="thumbs" class="content grid">
            <?php 
get_videos('gallery', 'content-gallery-item');
?>
        </div>
    </div>
    
    <footer id="footer" class="row">
        <div class="content">
            <div class="left">
                <span><?php 
get_text($footer_text);
?>
</span><br>
                <a class="cinematico" href="http://cinemati.co" target="_blank">Powered by Cinematico</a>
            </div>
            
            <div class="right">
开发者ID:cristianoiglesias,项目名称:cinematico,代码行数:31,代码来源:content-gallery.php

示例6: mysql_clean

$u = mysql_clean($u);
$udetails = $userquery->get_user_details($u);
$page = mysql_clean($_GET['page']);
if ($udetails) {
    assign("u", $udetails);
    $mode = $_GET['mode'];
    assign("u", $udetails);
    assign('p', $userquery->get_user_profile($udetails['userid']));
    switch ($mode) {
        case 'uploads':
        case 'videos':
        default:
            $get_limit = create_query_limit($page, config('videos_items_uvid_page'));
            assign("the_title", $udetails['username'] . " videos");
            $videos = get_videos(array('user' => $udetails['userid'], 'limit' => $get_limit));
            $total_rows = get_videos(array('user' => $udetails['userid'], 'count_only' => true));
            subtitle(sprintf(lang("users_videos"), $udetails['username']));
            $total_pages = count_pages($total_rows, config('videos_items_uvid_page'));
            break;
        case 'favorites':
            $get_limit = create_query_limit($page, config('videos_items_ufav_page'));
            assign("the_title", $udetails['username'] . " favorites");
            $params = array('userid' => $udetails['userid'], 'limit' => $get_limit);
            $videos = $cbvid->action->get_favorites($params);
            $params['count_only'] = "yes";
            $total_rows = $cbvid->action->get_favorites($params);
            subtitle(sprintf(lang("title_usr_fav_vids"), $udetails['username']));
            $total_pages = count_pages($total_rows, config('videos_items_ufav_page'));
            //pr($total_pages,true);
            break;
        case 'playlists':
开发者ID:reactvideos,项目名称:Website,代码行数:31,代码来源:user_videos.php

示例7: count

    $total = count($_POST['check_queue']);
    for ($i = 0; $i <= $total; $i++) {
        $myquery->queue_action("delete", $_POST['check_queue'][$i]);
    }
    e("Selected items have been deleted", "m");
}
if (isset($_POST['processed'])) {
    $total = count($_POST['check_queue']);
    for ($i = 0; $i <= $total; $i++) {
        $myquery->queue_action("processed", $_POST['check_queue'][$i]);
    }
    e("Selected items have been set changed to processed", "m");
}
if (isset($_POST['pending'])) {
    $total = count($_POST['check_queue']);
    for ($i = 0; $i <= $total; $i++) {
        $myquery->queue_action("pending", $_POST['check_queue'][$i]);
    }
    e("Selected items have been set changed to processed", "m");
}
//Getting List of Conversion Queue
$page = mysql_clean($_GET['page']);
$get_limit = create_query_limit($page, RESULTS);
$queue_list = $myquery->get_conversion_queue(NULL, $get_limit);
assign('queues', $queue_list);
$total_rows = get_videos($vcount);
$total_pages = count_pages($db->count(tbl('conversion_queue'), "cqueue_id"), RESULTS);
$pages->paginate($total_pages, $page);
subtitle("Conversion Queue Manager");
template_files("cb_conversion_queue.html");
display_it();
开发者ID:Coding110,项目名称:cbvideo,代码行数:31,代码来源:cb_conversion_queue.php

示例8: error_list

            $msg = $msg[0];
        }
        if (error()) {
            $err = error_list();
            $err = $err[0];
        }
        $ajax['msg'] = $msg;
        $ajax['err'] = $err;
        echo json_encode($ajax);
        break;
}
/////////////////////////ending notes
if (!$array['order']) {
    $result_array['order'] = " views DESC LIMIT 8 ";
}
$videos = get_videos($result_array);
Assign('videos', $videos);
$comments = getComments($comment_cond);
assign("comments", $comments);
$get_limit = create_query_limit($page, 5);
$videos = $cbvid->action->get_flagged_objects($get_limit);
Assign('flaggedVideos', $videos);
$get_limit = create_query_limit($page, 5);
$users = $userquery->action->get_flagged_objects($get_limit);
Assign('flaggedUsers', $users);
$get_limit = create_query_limit($page, 5);
$photos = $cbphoto->action->get_flagged_objects($get_limit);
assign('flaggedPhotos', $photos);
$numbers = array(100, 1000, 15141, 3421);
function format_number($number)
{
开发者ID:reactvideos,项目名称:Website,代码行数:31,代码来源:index.php

示例9: content_56afd78d1fea15_55283541


//.........这里部分代码省略.........
							<?php 
            if (isset($_smarty_tpl->tpl_vars['counter'])) {
                $_smarty_tpl->tpl_vars['counter'] = clone $_smarty_tpl->tpl_vars['counter'];
                $_smarty_tpl->tpl_vars['counter']->value = $_smarty_tpl->tpl_vars['counter']->value + 1;
                $_smarty_tpl->tpl_vars['counter']->nocache = null;
                $_smarty_tpl->tpl_vars['counter']->scope = 0;
            } else {
                $_smarty_tpl->tpl_vars['counter'] = new Smarty_variable($_smarty_tpl->tpl_vars['counter']->value + 1, null, 0);
            }
            ?>
							<?php 
        }
        ?>
						</ul>
						<input tabindex="-1" type="submit" name="cbsearch" id="cbsearch" value="<?php 
        echo smarty_lang(array('code' => 'Go'), $_smarty_tpl);
        ?>
" class="btn btn-default minus-marginLeft" />
					</div>
				</div>
			</form>
		</div>

		<ul class="nav navbar-nav main-nav navbar-collapse collapse manual-height left-margin-xero pad-left-xero" id="khulja-sim-sim">
			<li class="dropdown hidden-xs mega-dropdown">
				<a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="fa fa-bars"></i>&nbsp;Menu <span class="caret"></span></a>
				<ul class="dropdown-menu clearfix mega-dropdown-menu noclose">
					<li class="col col-lg-3 col-md-3 col-sm-4 col-xs-12">
						<div id="menCollection" class="carousel slide clearfix" data-ride="carousel">
							<div class="carousel-inner">
							<?php 
        if (isset($_smarty_tpl->tpl_vars['videos'])) {
            $_smarty_tpl->tpl_vars['videos'] = clone $_smarty_tpl->tpl_vars['videos'];
            $_smarty_tpl->tpl_vars['videos']->value = get_videos(array("order" => "date_added DESC", "limit" => 4, "featured" => "yes"));
            $_smarty_tpl->tpl_vars['videos']->nocache = null;
            $_smarty_tpl->tpl_vars['videos']->scope = 0;
        } else {
            $_smarty_tpl->tpl_vars['videos'] = new Smarty_variable(get_videos(array("order" => "date_added DESC", "limit" => 4, "featured" => "yes")), null, 0);
        }
        ?>
							<?php 
        if ($_smarty_tpl->tpl_vars['videos']->value) {
            ?>
				        	<?php 
            $_smarty_tpl->tpl_vars['video'] = new Smarty_Variable();
            $_smarty_tpl->tpl_vars['video']->_loop = false;
            $_from = $_smarty_tpl->tpl_vars['videos']->value;
            if (!is_array($_from) && !is_object($_from)) {
                settype($_from, 'array');
            }
            $_smarty_tpl->tpl_vars['video']->iteration = 0;
            foreach ($_from as $_smarty_tpl->tpl_vars['video']->key => $_smarty_tpl->tpl_vars['video']->value) {
                $_smarty_tpl->tpl_vars['video']->_loop = true;
                $_smarty_tpl->tpl_vars['video']->iteration++;
                ?>
				        	<?php 
                if ($_smarty_tpl->tpl_vars['video']->iteration == 1) {
                    ?>
				        	<div class="item active">
				        	<?php 
                } else {
                    ?>
				        	<div class="item">
				        	<?php 
                }
                ?>
开发者ID:reactvideos,项目名称:Website,代码行数:67,代码来源:0bb2b4a7950177c772107f1dddb828f9cbf5f716.file.header.html.php

示例10: json_encode

                $data[$i]['options']['type'] = 'projectMarker';
                $data[$i]['options']['actionType'] = "linkToProject";
            }
            $marker_data['markers'] = $data;
        } else {
            $marker_data['error'] = 'permission denied';
        }
    } else {
        $marker_data['error'] = 'permission denied';
    }
    echo json_encode($marker_data, JSON_NUMERIC_CHECK);
}
//get videos of a project
if ($_GET['req'] == "getVideos") {
    $project_id = $_GET['data']['projectId'];
    $video_rows = get_videos($project_id);
    //chage data form for client side
    $videos = array();
    for ($i = 0; $i < count($video_rows); $i++) {
        $video = $video_rows[$i];
        $videos[] = array('id' => $video['video_id'], 'url' => $video['url'], 'name' => $video['name']);
    }
    echo json_encode($videos, JSON_NUMERIC_CHECK);
}
if ($_GET['req'] == "getPolylines") {
    $project_id = $_GET['data']['projectId'];
    $polyline_rows = get_polylines($project_id);
    //get polylines of a project
    $polylines = array();
    for ($i = 0; $i < count($polyline_rows); $i++) {
        $polyline = $polyline_rows[$i];
开发者ID:nextben,项目名称:PVR_editor,代码行数:31,代码来源:getData.php

示例11: header

<?php

include '../../../../includes/config.inc.php';
header('Content-Type: text/xml');
$title = mysql_clean($_GET['title']);
$tags = mysql_clean($_GET['tags']);
$videoid = mysql_clean($_GET['vid']);
$related_videos = get_videos(array('title' => $title, 'tags' => $tags, 'exclude' => $videoid, 'show_related' => 'yes', 'limit' => 8, 'order' => 'date_added DESC'));
if (!$related_videos) {
    $related_videos = get_videos(array('exclude' => $videoid, 'limit' => 12, 'order' => 'date_added DESC'));
}
?>
<rss version="2.0" xmlns:media="http://search.yahoo.com/mrss/">
<channel>
	<?php 
if ($related_videos) {
    foreach ($related_videos as $video) {
        ?>
    <item>
        <title><?php 
        echo $video['title'];
        ?>
</title>
        <link><?php 
        echo videoLink($video);
        ?>
</link>
        <media:thumbnail url="<?php 
        echo get_thumb($video);
        ?>
" height="90" width="120" time="<?php 
开发者ID:Coding110,项目名称:cbvideo,代码行数:31,代码来源:related_videos.php

示例12: is_video

function is_video($record)
{
    $videos = get_videos();
    foreach ($videos as $video) {
        if (strstr(strtolower($record['type']), $video)) {
            return true;
        }
    }
    return false;
}
开发者ID:phillipmadsen,项目名称:noidea-shopify,代码行数:10,代码来源:import_functions.php

示例13: content_56afd77ab2a977_56293857


//.........这里部分代码省略.........
                                </div>

                                <div class="col-md-7">
                                    <label class="label label-danger">Last Active  <?php 
                echo niceTime($_smarty_tpl->tpl_vars['u']->value['last_active']);
                ?>
</label>
                                    <label class="label label-primary"> <?php 
                echo smarty_lang(array('code' => 'Flags'), $_smarty_tpl);
                ?>
 : <?php 
                echo $_smarty_tpl->tpl_vars['u']->value['flag_type'];
                ?>
</label>

                                </div>
                            </div>
                            <?php 
            }
            ?>
                        <?php 
        }
        ?>
                    </div>
                </div>
           
                <div class="widget-main">
                    <hr>
                    <table class="table table-stripped table-bordered">
                        <tr>
                            <td>
                                <div class="stats_subitem_d">Total Videos : <strong><?php 
        ob_start();
        echo get_videos(array('count_only' => 'yes'), $_smarty_tpl);
        echo number_format(ob_get_clean());
        ?>
</strong> </div>
                            </td>
                            <td>
                                <div class="stats_subitem_d">Total Groups : <strong><?php 
        echo get_groups(array('count_only' => 'yes'), $_smarty_tpl);
        ?>
</strong> </div>
                            </td>
                            <td>
                                <div class="stats_subitem_d">Total Collection : <strong><?php 
        echo get_collections(array('count_only' => 'yes'), $_smarty_tpl);
        ?>
</strong> </div>
                            </td>
                            <td>
                                <div class="stats_subitem_d">Total Users : <strong><?php 
        echo get_users(array('count_only' => 'yes'), $_smarty_tpl);
        ?>
</strong> </div>
                            </td>
                            <td>
                                <div class="stats_subitem_d">Total Photos: <strong><?php 
        echo get_photos(array('count_only' => 'yes'), $_smarty_tpl);
        ?>
</strong> </div>
                            </td>
                    </table>
                </div>

            </div>
开发者ID:reactvideos,项目名称:Website,代码行数:67,代码来源:49fc3041a368292de3fa784c18e159751f38aa9b.file.index.html.php

示例14: foreach

                    <video height="480" autobuffer="1" preload="metadata">

                    </video>
                </div>
            </div>
        </div>
        <div id="container">
            <ul class='cams'>
                <?php 
if ($list === false) {
    foreach ($cams as $cam) {
        if (isset($cam_dir[$cam])) {
            if (count($cams) <= 1 || $detail) {
                echo "<li><h4>" . htmlentities($cam_dir[$cam]['section']['title']) . " : " . htmlentities($cam_dir[$cam]['data'][0]) . "</h4>\n";
                echo "<ul class='dates'>";
                $videos = get_videos($cam, $all ? false : RECENT_DEFAULT);
                foreach ($videos as $video) {
                    $date = preg_replace('/.*-(20\\d\\d-\\d\\d-\\d\\d).*/', '\\1', $video);
                    $url = sprintf($vurltmpl, $video);
                    $path = sprintf($vpathtmpl, $video);
                    $htmldate = htmlentities($date);
                    echo "<li><a class='play-link' href='#{$url}' data-video='{$path}'><i class='fa fa-play'></i> {$htmldate}</a></li>";
                }
                if (!$all) {
                    echo "<li><a href='?cam=" . htmlentities($cam) . "&all=1'>more</a></li>\n";
                }
                echo "</ul>";
            } else {
                echo "<li><h4><a href='?cam=" . htmlentities($cam) . "'>" . htmlentities($cam_dir[$cam]['section']['title']) . " : " . htmlentities($cam_dir[$cam]['data'][0]) . "\n";
                echo "</a></h4><ul>";
            }
开发者ID:mscalora,项目名称:utah-cams,代码行数:31,代码来源:videos.php

示例15: array

            $userquery->removeProfileItem();
        }
        //Getting Video List
        $vid_array = array('user' => $udetails['userid'], 'limit' => $get_limit);
        if (get('query') != '') {
            $vid_array['title'] = mysql_clean(get('query'));
            $vid_array['tags'] = mysql_clean(get('query'));
        }
        if (get('order') == 'oldest') {
            $vid_array['order'] = ' date_added ASC ';
        } else {
            $vid_array['order'] = ' date_added DESC ';
        }
        if (get('broadcast') && is_valid_broadcast(get('broadcast'))) {
            $vid_array['broadcast'] = mysql_clean(get('broadcast'));
        }
        $videos = get_videos($vid_array);
        Assign('uservids', $videos);
        Assign('videos', $videos);
        //Collecting Data for Pagination
        $vid_array['count_only'] = true;
        $total_rows = get_videos($vid_array);
        assign('total_videos', $total_rows);
        $total_pages = count_pages($total_rows, VLISTPP);
        //Pagination
        $pages->paginate($total_pages, $page);
        subtitle(lang("vdo_manage_vdeos"));
        break;
}
template_files('manage_videos.html');
display_it();
开发者ID:yukisky,项目名称:clipbucket,代码行数:31,代码来源:manage_videos.php


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