<?php /** * Provide a public-facing view for the plugin * * This file is used to markup the public-facing aspects of the plugin. * * @link http://example.com * @since 1.0.0 * * @package simple_contact_forms * @subpackage simple_contact_forms/public/partials */ ?> <?php // Add the file with the main class require_once plugin_dir_path(dirname(__FILE__)) . 'partials/classes/formconstructor.php'; // Create the form constructor class $form = new scf_FormConstructor(); // Start the form constructor class $form->init($sc_options);
/** * Initialize the view on the frontend with a function * * @since 1.0.0 */ function simple_contact_form($sc_options = array()) { // Add the file with the main class require_once plugin_dir_path(dirname(__FILE__)) . 'public/partials/classes/formconstructor.php'; // Create the form constructor class $form = new scf_FormConstructor(); // Start the form constructor class $html = $form->init($sc_options); // Return the $html return $html; }