function Contact_Form_maker_fornt_end_main($content) { if (!get_option('form_maker_pro_active', false)) { $pattern = '[\\[contact_form id="([0-9]*)"\\]]'; $count_forms_in_post = preg_match_all($pattern, $content, $matches_form); for ($jj = 0; $jj < $count_forms_in_post; $jj++) { $padron = $matches_form[0][$jj]; $replacment = contact_form_front_end($matches_form[1][$jj]); $content = str_replace($padron, $replacment, $content); } } return $content; }
function widget($args, $instance) { extract($args); $title = apply_filters('widget_title', $instance['title']); // Before widget echo $before_widget; // Title of widget if ($title) { echo $before_title . $title . $after_title; } // echo $title; global $contact_form_maker_function__once; if ($contact_form_maker_function__once) { $contact_form_maker_function__once = 0; } require_once "front_end_contact_form.php"; echo contact_form_front_end($instance['form_id']); // After widget echo $after_widget; }