{* header *}{include file="1549864.tpl"}

{if $user_id eq false}
<center>{* loginbox *}{include file="1549885.tpl"}</center><br><br>
{/if}

<table width='100%'><tr>

<!--left column-->
<td valign='top' align='center' width='23%'>
{* node_settings *}
{include file="1549925.tpl"}

{* get_poll_box *}
{include file="1549834.tpl"}
<br>
{*get_bookmark_statistics_box : include file="1549386.tpl" *}
<img src=/images/nodes/1/0/101.gif border=1>
</td>
<!--end of left column-->

<!--main central column-->
<td width=666 valign='top'>
{*node_content*}
{include file="1549916.tpl"}
{*showing form for adding child node*}
<form enctype="multipart/form-data" action='/id/{$node.node_id}/{if $action neq
false}{$action}{/if}'method='post' name='formular'>
{if $permissions.w eq true}
  {*addnode ---------- *}






<!-- ADDNODE | MARIN -->
{if $permissions.w eq true}

<div class='add_title' style='margin-bottom:2pt;'>
  title or keywords::
  <input type='text' name='node_name' id='node_name' value='{$post_vars.node_name}'>
  <input type='checkbox' name='no_html' value='yes'>&nbsp;NO HTML
</div>

<textarea name='node_content' id='node_content'>{$post_vars.node_content|escape:"html"|stripslashes}
</textarea>

<div class='toolbar'>
  <input type='submit' value='add' name='event' />
  <input type='submit' value='preview' name='template_event' class='preview_button' />
  <input type='text' name='template_id' size=5 value='{if $node.template_id == 2}3{else}4{/if}'
title='[submission: 4 | forum: 3 | nodeshell: 2 | article: 5 | data: 12]' />
  <select name='sel_help' onchange='document.getElementById("node_content").innerHTML += sel_help.value;' style='margin-right:4px'>
    <option value='' selected>helpful</option>
    <option value='<a href="" target="_blank"></a>'>link</option>
    <option value='<img src="">'>image</option>
    <option value='<b></b>'>bold</option>
    <option value='<i></i>'>italic</option>
  </select>
  {* movement *}{include file="1549913.tpl"}
  <input type='submit' value='filter_by' name='template_event' />
  <select name='search_type' style=''>
    <option value='content'>content</option>
    <option value='user'>user</option>
  </select>
  <input type='hidden' name='node_parent' value='{$node.node_id}'>
</div>
  {* owner_toolbar *}{include file="1549939.tpl"}
{/if}

<div class='add_put'>
  <input type='submit' value='delete' name='event' />
   <span class='add_k_cmnt'>&nbsp; u have {$user_k} </span>
   <input type='submit' value='K' name='event' />
   <input type='submit' value='delete_hardlink' name='event' style='margin-right:1.5em' />
   <input type='submit' value='put' name='event' /> into
   <input type='text' name='nodeshell_id' value='' style="width: 80px" />
   <select name='nodeshell_id_select'>
    {foreach from=$bookmarks key=id item=name}<option value='{$id}'>{$name|strip_tags|truncate:32:"":true}</option>{/foreach}
   </select>
   <input type='submit' value='go_to' name='event' />
</div>
<br />


{*add_movie*}
{if $permissions.w eq true}


{literal}
<script type="text/javascript">
<!--

function open_win() {
  var add_m = document.getElementById('add_m');
  if(add_m.style.display == 'block' || add_m.style.display == '') {
    add_m.style.display = 'none';
  } else {
    add_m.style.display = 'block';
  }
}

