{"id":2265,"date":"2024-03-05T10:28:38","date_gmt":"2024-03-05T10:28:38","guid":{"rendered":"https:\/\/wpshortcode.org\/?p=2265"},"modified":"2024-03-05T10:28:39","modified_gmt":"2024-03-05T10:28:39","slug":"quick-contact-form","status":"publish","type":"post","link":"https:\/\/wpshortcode.org\/quick-contact-form\/","title":{"rendered":"Quick Contact Form Shortcode"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Below, you&#8217;ll find a detailed guide on how to add the <strong>Quick Contact Form Shortcode<\/strong> to your WordPress website, including its <strong>parameters<\/strong>, <strong>examples<\/strong>, and <strong>PHP function code<\/strong>. Additionally, we&#8217;ll assist you with common issues that might cause the Quick Contact Form Plugin shortcode not to show or not to work correctly.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Before starting, here is an overview of the Quick Contact Form Plugin and the shortcodes it provides:<\/p>\n\n\n<p>    <div class=\"plugin-info-box\">\n        <div class=\"top-main\">\n            <!-- SVG Image -->\n            <div class=\"plugin-image\">\n                <img decoding=\"async\" src=\"https:\/\/ps.w.org\/quick-contact-form\/assets\/icon-128x128.png?rev=1068066\" alt=\"Plugin Icon\" \/>\n            <\/div>\n            \n            <div class=\"plugin-descriptive-part\">\n                <!-- Plugin Name with Link -->\n\n                    <a class=\"plugin-title\" href=\"https:\/\/wordpress.org\/plugins\/quick-contact-form\" target=\"_blank\" rel=\"noopener\">\n                        Quick Contact Form                    <\/a>\n\n\n                <!-- Plugin Description -->\n                <p class=\"plugin-description\">\n                    &quot;Quick Contact Form is a WordPress plugin that allows you to easily create and embed contact forms. With its intuitive interface, you can customize forms to suit your needs.&quot;                <\/p>\n            <\/div>\n        <\/div>\n\n        <!-- Rating and Additional Info -->\n        <div class=\"plugin-meta\">\n            <span class=\"plugin-rating\">\n                <span class='stars'>\u2605\u2605\u2605\u2605\u2606<\/span> (20)\n            <\/span>\n            <span class=\"plugin-active-installs\">\n                <strong>Active Installs<\/strong>: 2000+\n            <\/span>\n            <span class=\"plugin-tested\">\n                <strong>Tested with<\/strong>: 6.3.2            <\/span>\n            <span class=\"plugin-php-version\">\n                <strong>PHP Version<\/strong>: 5.6            <\/span>\n        <\/div>\n\n        <!-- List of Included Shortcodes -->\n        <div class=\"plugin-shortcodes\">\n            <strong>Included Shortcodes:<\/strong>\n            <ul>\n                <li>[qcf]<\/li>            <\/ul>\n        <\/div>\n    <\/div>\n    <\/p>\n\n\n\n<div style=\"height:50px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Quick Contact Form [qcf] Shortcode<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The Quick Contact Form shortcode is a function that enables a specific form to be displayed. \n\n\n\nThis shortcode uses the &#8216;qcf_start&#8217; function, which accepts attributes for &#8216;id&#8217; and &#8216;form&#8217;. If an &#8216;id&#8217; is specified, it&#8217;s used; otherwise, the &#8216;form&#8217; attribute is used. The &#8216;id&#8217; is then sanitized to remove any non-alphabetic characters. Lastly, the function &#8216;qcf_loop&#8217; is called with the &#8216;id&#8217; as an argument, generating the desired form.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Shortcode<\/strong>: <code>[qcf]<\/code><\/p>\n\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">Parameters<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Here is a list of all possible qcf shortcode parameters and attributes:<\/p>\n\n\n<ul>\n<li><code>id<\/code> &#8211; Specifies the unique identifier of the contact form.<\/li>\n<li><code>form<\/code> &#8211; Provides an alternative identifier if &#8216;id&#8217; is not set.<\/li>\n<\/ul>\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">Examples and Usage<\/h3>\n\n\n<p><strong>Basic example<\/strong> &#8211; Displays a contact form by referencing the ID.<\/p>\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">[qcf id='contact_form_1' \/]<\/code><\/pre>\n\n\n<p><strong>Advanced examples<\/strong><\/p>\n<p>Displays a contact form by referencing the form title. If the form with the given ID is not found, it will try to load the form by the title.<\/p>\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">[qcf form='Contact Form 1' \/]<\/code><\/pre>\n\n\n<p>Displays a contact form by referencing both ID and form title. The form will first try to load by ID, but if not found, it will try to load by the title.<\/p>\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">[qcf id='contact_form_1' form='Contact Form 1' \/]<\/code><\/pre>\n\n\n<p>Note: In the above examples, &#8216;contact_form_1&#8217; and &#8216;Contact Form 1&#8217; are just placeholders. Replace them with your actual form ID or title.<\/p>\n\n\n<div style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h3 class=\"wp-block-heading\">PHP Function Code<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">In case you have difficulties debugging what causing issues with <code>[qcf]<\/code> shortcode, check below the related PHP functions code.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Shortcode line<\/strong>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">add_shortcode( 'qcf', 'qcf_start' );<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>Shortcode PHP function<\/strong>:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: php; light: false; title: ; toolbar: true; notranslate\" title=\"\">\nfunction qcf_start( $atts )\n{\n    $atts = shortcode_atts( array(\n        &#039;id&#039;   =&gt; &#039;&#039;,\n        &#039;form&#039; =&gt; &#039;&#039;,\n    ), $atts );\n    \n    if ( !empty($atts&#91;&#039;id&#039;]) ) {\n        $id = $atts&#91;&#039;id&#039;];\n    } else {\n        $id = $atts&#91;&#039;form&#039;];\n    }\n    \n    $id = preg_replace( &quot;\/&#91;^A-Za-z]\/&quot;, &#039;&#039;, $id );\n    return qcf_loop( $id );\n}\n<\/pre><\/div>\n\n\n<p class=\"wp-block-paragraph\"><strong>Code file location<\/strong>:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">quick-contact-form\/quick-contact-form\/legacy\/quick-contact-form.php<\/code><\/pre>\n\n\n\n<div style=\"height:50px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Now that you&#8217;ve learned how to embed the <strong>Quick Contact Form Plugin shortcode<\/strong>, understood the parameters, and seen code examples, it&#8217;s easy to use and debug any issue that might cause it to &#8216;not work&#8217;. If you still have difficulties with it, don&#8217;t hesitate to leave a comment below.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Below, you&#8217;ll find a detailed guide on how to add the Quick Contact Form Shortcode to your WordPress website, including its parameters, examples, and PHP function code. Additionally, we&#8217;ll assist you with common issues that might cause the Quick Contact Form Plugin shortcode not to show or not to work correctly. Before starting, here is [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"name":"Quick Contact Form","slug":"","version":"8.0.6.9","author":"<a href=\"https:\/\/fullworks.net\/\">Fullworks<\/a>","icons":"https:\/\/ps.w.org\/quick-contact-form\/assets\/icon-128x128.png?rev=1068066","plugin_tags":"{\"contact-form\":\"contact form\",\"form\":\"form\"}","author_profile":"https:\/\/profiles.wordpress.org\/fullworks\/","requires":"4.6","tested":"6.3.2","requires_php":"5.6","rating":98,"num_ratings":20,"active_installs":2000,"downloaded":154822,"last_updated":"2023-08-01 2:56pm GMT","added":"2012-03-15","homepage":"https:\/\/fullworks.net\/products\/quick-contact-form","short_description":"An easy to set up, plug and play contact form with a huge range of options and styles. A beginner friendly WordPress contact form plugin.","description":"\"Quick Contact Form is a WordPress plugin that allows you to easily create and embed contact forms. With its intuitive interface, you can customize forms to suit your needs.\"","shortcodes":"[\"qcf\"]","footnotes":""},"categories":[1],"tags":[],"class_list":["post-2265","post","type-post","status-publish","format-standard","hentry","category-plugins"],"_links":{"self":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts\/2265","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/comments?post=2265"}],"version-history":[{"count":1,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts\/2265\/revisions"}],"predecessor-version":[{"id":2787,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/posts\/2265\/revisions\/2787"}],"wp:attachment":[{"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/media?parent=2265"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/categories?post=2265"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpshortcode.org\/wp-json\/wp\/v2\/tags?post=2265"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}