title: How to create self referential relationship in laravel?
body: <p>I am new to Laravel. I Just want to create a self referential model. For example, I want to create a product category in which the field <code>parent_id</code> as same as product category id. How is this possible? </p>
  
  <p>Model Shown below</p>
  
  <pre><code>class Product_category extends Eloquent 
  {
      protected $guarded = array();
  
      public static $rules = array(
          'name' =&gt; 'required',
          'parent_id' =&gt; 'required'
      );
  
       function product_category()
      {
          return $this-&gt;belongsto('Product_category','parent_id');
      }
  }
  </code></pre>
  
  <p>It results Maximum function nesting level of '100' reached, aborting! Error</p>