function naplnData(status) {
  var textarea = document.getElementById('node_content');
  var node_name = document.getElementById('node_name')
  var movie = document.getElementById('movie');
  var genre = document.getElementById('genre');
  var year = document.getElementById('year');
  var director = document.getElementById('director');
  var img1 = document.getElementById('img1');
  var img2 = document.getElementById('img2');
  var img3 = document.getElementById('img3');
  var img4 = document.getElementById('img4');
  var imdb = document.getElementById('imdb');
  var csfd = document.getElementById('csfd');
  var subs = document.getElementById('subs');
  var trailer = document.getElementById('trailer');
  var custom_name = document.getElementById('custom_name');
  var custom_text = document.getElementById('custom_text');
  var format = document.getElementById('format');
  var bitrate_v = document.getElementById('bitrate_v');
  var bitrate_a = document.getElementById('bitrate_a');
  var resolution = document.getElementById('resolution');
  var codec = document.getElementById('codec');
  var duration = document.getElementById('duration');
  var size = document.getElementById('size');
  var youtube = document.getElementById('youtube');
  var download = document.getElementById('download');
  var info = document.getElementById('info');
  

  var startDiv = '<div style="color:#777;width:60px;text-align:right;float:left">';

  var newData = '<div style="width:610px;float:left">';
  if (status == "plus" && textarea.value ) {
    var newData = textarea.value + '<br /><hr style="padding:0px; border: 1px #444 solid" /><br /> <div style="width:610px;float:left">';
  }
  if (status != "plus" && movie.value) {
    node_name.value = movie.value;
  } else {
    node_name.value = '';
  }

  if (movie.value) { newData = newData + startDiv + 'movie |&nbsp;</div><b style="font-size:12px;"> ' + movie.value + ' </b><br />'; }
  if (genre.value) {newData = newData + startDiv + 'genre |&nbsp;</div> ' + genre.value + ' <br />'; }
  if (year.value) {newData = newData + startDiv + 'year |&nbsp;</div> ' + year.value + ' <br />'; }
  if (director.value) {newData = newData + startDiv + 'director |&nbsp;</div> ' + director.value + ' <br />'; }
  if (movie.value || genre.value || year.value || director.value ) { newData = newData + '<br />'; }
  if (img1.value) {newData = newData + '<img src="' + img1.value + '" /><br /><br /> '; }
  if (img2.value) {newData = newData + '<img src="' + img2.value + '" /><br /><br /> '; }
  if (img3.value) {newData = newData + '<img src="' + img3.value + '" /><br /><br /> '; }
  if (img4.value) {newData = newData + '<img src="' + img4.value + '" /><br /><br /> '; }
  if (imdb.value) {newData = newData + startDiv + 'imdb |&nbsp;</div> ' + imdb.value + ' <br />'; }
  if (csfd.value) {newData = newData + startDiv + 'csfd |&nbsp;</div> ' + csfd.value + ' <br />'; }
  if (subs.value) { newData = newData + startDiv + 'subs |&nbsp;</div> ' + subs.value + ' <br />'; }
  if (trailer.value) { newData = newData + startDiv + 'trailer |&nbsp;</div> ' + trailer.value + ' <br />'; }
  if (custom_name.value || custom_text.value) {
    newData = newData + startDiv + custom_name.value + ' |&nbsp;</div> ' + custom_text.value + ' <br />';
  }
  
  if (format.value) {newData = newData + startDiv + 'format |&nbsp;</div> ' + format.value + ' <br />';  }
  if (size.value) {newData = newData + startDiv + 'size |&nbsp;</div> ' + size.value + ' <br />';  }
  if (bitrate_v.value) {newData = newData + startDiv + 'bitrate V |&nbsp;</div> ' + bitrate_v.value + ' <br />';  }
  if (bitrate_a.value) {newData = newData + startDiv + 'bitrate A |&nbsp;</div> ' + bitrate_a.value + ' <br />';  }

  if (duration.value) {newData = newData + startDiv + 'duration |&nbsp;</div> ' + duration.value + ' <br />';  }
  if (resolution.value) {newData = newData + startDiv + 'resolution |&nbsp;</div> ' + resolution.value + ' <br />';  }
  if (codec.value) {newData = newData + startDiv + 'codec |&nbsp;</div> ' + codec.value + ' <br />';  }

  if (download.value) {
    newData = newData + '<div style="overflow:hidden">' + startDiv + 'download |&nbsp;</div><div style="float:left; width:90%;"> ' + download.value + ' </div></div>';
  }
  if (info.value) {
    newData = newData + '<div style="overflow:hidden">' + startDiv +' info |&nbsp;</div><div style="float:left; width:90%;"> ' + info.value + ' </div></div>';
  }
  newData = newData + '</div>';
  textarea.value = newData;

  if (status == "plus") {
    movie.value = '';
    genre.value = '';
    year.value = '';
    director.value = '';
    img1.value = '';
    img2.value = '';
    img3.value = '';
    img4.value = '';
    imdb.value = '';
    csfd.value = '';
    subs.value = '';
    trailer.value = '';
    custom_name.value = '';
    custom_text.value = '';
    format.value = '';
    bitrate_v.value = '';
    bitrate_a.value = '';
    resolution.value = '';
    codec.value = '';
    duration.value = '';
    size.value = '';
    download.value = '';
    info.value = '';
    
  }


}

