<?php
session_start();
require_once 'includes/header.php';
require_once 'includes/config.php';
$error=false;
$errors=array();
// avoid user arriving to this page without logging in
if(!isset($_SESSION['user_logged_in']) && $_SESSION['user_logged_in']!=TRUE )
{
	header('Location:login.php');

}

?>
 <div class="content">
        <div class="container-fluid">
          <div class="row">
            <div class="col-md-12">
              <div class="card">
                <div class="card-header card-header-primary">
                  <h4 class="card-title">Add Trendyads-</h4>
                  <p class="card-category"></p>
                </div>
                <div class="card-body">

<?php

if (isset($error) && $error==false && isset($errors['success'])) {
	echo '<div class="alert alert-success" role="alert" id="success_message">Success <i class="glyphicon glyphicon-thumbs-up"></i> '.$errors['success'].'</div>';
} 

if (isset($error) && $error==true && isset($errors['error'])) {
	echo '<div class="alert alert-danger" role="alert" id="success_message">Success <i class="glyphicon glyphicon-thumbs-up"></i> '.$errors['error'].'</div>';
} 

?>

  <form role="form" method="post" action="http://app.trendinfotechs.com/api/add_imagebyfolder1.php" enctype="multipart/form-data">
   <div class="box-body">
   

   
   <div class="row">
   
  
   
    <div class="col-md-6">
	 <div class="form-group">
	<div class="file-field input-field">
      <div class="btn btn-primary">
        <span>Image</span>
        <textarea name="image"></textarea>
      </div>
      
    </div>
    </div>
	
   </div>
   
    <div class="col-md-6">
   
   <div class="form-group">
   <label>Name</label>
	<input type="text" name="leaderid" class="form-control">
	
   </div>
   </div>
   
   </div>
   
     <div class="row">
   
  
   
      
    <div class="col-md-6">
   
   <div class="form-group">
   <label>Views</label>
	<input type="text" name="folderid" class="form-control">
	
   </div>
   </div>
   
   </div>
   
   <div class="box-footer">
		<button type="submit" class="btn btn-primary">Save</button>
   </div>
			  
   </form>
  </div>
  </div>
  </div>
  </div>
  </div>
  </div>

<?php include_once 'includes/footer.php'; ?>