I placed the cck_video in my nodes. But if a node have only title/text and NO video (no upload), then there is a empty place in the node.

CommentFileSizeAuthor
#3 Output is "1"12.18 KBbreitner
#3 Code from output3.19 KBbreitner

Comments

breitner’s picture

and if you have 3 nodes on the frontpage then you have 3 javascript in the footer:

    </div> <!-- /container -->
  </div>
<!-- /layout -->

  <script type="text/javascript">
<!--//--><![CDATA[//><!--
flowplayer("player", "/sites/all/libraries/flowplayer/flowplayer-3.2.8.swf");
//--><!]]>
</script>
<script type="text/javascript">
<!--//--><![CDATA[//><!--
flowplayer("player", "/sites/all/libraries/flowplayer/flowplayer-3.2.8.swf");
//--><!]]>
</script>
<script type="text/javascript">
<!--//--><![CDATA[//><!--
flowplayer("player", "/sites/all/libraries/flowplayer/flowplayer-3.2.8.swf");
//--><!]]>
</script>
  </body>
</html>
drupalnesia’s picture

6.x-1.0-alpha3:
a. Disable autoplay for Flowplayer
b. Empty output if CCK Filefield is empty

breitner’s picture

StatusFileSize
new3.19 KB
new12.18 KB

Sorry, but the empty output is NOT really empty. Now there is a "1" in the output:

<div class="field field-type-filefield field-field-video">
<div class="field-items">
<div class="field-item odd"> 1 </div>
</div>
</div>
drupalnesia’s picture

Status: Active » Needs work

Open cck_video.module and edit line 102

if (empty($element['#item'][fid])) {
    return TRUE;
}

to:

if (empty($element['#item'][fid])) {
    return;
}

See if this works fine, I will apply to alpha4 version, thanks.

drupalnesia’s picture

Status: Needs work » Fixed

6.x-1.0-alpha4:
a. New: support multi videos on same page
b. Fixed: Empty output if CCK Filefield is empty
c. Fixed: Avoid drupal_add_js run twice on footer

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.