//-->
</script>

<style type="text/css" media="screen">
div.btn {background-color:#222; border:1px #444 solid; padding:2px 12px; margin:3px 0 0 0; color:#fff; font-weight: bold; width: 70px; text-align:center; cursor:hand; }
div.btn:hover { background-color:#333; color:#fff; }
#add_m div.btn {background-color:#333; border:1px #444 solid; padding:2px 12px; display:block; margin:3px 0px 3px 10px; float:left; color:#fff; font-weight: bold;}
#add_m div.btn:hover {background-color:#444; border:1px #555 solid; color:#fff; }
#add_m {background-color:#111; border:1px #444 solid; width:650px; overflow:hidden; margin: 0;}
#add_m input {width:250px;}
#add_m input.mini {width:50px;margin-left:5px;}
#add_m input.img {width:140px;}
#add_m span.popis {color:#777 ;width:60px; text-align:right; float:left; margin-right:2px;}
#add_m .left {float:left;  overflow:hidden; width: 320px; margin:10px 0;}
#add_m textarea {width:250px; height:125px; font-family: tahoma;font-size: 10px;}
#add_m .bottom {background-color:#222; overflow: hidden; margin: 10px 0 0 0;}
</style>

{/literal}

<div class="btn" onclick="open_win()">add movie</div>
<div id="add_m" style="display:none">
  <div class="left">
    <span class="popis"><b>movie</b>:</span> <input type='text' id='movie' name='movie' /><br />
    <span class="popis">genre:</span> <input type='text' id='genre' name='genre' style="width:160px; float:left;" />
    <span class="popis" style="width:35px">year:</span> <input type='text' id='year' name='year' style="width:53px" /><br />
    <span class="popis">director:</span> <input type='text' id='director' name='director' /><br /><br />
    <span class="popis">imdb:</span> <input type='text' id='imdb' name='imdb' /><br />
    <span class="popis">csfd:</span> <input type='text' id='csfd' name='csfd' /><br />
    <span class="popis">subs:</span> <input type='text' id='subs' name='subs' /><br />
    <span class="popis">trailer:</span> <input type='text' id='trailer' name='trailer' /><br />
    <input type='text' id='custom_name' name='custom_name' class="mini" />: <input type='text' id='custom_text' name='custom_text' /><br /><br />

    <span class="popis">format:</span> <input type='text' id='format' name='format' style="width:92px; float:left;" />
    <span class="popis" style="width:60px">size:</span> <input type='text' id='size' name='size' style="width:92px" /><br />

    <span class="popis">bitrate V:</span> <input type='text' id='bitrate_v' name='bitrate_v' style="width:92px; float:left;" />
    <span class="popis" style="width:60px">bitrate A:</span> <input type='text' id='bitrate_a' name='bitrate_a' style="width:92px" /><br />

    <span class="popis">duration:</span> <input type='text' id='duration' name='duration' style="width:92px; float:left;" />
    <span class="popis" style="width:60px">resolution:</span> <input type='text' id='resolution' name='resolution' style="width:92px" /><br />
    <span class="popis">codec:</span> <input type='text' id='codec' name='codec' /><br />
<!--  format, duration, size -->
<!--  bitrate_v bitrate_a resolution codec -->
    
  </div>
  <div class="left">
    <span class="popis">download:</span> <textarea name='download' id='download'></textarea><br />
    <span class="popis">info:</span> <textarea name='info' id='info'></textarea><br />
  </div>
  <span class="popis">images:</span>
  <input type='text' id='img1' name='img1' class="img" />
  <input type='text' id='img2' name='img2' class="img" />
  <input type='text' id='img3' name='img3' class="img" />
  <input type='text' id='img4' name='img4' class="img" />
  <br />

  <div class="bottom">
    <div class="btn" onclick='naplnData()'>add</div>
    <div class="btn" onclick='naplnData("plus")'>add multiple</div>
  </div>
</div>

{/if}



{* get_node_userlist *}{include file="1549803.tpl"}
{*addnode ---------- end *}
{else}{* read-only *}{include file="2264143.tpl"}
{/if}
{*get_threaded_children*}{include file="1549839.tpl" children_type=4}
</form>
<!--end of central column-->
</td></tr></table>
{*footer*}{include file="1549377.tpl"}