title: How to set disabled select option in Laravel?
body: <p>In a controller function, I extract all the <code>attributes</code> and the attributes that I have already used.</p>
  
  <p>All the attributes:</p>
  
  <pre><code>$attributeNames = array('' =&gt; 'Select Attribute Name') + AttributeName::lists('name' , 'id');
  </code></pre>
  
  <p>Already Taken Attributes:</p>
  
  <pre><code>$selectedAttributeNames = $xmlDocument-&gt;masterInformation-&gt;masterAttributes;
  </code></pre>
  
  <p>How can I make the <code>selectedAttributeNames</code> as <code>disable</code> please?</p>
  
  <p>Here is the output of <code>var_dump($selectedAttributeNames)</code>:</p>
  
  <pre><code>object(Illuminate\ Database\ Eloquent\ Collection) #312 (1) {
      ["items":protected]= &gt; array(1) {
          [0] =&gt; object(MasterAttribute) #310 (20) {
              ["table":protected]= &gt; string(16) "master_attribute"
              ["guarded": protected] =&gt; array(1) {
                  [0] =&gt; string(2) "id"
              }
              ["connection": protected] =&gt; NULL["primaryKey": protected] =&gt; string(2) "id"
              ["perPage": protected] =&gt; int(15)["incrementing"] =&gt; bool(true)["timestamps"] =&gt; bool(true)["attributes": protected] =&gt; array(7) {
                  ["id"] =&gt; int(1)["xpath"] =&gt; string(17)
                  "this is the xpath"
                  ["attribute_name_id"] =&gt; int(1)["master_information_id"] =&gt; int(6)["default_value"] =&gt; string(25) "This is the default value"
                  ["created_at"] =&gt; string(19) "2014-07-19 17:53:55"
                  ["updated_at"] =&gt; string(19) "2014-07-19 17:53:55"
              }
              ["original": protected] =&gt; array(7) {
                  ["id"] =&gt; int(1)["xpath"] =&gt; string(17) "this is the xpath"
                  ["attribute_name_id"] =&gt; int(1)["master_information_id"] =&gt; int(6)["default_value"] =&gt; string(25) "This is the default value"
                  ["created_at"] =&gt; string(19) "2014-07-19 17:53:55"
                  ["updated_at"] =&gt; string(19) "2014-07-19 17:53:55"
              }
              ["relations": protected] =&gt; array(0) {}
              ["hidden": protected] =&gt; array(0) {}
              ["visible": protected] =&gt; array(0) {}
              ["appends": protected] =&gt; array(0) {}
              ["fillable": protected] =&gt; array(0) {}
              ["dates": protected] =&gt; array(0) {}
              ["touches": protected] =&gt; array(0) {}
              ["observables": protected] =&gt; array(0) {}
              ["with": protected] =&gt; array(0) {}
              ["morphClass": protected] =&gt; NULL["exists"] =&gt; bool(true)
          }
      }
  }
  </code></pre>