array('post'),
'order' => $dedication_order,
'orderby' => $dedication_orderby,
'posts_per_page' => $posts_per_page,
'post_status' => $post_status,
'category_name' => $category_name,
);
query_posts($args);
}
if (have_posts()) {
$slide_counter = 0;
?>
ID, 'ghostpool_destination_user_email', true);
// Usuario actual puede ver la dedicatoria?
if (($current_user->ID == $from_user_id) || ($current_user->user_email == $to_user_email)) {
$video = get_post_meta($post->ID, 'ghostpool_dedication_url', true);
$artist = get_post_meta($post->ID, 'ghostpool_dedication_artist', true);
$song = get_post_meta($post->ID, 'ghostpool_dedication_song', true);
// Video Type
$vimeo = strpos($video, "vimeo.com");
$yt1 = strpos($video, "youtube.com");
$yt2 = strpos($video, "youtu.be");
if (($vimeo) OR ($yt1) OR ($yt2)) {
if ($yt2) { //youtu.be
$video_id = substr(parse_url($video, PHP_URL_PATH), 1);
$data_type = 'youtube_single';
$data_path = 'http://gdata.youtube.com/feeds/api/videos/' . $video_id . '?v=2&alt=jsonc';
}
if ($yt1) { //youtube.com
$video = parse_str(parse_url($video, PHP_URL_QUERY), $my_array_of_vars);
$video_id = $my_array_of_vars['v'];
$data_type = 'youtube_single';
$data_path = 'http://gdata.youtube.com/feeds/api/videos/' . $video_id . '?v=2&alt=jsonc';
}
if ($vimeo) { //vimeo.com
$video_id = substr(parse_url($video, PHP_URL_PATH), 1);
$data_type = 'vimeo_single';
$data_path = 'http://vimeo.com/api/v2/video/' . $video_id . '.json';
}
?>
-
FROM:
ID);
?>TO: ID); ?>
TO: ID, 'ghostpool_destination_user_name', true); ?>