Embedding a form in the theme/Header/Footer

Liferay DXP

Crete your form: Login to your site and go to Control Panel -> Content and data -> Forms -> Create your form

Add code to display form Portlet  n your Theme/Header/Footer  : In your portal_normal.ftl or other corresponding file where you want to add the form place the following code:        
        <@liferay_portlet["runtime"]
              portletName="com_liferay_dynamic_data_mapping_form_web_portlet_DDMFormPortlet"    
              defaultPreferences="${freeMarkerPortletPreferences}"
        />

and deploy your theme. 

After refreshing your page you will see the the form portlet on the page. 

Select your form using the form portlet's UI.

Navigate to other pages to confirm that your form shows at every page.