Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

jwplayer_tag_callback() not supported?


When I updated to 6 I now get this error message where my videos are:

bc.. Fatal error: Call to undefined function jwplayer_tag_callback()


Is that function not supported anymore? Is there another way to use the shortcode in theme?

11 Community Answers

JW Player

User  
0 rated :

I am getting the error here: http://fandom.candaceduffyjones.com/hatteralice-video/.

I am using my own theme. I have plugin version 2.0.5 with JW Player 6.2.

I using this code in my theme loop-video.php:
bc.. <!-- THE VIDEO LOOP -->
<div class="date-tab">
<div class="post-date"><?php the_time('d M Y'); ?></div>
</div><!-- .date-tab -->
<?php $jwplayer_id = get_post_meta( $post->ID, 'jwplayermodule_fb_headers_id', true ); ?>
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<div class="video"><?php echo jwplayer_tag_callback('[jwplayer config="Mobile" mediaid="' . $jwplayer_id . '"]'); ?></div>
<div class="post-content">
<?php the_excerpt( 'READ MORE <span class="meta-nav">→</span>'); ?>
<div class="post-meta">
<div class="post-tags"><?php the_tags('#',' #',''); ?></div>
<div class="post-comments"><a href="<?php the_permalink(); ?>#comments"><?php comments_number('0','1','%'); ?></a></div>
</div>
</div><!-- .post-content -->
</article><!-- .post -->


and I placed in my functions.php
bc.. apply_filters('jwplayer_tag_callback', 'the_content');


I have all the shortcode settings set to content.

This code work before I updated to JW 6. I works fine on my other blog within the multisite, but that I put the shortcode into the post instead of the theme.

JW Player

User  
0 rated :

I couldn't get that to work. I just decided to just not use the shortcode in the theme.

JW Player

User  
0 rated :

hi roel
i have almost the same problem.
i use :
bc.. <?php $jwplayer_id = the_ID();?>

<?php echo JWP6_Shortcode::the_content_filter('[jwplayer mediaid="' . $jwplayer_id . '"]'); ?>


in my theme code and i get this error:
Error loading player:
No playable sources found
and when i put
bc.. apply_filters(array('JWP6_Shortcode', 'the_content_filter'), 'the_content');


i get some other error page at page header when using in localhost.
i really like to use this and i have to.
because i have promised someone to solve this.
thx

JW Player

User  
0 rated :

i dont know why enen the error and black div disapperaed.
nothing now.
even worse than before.
this is the whole template code that i'm using:
bc.. <?php if (!empty($max['videos'])) { ?>

<?php
$v = 1;
$video = new WP_query();
$video->query('showposts='.$max['videon'].'&cat='.$max['videos']);
?>

<div class="videohead"><span class="videotitle"><?php _e('Media Browser','max'); ?></span>

<ul id="videos" class="videos">
<?php while ($video->have_posts()) : $video->the_post(); ?>
<li><a href="#" rel="video-<?php the_ID(); ?>" class="<?php if($v == 1) echo 'selected'; ?>"><?php print $v++; ?></a></li>
<?php endwhile; ?>
<li><a href="<?php echo get_category_link($max['videos']); ?>" title="More Videos"><?php _e('more','max'); ?></a></li>
</ul><div class="clear"></div>

</div><div class="clear"></div>

<?php while ($video->have_posts()) : $video->the_post(); ?>
<div id="video" class="VideoContent">
<?php $jwplayer_id = the_ID();?>
<div class="videop"><?php echo JWP6_Shortcode::the_content_filter('[jwplayer mediaid="' . $jwplayer_id . '"]'); ?></div>
<div class="videofooter"><span><?php _e('Currently playing:','max'); ?></span> <?php the_title(); ?></div>
</div>
<?php endwhile; ?>

<script type="text/javascript">
var videos=new ddtabcontent("videos")
videos.setpersist(false)
videos.setselectedClassTarget("link")
videos.init()
</script>

<?php } ?>

