<!-- Start right content -->
<div class="content-page">
    <!-- ============================================================== -->
    <!-- Start Content here -->
    <!-- ============================================================== -->
    <div class="content">
        <!-- Page Heading Start -->
        <?php /*<div class="page-heading">
            <h1><i class='fa fa-file'></i> <?php echo $viewTitle;?></h1>
            <h3><?php echo $viewTitle;?></h3>
        </div>*/?>
        <!-- Page Heading End-->

        <div class="row">

            <div class="col-sm-12 portlets">

                <div class="widget">
                    <div class="data-table-toolbar">
                        <div class="row">
                            <div class="col-md-4">
                                <h4><strong> Yeni <?php echo $viewTitle;?> içeriği </strong> ekliyorsunuz...</h4>
                            </div>
                            <div class="col-md-8">
                                <div class="toolbar-btn-action">
                                    <a href="<?php echo base_url("backend/kategoriler");?>" class="btn btn-red-1"><i class="fa fa-list"></i> <?php echo $viewTitle;?> Liste</a>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="widget-content padding">
                        <div id="basic-form">

                            <?php
                            if (isset($form_hatasi))
                            {
                            ?>
                                <div class="alert alert-danger alert-dismissable">
                                    <button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
                                    <?php 
                                        $titleError         = form_error("title");
                                        $aciklamaError      = form_error("aciklama");
                                        $pageTitleerror     = form_error("pagetitle");
                                        $metadescError      = form_error("metadesc");
                                        $metakeyError       = form_error("metakey");

                                        if ($titleError <> "")      {echo form_error("title")."<br />";}
                                        if ($aciklamaError <> "")   {echo form_error("aciklama")."<br />";}
                                        if ($pageTitleerror <> "")  {echo form_error("pagetitle")."<br />";}
                                        if ($metadescError <> "")   {echo form_error("metadesc")."<br />";}
                                        if ($metakeyError <> "")    {echo form_error("metakey")."<br />";}
                                    ?>
                                </div>
                            <?php
                            }
                            ?>

                            <form role="form" action="<?php echo base_url("backend/kategoriler/formKaydet");?>" method="post">
                                 <div class="form-group">
                                    <h4><strong>Üst Kategori</strong> </h4>
                                    <select class="form-control" name="kategori" style="font-size: 13pt;">
                                        <option value="">.... Üst Kategori Seçiniz ...</option>
                                        <?php get_category();?>
                                    </select>    
                                </div>

                                <!-- include summernote css/js -->
                                <script src="https://cdn.ckeditor.com/4.7.3/standard/ckeditor.js"></script>

                                <br />
                                <?php
                                for ($i=1;$i<=5;$i++)
                                {
                                    if ($i == 1) {$dil = "TR"; $dkod = "tr";}
                                    if ($i == 2) {$dil = "EN"; $dkod = "en";}
                                    if ($i == 3) {$dil = "AR"; $dkod = "ar";}
                                    if ($i == 4) {$dil = "RU"; $dkod = "ru";}
                                    if ($i == 5) {$dil = "FR"; $dkod = "fr";}
                                    /*if ($i == 6) {$dil = "DL"; $dkod = "dl";}
                                    if ($i == 7) {$dil = "ES"; $dkod = "es";}*/
                                ?>
                                <div class="form-group">
                                    <h4><strong>Başlık - <?php echo $dil;?></strong> </h4>
                                    <input type="text" class="form-control" name="title_<?php echo $dkod;?>">
                                    <?php if (isset($form_hatasi)) {?>
                                        <small class="pull-right input-form-error"><?php echo form_error("title_tr");?></small>
                                    <?php }?>
                                </div>

                                <br /><br />
                                <?php
                                }
                                ?>
                              
                                <br />
                                
                                <div class="form-group">
                                    <label><h4><strong>Meta Keywords</strong> </h4></label>
                                    <textarea class="form-control" name="metakey" style="height: 140px; resize: none;" placeholder="Meta Keywords Kelimeler"><?php echo isset($form_hatasi) ? set_value("metakey") : "";?></textarea>
                                </div>


                                <div class="form-group pull-right">
                                    <button type="submit" class="btn btn-info">Kaydet</button>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>

            </div>

        </div>
        <?php $this->load->view("includes/footer");?>
    </div>
    <!-- ============================================================== -->
    <!-- End content here -->
    <!-- ============================================================== -->

</div>
<!-- End right content -->