How to add exposed form block to .tpl.php I've added this code to preprocess function but it dosen't work :
in preprocess :

//edit_search_api_views_fulltext is the form_id of exposed form block;
$vars['custom_search'] = drupal_render(drupal_get_form("edit_search_api_views_fulltext"));


in tpl.php

print $custom_search;


What I'm missing ?
You want to print an exposed block in tpl, right? I am using this in drupal 7

&lt;?php 
  $block = block_load('views', '-exp-VIEWNAME-DISPLAYNAME'); 
  $output = drupal_render(_block_get_renderable_array(_block_render_blocks(array($block)))); 
  print $output; 
?&gt;


for example 

&lt;?php
  $search_block = block_load('views', '-exp-cruise_package-page');
  $output =  drupal_render(_block_get_renderable_array(_block_render_blocks(array($search_block)))); 
  print $output; 
?&gt;