JW Player

User  
0 rated :

sorry-because i'm using it on localserver.
but i'm almost sure about the media IDs.
what else is the problem?
I really need to do that.
the way it not important just help me to make to to work.
i just want a tabbed video box of last vodeo posts.
thx so much

JW Player

User  
0 rated :

hi roel
i finally could make it up.
thx so much.

but now another problem:
i want 2 tabbed box in home page.
for my 2 video categories.
i have included the 2 different file almost same for each one in my index.php.
each one code is almost same to what i had post before here.
but just the first one work.
the code that work now correctly is:
bc.. <?php if (!empty($max['videos'])) { ?>

<?php
$v = 1;
$video = new WP_query();
$video->query('showposts='.$max['videon'].'&cat='.$max['videos']);
?>

<div class="videohead"><span class="videotitle"><?php print get_cat_name($max['videos']); ?></span>

<ul id="videos" class="videos">
<?php while ($video->have_posts()) : $video->the_post(); ?>
<li><a href="#" rel="video-<?php the_ID(); ?>" class="<?php if($v == 1) echo 'selected'; ?>"><?php print $v++; ?></a></li>
<?php endwhile; ?>
</ul><div class="clear"></div>

</div><div class="clear"></div>

<?php while ($video->have_posts()) : $video->the_post(); ?>
<div id="video-<?php the_ID(); ?>" class="VideoContent">
<div class="videofooter"><span><?php _e('Currently playing:','max'); ?></span><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php the_title(); ?>"><?php the_title(); ?></a></div>

<?php

$attachments = get_posts(array(
'post_type' => 'attachment',
'numberposts' => 3,
'post_status' =>'any',
'post_parent' => $post->ID
));

if ($attachments) {
foreach ( $attachments as $attachment ) {
}
}; ?>

<div class="videop"><?php echo JWP6_Shortcode::the_content_filter('[jwplayer player="1" file="'.wp_get_attachment_url($attachment->ID).'"]'); ?></div>

</div>
<?php endwhile; ?>

<script type="text/javascript">
var videos=new ddtabcontent("videos")
videos.setpersist(false)
videos.setselectedClassTarget("link")
videos.init()
</script>

<?php } ?>
<div class="clear"></div>
<a href="<?php print get_category_link($max['videos']); ?>" rel="bookmark" class="flink">???? ????? ??? ????? ??</a>

JW Player

User  
0 rated :

ok roel. u won.
i uploaded them. but not in homepage.
in everysingle page there are 2 tabbed player that only first one work.
link:

http://www.kavoshpress.ir/subject/politics/%D8%A7%D8%B4%D8%AA%D8%A8%D8%A7%D9%87-%D8%B1%D9%87%D8%A8%D8%B1%DB%8C%D8%9B-%D8%A7%D9%84%DA%AF%D9%88%DB%8C-%D9%85%D8%AF%DB%8C%D8%B1%DB%8C%D8%AA-%D8%A7%D8%B3%D9%84%D8%A7%D9%85%DB%8C/

and another problem . only first tab show the video.(on local host there wasn't any problem with secound or third tab.)
thx for your help

JW Player

User  
0 rated :

sorry the secound problem is solved if i select flash not html5.

but we recently upload our video on a download server with a subdomain of kavoshpress.ir
the videos of the download server don't be played and could not be found.
u can see error yourself.
just pls answer my question.
thx for your reply

JW Player

User  
0 rated :

yes i see
i use the wp-get-attachment-url function as u can see.
i am working on it.

but the more important problem is having just a tabbed box not 2.
did u see that too?

JW Player

User  
0 rated :

do u have suggestion to get file url from post ID?
we use a download server as s1.kavoshpress.ir and enter them to library as external medias.

JW Player

User  
0 rated :

ok

but if you see carfully there another tabbing box at bottom of the first one with name:????? ???
but the tabs are not working.
pls help
thx

This question has received the maximum number of answers.