title: Comparing strings in laravel 5 blade
body: <p>I have this in my blade file:</p>
  
  <pre><code> &lt;select class="form-control" name="category" id="category"&gt;
     @foreach ($category as $h)
       @if ({{$h-&gt;id}} == {{$directory-&gt;category}})
        &lt;option value="{{$h-&gt;id}}" selected&gt;{{$h-&gt;name}}&lt;/option&gt;
       @else
        &lt;option value="{{$h-&gt;id}}"&gt;{{$h-&gt;name}}&lt;/option&gt;
       @endif
     @endforeach
  &lt;/select&gt;
  </code></pre>
  
  <p>and controller:</p>
  
  <pre><code>    $directory= Directory::find($id);
      $category = StoreCategory::all();
      return view('edit')-&gt;with('category', $category)-&gt;with('directory', $directory);
  </code></pre>
  
  <p>Upon opening edit, I am getting "syntax error, unexpected '&lt;'"</p>
  
  <p>Tried removing the if-else condition and it is working fine.</p>