Render form in template I have made the following .tpl.php template:

&lt;?php print drupal_render($element["term"]); ?&gt;
&lt;?php print drupal_render($element["search"]);?&gt;
&lt;?php print drupal_render($element["advanced_search"]);?&gt;
&lt;?php print drupal_render_children($element);?&gt;


But the form tag is not generated, so the form cannot be submitted ... what am i doing wrong?
You can add search box in a preprocess function in your template.php:

&lt;?php
/*
 *  Preprocess page.tpl.php to inject the $search_box variable back into D7.
 */
function MYTHEME_preprocess_page(&amp;$variables){
  $search_box = drupal_render(drupal_get_form('search_form'));
  $variables['search_box'] = $search_box;
}


Then you just need to print the variable in your page.tpl.php:

&lt;?php print $search_box; ?&gt;