Entity form in ctools modal
I recommend trying to use Ctools Automodal module. It's really easy to use just look at the project page:


  Provides automatic modal support for any hook_menu() paths that have
  'modal' => TRUE defined. This makes it easy to add optional modal
  support in any contrib module and helps reduce the burden on module
  developers to support modals.
  
  Example Usage


&lt;?php
function mymodule_menu() {
  $items['mymodule/form'] = array(
    'page callback' =&gt; 'drupal_get_form',
    'page arguments' =&gt; array('mymodule_form'),
    'access arguments' =&gt; array('administer mymodule'),
    'modal' =&gt; TRUE, // This line is where the magic happens.
  );
}
?&gt;