
.page-header
  %h2
    %li.icon-folder-open
    = Yii::t("app", "Edit")

-$directory = pathinfo($filename,PATHINFO_DIRNAME)
%h4
  =t('Current file').':'
  =$filename
  %font(size="2pt")
    %a(href="#{url('debug/ViewAsText',array('filename'=>$filename))}" onclick="return confirm('#{t('Confirm')}?');")='['.t('View').']'  
%h5
  =t('Return to').' '
  %a(href="#{url('debug/fileexplorer',array('path'=>$directory))}" onclick="return confirm('#{t('Confirm')}?');")
    =$directory

%form(method="post")
  %input(type="hidden" name="filename" value="#{$filename}")
  %input(type="hidden" name="action" value="write")
  %textarea#fileContent(name="content" cols="10" rows="30" style="width: 100%; height: 100%; font-family: monospace;")=$filecontent
  %input(type="submit")

%script
  !="$('#fileContent').focus()"