<html lang="zh-tw">
<head>
  <title>Bootstrap Example</title>
  <meta http-equiv="content-Type" content="text/html;charset=UTF8"> 
  <meta name="viewport" content="width=device-width, initial-scale=1">

  <link rel="stylesheet" href="{{ URL::asset('css/bootstrap.css')}}">
  <link rel="stylesheet" href="{{ URL::asset('css/slider_video.css')}}">
  <link href="https://cdnjs.cloudflare.com/ajax/libs/video.js/6.0.0-RC.5/alt/video-js-cdn.min.css" rel="stylesheet">
  
  <script src="{{ URL::asset('js/jquery.min.js')}}"></script>
  <script src="{{ URL::asset('js/bootstrap.min.js')}}"></script>
  <script src="{{ URL::asset('js/slider.js')}}"></script>

  <script src="https://cdnjs.cloudflare.com/ajax/libs/video.js/6.0.0-RC.5/video.js"></script>

  <script src="https://cdnjs.cloudflare.com/ajax/libs/videojs-contrib-hls/5.3.3/videojs-contrib-hls.js"></script>


</head>

<body>
<nav class="navbar navbar-inverse">
    <div class="container-fluid">
      <div class="navbar-header">
        <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
          <span class="icon-bar"></span>
          <span class="icon-bar"></span>
          <span class="icon-bar"></span>                        
        </button>
        <div id="mySidenav" class="sidenav">
                  @foreach($result as $results)
                  <a href="{{$results->path_dir}}">{{$results->path_name}}</a>
                        
                  @endforeach
                      
        </div>
        <div id="main">
            <span >&#9776;</span>
        </div>
      </div>
      <div class="collapse navbar-collapse" id="myNavbar">
        <ul class="nav navbar-nav">
          <li class="active"><a href="page">Home</a></li>
          <li class="dropdown">
            <a class="dropdown-toggle" data-toggle="dropdown" href="#">Page 1 <span class="caret"></span></a>
            <ul class="dropdown-menu">
              <li><a href="#">Page 1-1</a></li>
              <li><a href="#">Page 1-2</a></li>
              <li><a href="#">Page 1-3</a></li>
            </ul>
          </li>
        </ul>
        <form class="navbar-form navbar-left" action="#">
          <div class="input-group">
            <input type="text" class="form-control" placeholder="Search">
            <div class="input-group-btn">
              <button class="btn btn-default" type="submit">
                <i class="glyphicon glyphicon-search"></i>
              </button>
            </div>
          </div>
        </form>
        <ul class="nav navbar-nav navbar-right">
            <!-- 判斷用戶是否登入 登入後顯示user-icon，未登入則顯示login-icon -->
            @if (Session::has('ac'))
              <li><a id="user-icon" ><span class="glyphicon glyphicon-user"></span></a></li>    
            
            @else
              <li><a ><span href="#signup" class="glyphicon glyphicon-log-in" data-toggle="modal" data-target=".bs-modal-sm"></span> Login</a></li>
            @endif
                
        </ul>
      </div>
    </div>
</nav>


<div class="container">
  <div id="right" class="slider-right"><!--灰色背景--></div>
  <div id="user-bar" class="user-menu">
    <a href="#">Page 1-1</a>
    <a ><span href="#logout" onclick="logout()" class="glyphicon glyphicon-log-out"></span> Logout</a>
  </div>
  <!-- Modal START -->
  @include('modal')
  <!-- Modal END -->

  @include($page)

</div>
<script>
    function logout() {
      var r = confirm("是否登出")
      if (r == true) {
 
        parent.location.href='logout'; 
      }
    }
</script>   
<script src="{{ URL::asset('js/play-video.js') }}"></script>
</body>
</html>


