Changeset 3319446
- Timestamp:
- 06/29/2025 12:33:52 PM (9 months ago)
- Location:
- madquick-ppg
- Files:
-
- 8 added
- 11 edited
- 1 copied
-
assets/logo-128x128.png (modified) (previous)
-
tags/1.0.2 (copied) (copied from madquick-ppg/trunk)
-
tags/1.0.2/assets/css/home-page.css (modified) (1 diff)
-
tags/1.0.2/assets/css/plugin-page.css (modified) (1 diff)
-
tags/1.0.2/assets/js/generate-policy.js (modified) (4 diffs)
-
tags/1.0.2/madquick-ppg.php (modified) (1 diff)
-
tags/1.0.2/pages (added)
-
tags/1.0.2/pages/madquick-ppg-create.php (added)
-
tags/1.0.2/pages/madquick-ppg-help.php (added)
-
tags/1.0.2/pages/madquick-ppg-main.php (added)
-
tags/1.0.2/readme.txt (modified) (4 diffs)
-
trunk/assets/css/home-page.css (modified) (1 diff)
-
trunk/assets/css/plugin-page.css (modified) (1 diff)
-
trunk/assets/js/generate-policy.js (modified) (4 diffs)
-
trunk/madquick-ppg.php (modified) (1 diff)
-
trunk/pages (added)
-
trunk/pages/madquick-ppg-create.php (added)
-
trunk/pages/madquick-ppg-help.php (added)
-
trunk/pages/madquick-ppg-main.php (added)
-
trunk/readme.txt (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
madquick-ppg/tags/1.0.2/assets/css/home-page.css
r3239886 r3319446 1 /* create page */ 2 3 .wrap { 4 background: #fff; 5 padding: 12px; 6 min-height: 100vh; 7 } 8 1 9 .wrap-main { 2 10 background-color: #ffffff; 3 padding: 30px;11 padding: 16px; 4 12 border-radius: 8px; 5 13 box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); 6 14 max-width: 800px; 7 margin: 12px auto;15 /* margin: 12px auto; */ 8 16 } 9 17 10 18 #privacy-policy-form { 11 margin-top: 12px; 12 } 13 14 h1 { 15 line-height: 45px; 16 font-weight: bold; 17 margin-bottom: 30px; 18 padding-bottom: 20px; 19 border-bottom: 2px solid #eee; 20 font-size: 28px; 21 color: #333; 19 margin-top: 12px; 22 20 } 23 21 -
madquick-ppg/tags/1.0.2/assets/css/plugin-page.css
r3239886 r3319446 1 1 .wrap { 2 2 margin-top: 20px; 3 } 4 5 .mq-legal-table-container { 6 width: 100%; 7 max-width: 700px; 8 /* margin: 32px auto 0 auto; */ 9 border-spacing: 0; 10 background: #fff; 11 border-radius: 12px; 12 /* box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08); */ 13 overflow: hidden; 14 } 15 16 .mq-legal-table-container td { 17 vertical-align: top; 18 padding: 0; 19 border: none; 20 } 21 22 .mq-policy-title { 23 /* font-size: 1.1rem; 24 font-weight: 600; 25 color: #23282d; 26 padding: 28px 32px 18px 32px; 27 border-right: 1px solid #f1f1f1; 28 background: #f9fafb; 29 min-width: 170px; */ 30 } 31 32 .mq-policy-card { 33 padding: 4px 12px; 34 } 35 36 .mq-policy-description { 37 color: #50575e; 38 margin-bottom: 16px; 39 font-size: 1rem; 40 } 41 42 @media (max-width: 600px) { 43 .mq-legal-table-container, 44 .mq-legal-table-container tbody, 45 .mq-legal-table-container tr, 46 .mq-legal-table-container td { 47 display: block; 48 width: 100% !important; 49 } 50 .mq-policy-title, 51 .mq-policy-card { 52 /* padding: 18px 14px; */ 53 border: none; 54 min-width: 0; 55 } 3 56 } 4 57 -
madquick-ppg/tags/1.0.2/assets/js/generate-policy.js
r3239886 r3319446 54 54 const convertToPageContent = (formData) => { 55 55 const post_content = ` 56 57 <h2> Privacy Policy </h2> 58 59 <span style="font-weight: 400;">At ${ 60 formData?.websiteName ?? "" 61 }, accessible from ${ 62 formData.websiteURL 63 }, one of our main priorities is the privacy of our visitors. This Privacy Policy document contains types of information that is collected and recorded by test and how we use it.</span> <br><br> 64 65 <span style="font-weight: 400;">If you have additional questions or require more information about our Privacy Policy, do not hesitate to contact us.</span> <br><br> 66 67 <span style="font-weight: 400;">This Privacy Policy applies only to our online activities and is valid for visitors to our website with regards to the information that they shared and/or collected in test. This policy is not applicable to any information collected offline or via channels other than this website. Our Privacy Policy was created with the help of the </span><a href="https://privacypolicy-generator.com/"><span style="font-weight: 400;">Privacy Policy Generator.</span> <br><br></a> 68 <h2>Information we collect <br></h2> 69 <span style="font-weight: 400;">The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information.</span> <br><br> 70 <span>The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information. We also ask users to submit new passwords, if applicable. We prioritize security and understand the importance of strong passwords. That’s why we don’t use weak passwords on our website and recommend</span><a href="https://strong-password-generator.com/"><u><span style="color:#1155cc;"> tough password generator</span></u></a><span> to help safeguard your account from unauthorized access. This commitment helps protect our users' accounts and data, giving you peace of mind while using our services.</span><span style="font-weight: 400;">When you register for an Account, we may ask for your </span> <br><br> 71 72 Personal Information We Collect from Users:<br><br> 73 ${ 74 typeof formData.types_of_data_collected !== 75 "string" && 76 formData.types_of_data_collected 77 ?.map( 78 (data) => 79 "<li>" + data + "</li>" 80 ) 81 .join("") 82 } 83 ${ 84 "<li>" + 85 typeof formData.types_of_data_collected === 86 "string" 87 ? formData.types_of_data_collected 88 : "" + "</li>" 89 } 90 <h2>How we use your information <br></h2> 91 <span style="font-weight: 400;">We use the information we collect in various ways, including to:</span> <br><br> 92 <ul> 93 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Provide, operate, and maintain our website</span> <br><br></li> 94 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Improve, personalize, and expand our website</span> <br><br></li> 95 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Understand and analyze how you use our website</span> <br><br></li> 96 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Develop new products, services, features, and functionality</span> <br><br></li> 97 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Communicate with you, either directly or through one of our partners, including for customer service, to provide you with updates and other information relating to the website, and for marketing and promotional purposes</span> <br><br></li> 98 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Send you emails</span> <br><br></li> 99 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Find and prevent fraud</span> <br><br></li> 100 </ul> 101 102 103 <h2>Log Files <br></h2> 104 <span style="font-weight: 400;">test follows a standard procedure of using log files. These files log visitors when they visit websites. All hosting companies do this as part of hosting services’ analytics. The information collected by log files include internet protocol (IP) addresses, browser type, Internet Service Provider (ISP), date and time stamp, referring/exit pages, and possibly the number of clicks. These are not linked to any information that is personally identifiable. The purpose of the information is for analyzing trends, administering the site, tracking users’ movement on the website, and gathering demographic information.</span> <br><br> 105 106 <h2>Email Privacy Policies: <br></h2><span>Your privacy and security are what we care about most. To give you a better experience, we've updated our email privacy policies. We only allow real email addresses to make the space safer for everyone, and we've improved our encryption to protect your data. We do not allow <a href="https://temp-maill.org/">tempmail</a>.</span><br><br><h2>Updated Browser Policies for Enhanced Security and Privacy <br></h2> <span><span>We are committed to your security and have updated our browser policies to improve your privacy. Our new encryption standards, reduced cookie collection, and better protection against harmful content all contribute to a safer browsing experience.</span><a href="http://updatemybrowsers.com/"><span> </span>Update your browser</a><span> today.</span></span><br><br><h2>Adult Content and Compliance with Pornography Laws:<br></h2><span>We are dedicated to providing a respectful and secure online experience by following</span> <a href="https://pornography-laws.com/"><u><span>pornography laws</span></u></a><span>. Our platform bans adult content to ensure a family-friendly atmosphere. Our effective content moderation practices prevent any adult material from being published and address any violations promptly.</span><br><br><h2>Third Party Privacy Policies <br></h2> 107 <span style="font-weight: 400;">test’s Privacy Policy does not apply to other advertisers or websites. Thus, we are advising you to consult the respective Privacy Policies of these third-party ad servers for more detailed information. It may include their practices and instructions about how to opt-out of certain options.</span> <br><br> 108 109 <span style="font-weight: 400;">You can choose to disable cookies through your individual browser options. To know more detailed information about cookie management with specific web browsers, it can be found at the browsers’ respective websites.</span> <br><br> 110 <h2>CCPA Privacy Rights (Do Not Sell My Personal Information) <br></h2> 111 <span style="font-weight: 400;">Under the CCPA, among other rights, California consumers have the right to:</span> <br><br> 112 113 <span style="font-weight: 400;">Request that a business that collects a consumer’s personal data disclose the categories and specific pieces of personal data that a business has collected about consumers.</span> <br><br> 114 115 <span style="font-weight: 400;">Request that a business delete any personal data about the consumer that a business has collected.</span> <br><br> 116 117 <span style="font-weight: 400;">Request that a business that sells a consumer’s personal data, not sell the consumer’s personal data.</span> <br><br> 118 119 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 120 <h2>Use of Content</h2><span>We are dedicated to upholding high standards for content quality and integrity. Therefore, we strictly prohibit the use of</span><a href="https://lorem-ipsumm.com/"><u><span> Lorem Ipsum Generator</span></u></a><span> content, including but not limited to Lorem Ipsum text, on our website. All content must be original, relevant, and meaningful to our audience. This ensures that our website remains a valuable and trustworthy resource for our visitors.</span><br><br><h2>GDPR Data Protection Rights <br></h2> 121 <span style="font-weight: 400;">We would like to make sure you are fully aware of all of your data protection rights. Every user is entitled to the following:</span> <br><br> 122 123 <span style="font-weight: 400;">The right to access – You have the right to request copies of your personal data. We may charge you a small fee for this service.</span> <br><br> 124 125 <span style="font-weight: 400;">The right to rectification – You have the right to request that we correct any information you believe is inaccurate. You also have the right to request that we complete the information you believe is incomplete.</span> <br><br> 126 127 <span style="font-weight: 400;">The right to erasure – You have the right to request that we erase your personal data, under certain conditions.</span> <br><br> 128 129 <span style="font-weight: 400;">The right to restrict processing – You have the right to request that we restrict the processing of your personal data, under certain conditions.</span> <br><br> 130 131 <span style="font-weight: 400;">The right to object to processing – You have the right to object to our processing of your personal data, under certain conditions.</span> <br><br> 132 133 <span style="font-weight: 400;">The right to data portability – You have the right to request that we transfer the data that we have collected to another organization, or directly to you, under certain conditions.</span> <br><br> 134 135 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 136 <h2>Children’s Information <br></h2> 137 <span style="font-weight: 400;">Another part of our priority is adding protection for children while using the internet. We encourage parents and guardians to observe, participate in, and/or monitor and guide their online activity.</span> <br><br> 138 139 <span style="font-weight: 400;">test does not knowingly collect any Personal Identifiable Information from children under the age of 13. If you think that your child provided this kind of information on our website, we strongly encourage you to contact us immediately and we will do our best efforts to promptly remove such information from our records.</span> <br><br> 140 <p>For Entity Type, we use Individual platforms.</p>${ 141 formData.state ?? 142 " " + " " + formData.country ?? 143 " " 144 }<h2>Contact Us </h2>Contact Information<br><br>Email: ${ 145 formData?.websiteEmail ?? "" 146 }<br><br> 147 <br><br> 148 Phone: ${ 149 formData?.phoneNumber ?? "" 150 } 151 `; 56 <h2> Privacy Policy </h2> 57 58 <span style="font-weight: 400;">At ${ 59 formData?.websiteName ?? "" 60 }, accessible from ${ 61 formData.websiteURL 62 }, one of our main priorities is the privacy of our visitors. This Privacy Policy document contains types of information that is collected and recorded by test and how we use it.</span> <br><br> 63 64 <span style="font-weight: 400;">If you have additional questions or require more information about our Privacy Policy, do not hesitate to contact us.</span> <br><br> 65 66 <span style="font-weight: 400;">This Privacy Policy applies only to our online activities and is valid for visitors to our website with regards to the information that they shared and/or collected in test. This policy is not applicable to any information collected offline or via channels other than this website. Our Privacy Policy was created with the help of the </span><a href="https://privacypolicy-generator.com/"><span style="font-weight: 400;">Privacy Policy Generator.</span> <br><br></a> 67 <h2>Information we collect <br></h2> 68 <span style="font-weight: 400;">The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information.</span> <br><br> 69 <span>The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information. We also ask users to submit new passwords, if applicable. We prioritize security and understand the importance of strong passwords. That’s why we don’t use weak passwords on our website and recommend</span><a href="https://strong-password-generator.com/"><u><span style="color:#1155cc;"> tough password generator</span></u></a><span> to help safeguard your account from unauthorized access. This commitment helps protect our users' accounts and data, giving you peace of mind while using our services.</span><span style="font-weight: 400;">When you register for an Account, we may ask for your </span> <br><br> 70 71 Personal Information We Collect from Users:<br><br> 72 ${ 73 typeof formData.types_of_data_collected !== 74 "string" && 75 formData.types_of_data_collected 76 ?.map( 77 (data) => 78 "<li>" + data + "</li>" 79 ) 80 .join("") 81 } 82 ${ 83 "<li>" + 84 typeof formData.types_of_data_collected === 85 "string" 86 ? formData.types_of_data_collected 87 : "" + "</li>" 88 } 89 <h2>How we use your information <br></h2> 90 <span style="font-weight: 400;">We use the information we collect in various ways, including to:</span> <br><br> 91 <ul> 92 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Provide, operate, and maintain our website</span> <br><br></li> 93 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Improve, personalize, and expand our website</span> <br><br></li> 94 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Understand and analyze how you use our website</span> <br><br></li> 95 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Develop new products, services, features, and functionality</span> <br><br></li> 96 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Communicate with you, either directly or through one of our partners, including for customer service, to provide you with updates and other information relating to the website, and for marketing and promotional purposes</span> <br><br></li> 97 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Send you emails</span> <br><br></li> 98 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Find and prevent fraud</span> <br><br></li> 99 </ul> 100 101 102 <h2>Log Files <br></h2> 103 <span style="font-weight: 400;">test follows a standard procedure of using log files. These files log visitors when they visit websites. All hosting companies do this as part of hosting services’ analytics. The information collected by log files include internet protocol (IP) addresses, browser type, Internet Service Provider (ISP), date and time stamp, referring/exit pages, and possibly the number of clicks. These are not linked to any information that is personally identifiable. The purpose of the information is for analyzing trends, administering the site, tracking users’ movement on the website, and gathering demographic information.</span> <br><br> 104 105 <h2>Email Privacy Policies: <br></h2><span>Your privacy and security are what we care about most. To give you a better experience, we've updated our email privacy policies. We only allow real email addresses to make the space safer for everyone, and we've improved our encryption to protect your data. We do not allow <a href="https://temp-maill.org/">tempmail</a>.</span><br><br><h2>Updated Browser Policies for Enhanced Security and Privacy <br></h2> <span><span>We are committed to your security and have updated our browser policies to improve your privacy. Our new encryption standards, reduced cookie collection, and better protection against harmful content all contribute to a safer browsing experience.</span><a href="http://updatemybrowsers.com/"><span> </span>Update your browser</a><span> today.</span></span><br><br><h2>Adult Content and Compliance with Pornography Laws:<br></h2><span>We are dedicated to providing a respectful and secure online experience by following</span> <a href="https://pornography-laws.com/"><u><span>pornography laws</span></u></a><span>. Our platform bans adult content to ensure a family-friendly atmosphere. Our effective content moderation practices prevent any adult material from being published and address any violations promptly.</span><br><br><h2>Third Party Privacy Policies <br></h2> 106 <span style="font-weight: 400;">test’s Privacy Policy does not apply to other advertisers or websites. Thus, we are advising you to consult the respective Privacy Policies of these third-party ad servers for more detailed information. It may include their practices and instructions about how to opt-out of certain options.</span> <br><br> 107 108 <span style="font-weight: 400;">You can choose to disable cookies through your individual browser options. To know more detailed information about cookie management with specific web browsers, it can be found at the browsers’ respective websites.</span> <br><br> 109 <h2>CCPA Privacy Rights (Do Not Sell My Personal Information) <br></h2> 110 <span style="font-weight: 400;">Under the CCPA, among other rights, California consumers have the right to:</span> <br><br> 111 112 <span style="font-weight: 400;">Request that a business that collects a consumer’s personal data disclose the categories and specific pieces of personal data that a business has collected about consumers.</span> <br><br> 113 114 <span style="font-weight: 400;">Request that a business delete any personal data about the consumer that a business has collected.</span> <br><br> 115 116 <span style="font-weight: 400;">Request that a business that sells a consumer’s personal data, not sell the consumer’s personal data.</span> <br><br> 117 118 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 119 <h2>Use of Content</h2><span>We are dedicated to upholding high standards for content quality and integrity. Therefore, we strictly prohibit the use of</span><a href="https://lorem-ipsumm.com/"><u><span> Lorem Ipsum Generator</span></u></a><span> content, including but not limited to Lorem Ipsum text, on our website. All content must be original, relevant, and meaningful to our audience. This ensures that our website remains a valuable and trustworthy resource for our visitors.</span><br><br><h2>GDPR Data Protection Rights <br></h2> 120 <span style="font-weight: 400;">We would like to make sure you are fully aware of all of your data protection rights. Every user is entitled to the following:</span> <br><br> 121 122 <span style="font-weight: 400;">The right to access – You have the right to request copies of your personal data. We may charge you a small fee for this service.</span> <br><br> 123 124 <span style="font-weight: 400;">The right to rectification – You have the right to request that we correct any information you believe is inaccurate. You also have the right to request that we complete the information you believe is incomplete.</span> <br><br> 125 126 <span style="font-weight: 400;">The right to erasure – You have the right to request that we erase your personal data, under certain conditions.</span> <br><br> 127 128 <span style="font-weight: 400;">The right to restrict processing – You have the right to request that we restrict the processing of your personal data, under certain conditions.</span> <br><br> 129 130 <span style="font-weight: 400;">The right to object to processing – You have the right to object to our processing of your personal data, under certain conditions.</span> <br><br> 131 132 <span style="font-weight: 400;">The right to data portability – You have the right to request that we transfer the data that we have collected to another organization, or directly to you, under certain conditions.</span> <br><br> 133 134 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 135 <h2>Children’s Information <br></h2> 136 <span style="font-weight: 400;">Another part of our priority is adding protection for children while using the internet. We encourage parents and guardians to observe, participate in, and/or monitor and guide their online activity.</span> <br><br> 137 138 <span style="font-weight: 400;">test does not knowingly collect any Personal Identifiable Information from children under the age of 13. If you think that your child provided this kind of information on our website, we strongly encourage you to contact us immediately and we will do our best efforts to promptly remove such information from our records.</span> <br><br> 139 <p>For Entity Type, we use Individual platforms.</p>${ 140 formData.state ?? 141 " " + " " + formData.country ?? 142 " " 143 }<h2>Contact Us </h2>Contact Information<br><br>Email: ${ 144 formData?.websiteEmail ?? "" 145 }<br><br> 146 <br><br> 147 Phone: ${ 148 formData?.phoneNumber ?? "" 149 } 150 `; 152 151 153 152 savePost(post_content); … … 155 154 156 155 const savePost = (post_content) => { 157 console.log(post_content);158 156 159 if (typeof ajax_object=== "undefined") {160 console.error(" ajax_objectis not defined");157 if (typeof madquick_ppg_ajax === "undefined") { 158 console.error("madquick_ppg_ajax is not defined"); 161 159 return; 162 160 } … … 164 162 // Use jQuery's ajax method 165 163 jQuery.ajax({ 166 url: ajax_object.ajax_url,164 url: madquick_ppg_ajax.ajax_url, 167 165 type: "POST", 168 166 dataType: "json", … … 170 168 action: "create_custom_page", 171 169 post_content: post_content, 172 nonce: ajax_object.nonce,170 nonce: madquick_ppg_ajax.nonce, 173 171 }, 174 172 success: function (response) { -
madquick-ppg/tags/1.0.2/madquick-ppg.php
r3240916 r3319446 1 1 <?php 2 3 2 /** 4 3 * Plugin Name: Privacy Policy Generator - Madquick 5 4 * Author URI: https://github.com/Madquick-Private-Limited/ 6 * Requires at least: 6. 37 * Requires PHP: 7. 2.248 * Version: 1.0. 19 * Description: A simple wordpress plugin that help us to generate privacy and policy page and other legal pages that are required inyour website.5 * Requires at least: 6.8 6 * Requires PHP: 7.4 7 * Version: 1.0.2 8 * Description: Generate privacy policy, terms, and legal pages required for your website. 10 9 * License: GPLv2 or later 11 10 * License URI: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html 12 * Keywords: privacy, policy, terms, legal, compliance, GDPR, madquick13 11 * Text Domain: madquick-ppg 14 * 12 * 15 13 * @package madquick-ppg 16 14 */ 17 15 18 defined( "ABSPATH") || exit;16 defined('ABSPATH') || exit; 19 17 20 /* imports */ 21 // require_once "Madquick_Page_CPT.php"; 22 require_once "ajax/create-ppg-page.php"; 18 define('MADQUICK_PPG_PATH', plugin_dir_path(__FILE__)); 19 define('MADQUICK_PPG_URL', plugin_dir_url(__FILE__)); 23 20 24 function madquick_enqueue_scripts($hook_suffix) 25 { 26 // Define the plugin directory path for file versioning 27 $plugin_dir = plugin_dir_path(__FILE__); 21 // Required files 22 require_once MADQUICK_PPG_PATH . 'ajax/create-ppg-page.php'; 28 23 29 // Enqueue the script and set 'jquery' as a dependency, with versioning 30 wp_enqueue_script( 31 'generate-policy-script', 32 plugin_dir_url(__FILE__) . 'assets/js/generate-policy.js', 33 ['jquery'], 34 filemtime($plugin_dir . 'assets/js/generate-policy.js'), // Dynamic version based on last modified time 35 true // Load in the footer 36 ); 24 if (!class_exists('Madquick_PPG')) { 37 25 38 // Enqueue the CSS files with dynamic versioning 39 wp_enqueue_style( 40 "home-page-css", 41 plugin_dir_url(__FILE__) . "assets/css/home-page.css", 42 [], 43 filemtime($plugin_dir . "assets/css/home-page.css") 44 ); 26 class Madquick_PPG { 45 27 46 wp_enqueue_style( 47 "plugin-page-css", 48 plugin_dir_url(__FILE__) . "assets/css/plugin-page.css", 49 [], 50 filemtime($plugin_dir . "assets/css/plugin-page.css") 51 ); 28 public function __construct() { 29 add_action('admin_menu', [$this, 'register_admin_menu']); 30 add_action('admin_enqueue_scripts', [$this, 'enqueue_admin_assets']); 31 } 52 32 53 // Localize the script immediately after enqueueing 54 wp_localize_script('generate-policy-script', 'ajax_object', [ 55 'ajax_url' => admin_url('admin-ajax.php'), 56 'nonce' => wp_create_nonce('madquick_nonce'), 57 ]); 58 } 59 add_action('admin_enqueue_scripts', 'madquick_enqueue_scripts'); 33 /** 34 * Enqueue plugin scripts and styles only on our pages. 35 */ 36 public function enqueue_admin_assets($hook) { 37 $screen = get_current_screen(); 38 if ( 39 isset($screen->id) && 40 (strpos($screen->id, 'madquick-ppg-home') !== false || 41 strpos($screen->id, 'madquick-ppg-help') !== false || 42 strpos($screen->id, 'madquick-ppg-create') !== false) 43 ) { 44 wp_enqueue_style( 45 'madquick-ppg-plugin-page', 46 MADQUICK_PPG_URL . 'assets/css/plugin-page.css', 47 [], 48 filemtime(MADQUICK_PPG_PATH . 'assets/css/plugin-page.css') 49 ); 50 wp_enqueue_style( 51 'madquick-ppg-home-page', 52 MADQUICK_PPG_URL . 'assets/css/home-page.css', 53 [], 54 filemtime(MADQUICK_PPG_PATH . 'assets/css/home-page.css') 55 ); 56 wp_enqueue_script( 57 'madquick-ppg-generate-policy', 58 MADQUICK_PPG_URL . 'assets/js/generate-policy.js', 59 ['jquery'], 60 filemtime(MADQUICK_PPG_PATH . 'assets/js/generate-policy.js'), 61 true 62 ); 63 wp_localize_script('madquick-ppg-generate-policy', 'madquick_ppg_ajax', [ 64 'ajax_url' => admin_url('admin-ajax.php'), 65 'nonce' => wp_create_nonce('madquick_nonce'), 66 ]); 67 } 68 } 60 69 70 /** 71 * Register admin menu and submenus. 72 */ 73 public function register_admin_menu() { 74 add_menu_page( 75 __('Privacy & Policy Generator', 'madquick-ppg'), 76 __('Privacy & Policy Generator', 'madquick-ppg'), 77 'manage_options', 78 'madquick-ppg-home', 79 [$this, 'render_main_page'], 80 'dashicons-shield-alt', 81 20 82 ); 61 83 62 // Hook to add the custom admin menu 63 add_action('admin_menu', 'madquick_ppg_add_admin_menu'); 84 add_submenu_page( 85 'madquick-ppg-home', 86 __('Help', 'madquick-ppg'), 87 __('Help', 'madquick-ppg'), 88 'manage_options', 89 'madquick-ppg-help', 90 [$this, 'render_help_page'] 91 ); 64 92 65 // defined in cpt page 66 // add_action('init', 'madquick_register_custom_post_type'); 93 // "Create" page, hidden from menu but routable 94 add_submenu_page( 95 null, 96 __('Create Legal Page', 'madquick-ppg'), 97 __('Create', 'madquick-ppg'), 98 'manage_options', 99 'madquick-ppg-create', 100 [$this, 'render_create_page'] 101 ); 102 } 67 103 68 function madquick_ppg_add_admin_menu() 69 { 104 /** 105 * Main dashboard/page router. 106 */ 107 public function render_main_page() { 108 $action = isset($_GET['current-action']) ? sanitize_text_field(wp_unslash($_GET['current-action'])) : ''; 109 $nonce = isset($_GET['madquick_ppg_nonce']) ? sanitize_text_field(wp_unslash($_GET['madquick_ppg_nonce'])) : ''; 70 110 71 // Main menu 72 add_menu_page( 73 'Privary & Policy Generator', // Page title 74 'Privary & Policy Generator', // Menu title 75 'manage_options', // Capability required to access the menu 76 'madquick-ppg-home', // Menu slug (unique identifier) 77 'madquick_ppg_add_legal_page_cb', // Function to display the page content 78 'dashicons-admin-generic', 79 20 80 ); 111 if ($action && $nonce && wp_verify_nonce($nonce, 'madquick_create_ppg_nonce')) { 112 $this->include_page('madquick-ppg-create.php'); 113 } else { 114 $this->include_page('madquick-ppg-main.php'); 115 } 116 } 81 117 82 add_submenu_page( 83 'madquick-ppg-home', // Parent slug (must match the slug of the main menu) 84 'Help', // Page title 85 'Help', // Submenu title 86 'manage_options', // Capability required to access this submenu 87 'madquick-ppg-help', // Submenu slug (unique identifier) 88 'madquick_ppg_help_page' // Function to display the content of the submenu page 89 ); 90 } 118 /** 119 * Help submenu page. 120 */ 121 public function render_help_page() { 122 $this->include_page('madquick-ppg-help.php'); 123 } 91 124 125 /** 126 * Create page, can be routed directly. 127 */ 128 public function render_create_page() { 129 $this->include_page('madquick-ppg-create.php'); 130 } 92 131 93 function madquick_ppg_add_legal_page_cb() 94 { 95 $current_action = "none"; 96 97 // Check for 'current-action' and 'my_nonce' in the URL 98 if (isset($_GET['current-action']) && isset($_GET['my_nonce'])) { 99 // Properly unslash and sanitize the nonce parameter before verifying 100 $nonce = sanitize_text_field(wp_unslash($_GET['my_nonce'])); 101 102 // Verify the nonce to ensure the request is valid 103 if (wp_verify_nonce($nonce, 'madquick_create_ppg_nonce')) { 104 // Properly unslash and sanitize the action parameter 105 $current_action = wp_kses_post(wp_unslash($_GET['current-action'])); 106 } else { 107 // If nonce verification fails, stop the process and show an error 108 wp_die('Unauthorized request'); 132 /** 133 * Utility to include a page from /pages. 134 */ 135 private function include_page($file) { 136 $filepath = MADQUICK_PPG_PATH . 'pages/' . $file; 137 if (file_exists($filepath)) { 138 include $filepath; 139 } else { 140 echo esc_html__('Page not found.', 'madquick-ppg'); 141 } 109 142 } 110 143 } 111 144 112 113 ?> 114 115 <!-- main page --> 116 <?php if ($current_action === "none"): ?> 117 118 <!-- link plugin-page.css --> 119 120 <div class="wrap"> 121 <h1 class="wp-heading-inline"><?php esc_html_e('All Legal Pages', 'madquick-ppg'); ?></h1> 122 123 <table class="table-container"> 124 <tbody> 125 <tr> 126 <td style="width: 40%;"> 127 <p class="policy-title"><?php esc_html_e('Privacy Policy', 'madquick-ppg'); ?></p> 128 </td> 129 <td> 130 <div class="policy-card"> 131 <p class="policy-description"> 132 <?php esc_html_e('Create a simple Privacy Policy for your WordPress website.', 'madquick-ppg'); ?> 133 </p> 134 <?php 135 $url = wp_nonce_url( 136 add_query_arg( 137 [ 138 'page' => 'madquick-ppg-home', 139 'current-action' => 'create-ppg' 140 ], 141 admin_url('admin.php') 142 ), 143 'madquick_create_ppg_nonce', 144 'my_nonce' 145 ); 146 ?> 147 <a class="button button-primary" href="<?php echo esc_url($url); ?>"> 148 <?php esc_html_e('Create', 'madquick-ppg'); ?> 149 </a> 150 151 </div> 152 </td> 153 </tr> 154 <tr> 155 <td style="width: 40%;"> 156 <p class="policy-title"><?php esc_html_e('Terms & Conditions', 'madquick-ppg'); ?></p> 157 </td> 158 <td> 159 <div class="policy-card"> 160 <p class="policy-description"> 161 <?php esc_html_e('Create Terms & Conditions for your WordPress website.', 'madquick-ppg'); ?> 162 </p> 163 <a class="button button-primary" href="#"> 164 <?php esc_html_e('Create', 'madquick-ppg'); ?> 165 </a> 166 </div> 167 </td> 168 </tr> 169 </tbody> 170 </table> 171 </div> 172 173 174 <?php endif; ?> 175 176 <!-- PPG Page --> 177 <?php if ($current_action === "create-ppg"): ?> 178 179 <!-- link css home-page.css --> 180 181 <div class="wrap-main"> 182 <h1><?php esc_html_e('All Legal Pages', 'madquick-ppg'); ?></h1> 183 184 <!-- ppg form --> 185 <form id="privacy-policy-form" method="post" action="#"> 186 <h2 style="font-size: 20px;"> 187 <?php echo esc_html_e("Website Information to generate privacy policy", "madquick-ppg"); ?> 188 </h2> 189 <!-- Website --> 190 <div class="input-field"> 191 <label for="websiteName">What is your website name?</label> 192 <input type="text" id="websiteName" name="websiteName" placeholder="website name name" class="form-control"> 193 </div> 194 <!-- Website --> 195 <div class="input-field"> 196 <label for="websiteURL">What is your website URL?</label> 197 <input type="text" id="websiteURL" name="websiteURL" placeholder="Website URL" class="form-control"> 198 </div> 199 200 <!-- Entity Type --> 201 <div class="input-field"> 202 <label for="entityType">Entity Type</label> 203 204 <div> 205 <input type="radio" name="entityType" value="Business" id="business" 206 onclick="toggleContent('companyname', true)"> 207 <label for="business">I'm a Business</label> 208 </div> 209 210 <div> 211 <input type="radio" name="entityType" value="Individual" id="individual" 212 onclick="toggleContent('companyname', false)"> 213 <label for="individual">I'm an Individual</label> 214 </div> 215 </div> 216 217 <!-- Business Details --> 218 <div id="companyname" class="inner-section" style="display: none;"> 219 <div class="input-field"> 220 <label class="title">What is the name of the business?</label> 221 <input id="company_name" name="company_name" type="text" placeholder="My Company LLC" 222 class="form-control"> 223 <div class="help-text-bottom">e.g. My Company LLC</div> 224 </div> 225 226 <div class="input-field"> 227 <label class="title">What is the address of the business?</label> 228 <input id="company_address" name="company_address" type="text" placeholder="1 Cupertino, CA 95014" 229 class="form-control"> 230 <div class="help-text-bottom">e.g. 1 Cupertino, CA 95014</div> 231 </div> 232 </div> 233 234 <!-- Country and State --> 235 <div class="input-field"> 236 <label for="country">Enter the country</label> 237 <input type="text" id="country" name="country" placeholder="Enter the country" class="form-control"> 238 </div> 239 240 <div class="input-field"> 241 <label for="state">Enter the state</label> 242 <input type="text" id="state" name="state" placeholder="Enter the state" class="form-control"> 243 </div> 244 245 <!-- Personal Information Collected --> 246 <div class="input-field"> 247 <h2 class="" style="font-size: 24px;"> 248 Data Collection Information 249 </h2> 250 <label for="personalInfo">What kind of personal information do you collect from users?</label> 251 <p>Click all that apply</p> 252 <div class="checkbox-group"> 253 <div> 254 <input type="checkbox" name="types_of_data_collected" id="email" value="Email"> 255 <label for="email">Email address</label> 256 </div> 257 <div> 258 <input type="checkbox" name="types_of_data_collected" id="name" value="Name"> 259 <label for="name">First name and last name</label> 260 </div> 261 <div> 262 <input type="checkbox" name="types_of_data_collected" id="phone" value="Phone"> 263 <label for="phone">Phone number</label> 264 </div> 265 <div> 266 <input type="checkbox" name="types_of_data_collected" id="address" value="Address"> 267 <label for="address">Address, State, Province, ZIP/Postal code, City</label> 268 </div> 269 <div> 270 <input type="checkbox" name="types_of_data_collected" id="socialMedia" value="Social Media Login"> 271 <label for="socialMedia">Social Media Profile information (e.g., from Facebook, Twitter)</label> 272 </div> 273 </div> 274 </div> 275 276 <!-- Contact Method --> 277 <div class="input-field"> 278 <h2 style="font-size: 20px;"> 279 Contact Information Want To Put In Privacy Policy 280 </h2> 281 <label for="company_contact">How can the company contact users?</label> 282 283 <div class="checkbox-group"> 284 <div> 285 <input type="checkbox" name="company_contact" id="emailCheckbox" value="Email" 286 onchange="toggleFields('email')"> 287 <label for="emailCheckbox">By email</label> 288 </div> 289 290 <div id="emailFields" style="display: none;"> 291 <input type="email" id="websiteEmail" name="websiteEmail" placeholder="Website/Email" 292 class="form-control"> 293 </div> 294 295 <div> 296 <input type="checkbox" name="company_contact" id="linkCheckbox" value="Link" 297 onchange="toggleFields('link')"> 298 <label for="linkCheckbox">By visiting a page on our website</label> 299 </div> 300 301 <div id="linkFields" style="display: none;"> 302 <input type="text" id="websitePage" name="websitePage" placeholder="Page URL" class="form-control"> 303 </div> 304 305 <div> 306 <input type="checkbox" name="company_contact" id="phoneCheckbox" value="Phone" 307 onchange="toggleFields('phone')"> 308 <label for="phoneCheckbox">By phone number</label> 309 </div> 310 311 <div id="phoneFields" style="display: none;"> 312 <input type="tel" id="phoneNumber" name="phoneNumber" placeholder="Phone number" 313 class="form-control"> 314 </div> 315 316 <div> 317 <input type="checkbox" name="company_contact" id="addressCheckbox" value="Address" 318 onchange="toggleFields('address')"> 319 <label for="addressCheckbox">By sending post mail</label> 320 </div> 321 322 <div id="addressFields" style="display: none;"> 323 <input type="text" id="postAddress" name="postAddress" placeholder="Postal Address" 324 class="form-control"> 325 </div> 326 </div> 327 </div> 328 329 <!-- Submit Button --> 330 <button class="button button-primary">Generate</button> 331 </form> 332 333 <script> 334 335 </script> 336 </div> 337 338 339 <?php endif; ?> 340 341 <?php 145 // Initialize plugin 146 new Madquick_PPG(); 342 147 } 343 344 345 // Function to display the content of the "Madquick PPG" (submenu) page346 function madquick_ppg_help_page()347 {348 ?>349 <div class="wrap">350 <h1><?php esc_html_e('Help & Documentation', 'madquick-ppg'); ?></h1>351 <p><?php esc_html_e('Welcome to the Madquick Privacy & Policy Generator Help section. Here you’ll find useful information and guides on how to use the plugin effectively.', 'madquick-ppg'); ?>352 </p>353 354 <h2><?php esc_html_e('Table of Contents', 'madquick-ppg'); ?></h2>355 <ul>356 <li><a href="#overview"><?php esc_html_e('Overview', 'madquick-ppg'); ?></a></li>357 <li><a href="#how-to-use"><?php esc_html_e('How to Use', 'madquick-ppg'); ?></a></li>358 <li><a href="#faq"><?php esc_html_e('Frequently Asked Questions', 'madquick-ppg'); ?></a></li>359 <li><a href="#support"><?php esc_html_e('Support', 'madquick-ppg'); ?></a></li>360 </ul>361 362 <hr>363 364 <h2 id="overview"><?php esc_html_e('Overview', 'madquick-ppg'); ?></h2>365 <p><?php esc_html_e('Madquick PPG helps you quickly generate essential legal pages like Privacy Policy and Terms & Conditions. It ensures your site stays compliant with privacy laws such as GDPR and CCPA.', 'madquick-ppg'); ?>366 </p>367 368 <h2 id="how-to-use"><?php esc_html_e('How to Use', 'madquick-ppg'); ?></h2>369 <ol>370 <li><?php esc_html_e('Go to the plugin settings page under "Madquick PPG".', 'madquick-ppg'); ?></li>371 <li><?php esc_html_e('Select the type of legal page you want to create (Privacy Policy or Terms & Conditions).', 'madquick-ppg'); ?>372 </li>373 <li><?php esc_html_e('Click the "Create" button.', 'madquick-ppg'); ?></li>374 <li><?php esc_html_e('Edit the generated content as needed.', 'madquick-ppg'); ?></li>375 <li><?php esc_html_e('Save and publish the page.', 'madquick-ppg'); ?></li>376 </ol>377 378 <h2 id="faq"><?php esc_html_e('Frequently Asked Questions', 'madquick-ppg'); ?></h2>379 <dl>380 <dt><?php esc_html_e('Can I customize the generated pages?', 'madquick-ppg'); ?></dt>381 <dd><?php esc_html_e('Yes, all generated pages can be edited directly within the WordPress editor.', 'madquick-ppg'); ?>382 </dd>383 384 <dt><?php esc_html_e('Does the plugin ensure GDPR compliance?', 'madquick-ppg'); ?></dt>385 <dd><?php esc_html_e('The plugin provides a template that helps you stay compliant, but we recommend reviewing it to ensure it meets your specific needs.', 'madquick-ppg'); ?>386 </dd>387 388 <dt><?php esc_html_e('Can I regenerate the legal pages if needed?', 'madquick-ppg'); ?></dt>389 <dd><?php esc_html_e('Yes, you can regenerate pages at any time by visiting the plugin settings.', 'madquick-ppg'); ?>390 </dd>391 </dl>392 393 <h2 id="support"><?php esc_html_e('Support', 'madquick-ppg'); ?></h2>394 <p><?php esc_html_e('If you encounter any issues or have questions, please contact us at', 'madquick-ppg'); ?>395 <a href="mailto:tech@madquick.in">tech@madquick.in</a>.396 </p>397 </div>398 <?php399 }400 -
madquick-ppg/tags/1.0.2/readme.txt
r3240916 r3319446 1 1 === Privacy Policy Generator - Madquick === 2 Contributors: madquick 2 Contributors: madquick team 3 3 Tags: privacy, policy, terms, legal, GDPR 4 Requires at least: 6. 35 Tested up to: 6. 74 Requires at least: 6.8 5 Tested up to: 6.8 6 6 Requires PHP: 7.4 7 Stable tag: 1.0. 17 Stable tag: 1.0.2 8 8 License: GPLv2 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 13 13 == Description == 14 14 15 Privacy Policy Generator - Madquickis an easy-to-use plugin that enables website owners to quickly generate **Privacy Policies** and **Terms & Conditions** pages. This tool helps ensure that your website complies with privacy laws such as **GDPR** and **CCPA**. The generated pages are customizable, mobile-friendly, and designed to integrate seamlessly with WordPress.15 Madquick PPG is an easy-to-use plugin that enables website owners to quickly generate **Privacy Policies** and **Terms & Conditions** pages. This tool helps ensure that your website complies with privacy laws such as **GDPR** and **CCPA**. The generated pages are customizable, mobile-friendly, and designed to integrate seamlessly with WordPress. 16 16 17 17 == Features == … … 28 28 1. Upload the plugin files to the `/wp-content/plugins/madquick-ppg/` directory, or install the plugin through the WordPress plugins screen directly. 29 29 2. Activate the plugin through the 'Plugins' screen in WordPress. 30 3. Navigate to ** Privacy Policy Generator - Madquick** in the WordPress admin menu to generate legal pages.30 3. Navigate to **Madquick PPG** in the WordPress admin menu to generate legal pages. 31 31 32 32 == Frequently Asked Questions == … … 48 48 This is the first stable release. Please update regularly to benefit from new features and security fixes. 49 49 50 = 1.0.2 = 51 52 Restructure internal pages, inside /pages/madquick-*.php 53 Redesign all the pages 54 Usages OOBs System 55 Using the correct naming of identifier that start with madquick-ppg or madquick_ppg 56 50 57 == Screenshots == 51 58 -
madquick-ppg/trunk/assets/css/home-page.css
r3239886 r3319446 1 /* create page */ 2 3 .wrap { 4 background: #fff; 5 padding: 12px; 6 min-height: 100vh; 7 } 8 1 9 .wrap-main { 2 10 background-color: #ffffff; 3 padding: 30px;11 padding: 16px; 4 12 border-radius: 8px; 5 13 box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); 6 14 max-width: 800px; 7 margin: 12px auto;15 /* margin: 12px auto; */ 8 16 } 9 17 10 18 #privacy-policy-form { 11 margin-top: 12px; 12 } 13 14 h1 { 15 line-height: 45px; 16 font-weight: bold; 17 margin-bottom: 30px; 18 padding-bottom: 20px; 19 border-bottom: 2px solid #eee; 20 font-size: 28px; 21 color: #333; 19 margin-top: 12px; 22 20 } 23 21 -
madquick-ppg/trunk/assets/css/plugin-page.css
r3239886 r3319446 1 1 .wrap { 2 2 margin-top: 20px; 3 } 4 5 .mq-legal-table-container { 6 width: 100%; 7 max-width: 700px; 8 /* margin: 32px auto 0 auto; */ 9 border-spacing: 0; 10 background: #fff; 11 border-radius: 12px; 12 /* box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08); */ 13 overflow: hidden; 14 } 15 16 .mq-legal-table-container td { 17 vertical-align: top; 18 padding: 0; 19 border: none; 20 } 21 22 .mq-policy-title { 23 /* font-size: 1.1rem; 24 font-weight: 600; 25 color: #23282d; 26 padding: 28px 32px 18px 32px; 27 border-right: 1px solid #f1f1f1; 28 background: #f9fafb; 29 min-width: 170px; */ 30 } 31 32 .mq-policy-card { 33 padding: 4px 12px; 34 } 35 36 .mq-policy-description { 37 color: #50575e; 38 margin-bottom: 16px; 39 font-size: 1rem; 40 } 41 42 @media (max-width: 600px) { 43 .mq-legal-table-container, 44 .mq-legal-table-container tbody, 45 .mq-legal-table-container tr, 46 .mq-legal-table-container td { 47 display: block; 48 width: 100% !important; 49 } 50 .mq-policy-title, 51 .mq-policy-card { 52 /* padding: 18px 14px; */ 53 border: none; 54 min-width: 0; 55 } 3 56 } 4 57 -
madquick-ppg/trunk/assets/js/generate-policy.js
r3239886 r3319446 54 54 const convertToPageContent = (formData) => { 55 55 const post_content = ` 56 57 <h2> Privacy Policy </h2> 58 59 <span style="font-weight: 400;">At ${ 60 formData?.websiteName ?? "" 61 }, accessible from ${ 62 formData.websiteURL 63 }, one of our main priorities is the privacy of our visitors. This Privacy Policy document contains types of information that is collected and recorded by test and how we use it.</span> <br><br> 64 65 <span style="font-weight: 400;">If you have additional questions or require more information about our Privacy Policy, do not hesitate to contact us.</span> <br><br> 66 67 <span style="font-weight: 400;">This Privacy Policy applies only to our online activities and is valid for visitors to our website with regards to the information that they shared and/or collected in test. This policy is not applicable to any information collected offline or via channels other than this website. Our Privacy Policy was created with the help of the </span><a href="https://privacypolicy-generator.com/"><span style="font-weight: 400;">Privacy Policy Generator.</span> <br><br></a> 68 <h2>Information we collect <br></h2> 69 <span style="font-weight: 400;">The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information.</span> <br><br> 70 <span>The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information. We also ask users to submit new passwords, if applicable. We prioritize security and understand the importance of strong passwords. That’s why we don’t use weak passwords on our website and recommend</span><a href="https://strong-password-generator.com/"><u><span style="color:#1155cc;"> tough password generator</span></u></a><span> to help safeguard your account from unauthorized access. This commitment helps protect our users' accounts and data, giving you peace of mind while using our services.</span><span style="font-weight: 400;">When you register for an Account, we may ask for your </span> <br><br> 71 72 Personal Information We Collect from Users:<br><br> 73 ${ 74 typeof formData.types_of_data_collected !== 75 "string" && 76 formData.types_of_data_collected 77 ?.map( 78 (data) => 79 "<li>" + data + "</li>" 80 ) 81 .join("") 82 } 83 ${ 84 "<li>" + 85 typeof formData.types_of_data_collected === 86 "string" 87 ? formData.types_of_data_collected 88 : "" + "</li>" 89 } 90 <h2>How we use your information <br></h2> 91 <span style="font-weight: 400;">We use the information we collect in various ways, including to:</span> <br><br> 92 <ul> 93 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Provide, operate, and maintain our website</span> <br><br></li> 94 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Improve, personalize, and expand our website</span> <br><br></li> 95 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Understand and analyze how you use our website</span> <br><br></li> 96 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Develop new products, services, features, and functionality</span> <br><br></li> 97 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Communicate with you, either directly or through one of our partners, including for customer service, to provide you with updates and other information relating to the website, and for marketing and promotional purposes</span> <br><br></li> 98 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Send you emails</span> <br><br></li> 99 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Find and prevent fraud</span> <br><br></li> 100 </ul> 101 102 103 <h2>Log Files <br></h2> 104 <span style="font-weight: 400;">test follows a standard procedure of using log files. These files log visitors when they visit websites. All hosting companies do this as part of hosting services’ analytics. The information collected by log files include internet protocol (IP) addresses, browser type, Internet Service Provider (ISP), date and time stamp, referring/exit pages, and possibly the number of clicks. These are not linked to any information that is personally identifiable. The purpose of the information is for analyzing trends, administering the site, tracking users’ movement on the website, and gathering demographic information.</span> <br><br> 105 106 <h2>Email Privacy Policies: <br></h2><span>Your privacy and security are what we care about most. To give you a better experience, we've updated our email privacy policies. We only allow real email addresses to make the space safer for everyone, and we've improved our encryption to protect your data. We do not allow <a href="https://temp-maill.org/">tempmail</a>.</span><br><br><h2>Updated Browser Policies for Enhanced Security and Privacy <br></h2> <span><span>We are committed to your security and have updated our browser policies to improve your privacy. Our new encryption standards, reduced cookie collection, and better protection against harmful content all contribute to a safer browsing experience.</span><a href="http://updatemybrowsers.com/"><span> </span>Update your browser</a><span> today.</span></span><br><br><h2>Adult Content and Compliance with Pornography Laws:<br></h2><span>We are dedicated to providing a respectful and secure online experience by following</span> <a href="https://pornography-laws.com/"><u><span>pornography laws</span></u></a><span>. Our platform bans adult content to ensure a family-friendly atmosphere. Our effective content moderation practices prevent any adult material from being published and address any violations promptly.</span><br><br><h2>Third Party Privacy Policies <br></h2> 107 <span style="font-weight: 400;">test’s Privacy Policy does not apply to other advertisers or websites. Thus, we are advising you to consult the respective Privacy Policies of these third-party ad servers for more detailed information. It may include their practices and instructions about how to opt-out of certain options.</span> <br><br> 108 109 <span style="font-weight: 400;">You can choose to disable cookies through your individual browser options. To know more detailed information about cookie management with specific web browsers, it can be found at the browsers’ respective websites.</span> <br><br> 110 <h2>CCPA Privacy Rights (Do Not Sell My Personal Information) <br></h2> 111 <span style="font-weight: 400;">Under the CCPA, among other rights, California consumers have the right to:</span> <br><br> 112 113 <span style="font-weight: 400;">Request that a business that collects a consumer’s personal data disclose the categories and specific pieces of personal data that a business has collected about consumers.</span> <br><br> 114 115 <span style="font-weight: 400;">Request that a business delete any personal data about the consumer that a business has collected.</span> <br><br> 116 117 <span style="font-weight: 400;">Request that a business that sells a consumer’s personal data, not sell the consumer’s personal data.</span> <br><br> 118 119 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 120 <h2>Use of Content</h2><span>We are dedicated to upholding high standards for content quality and integrity. Therefore, we strictly prohibit the use of</span><a href="https://lorem-ipsumm.com/"><u><span> Lorem Ipsum Generator</span></u></a><span> content, including but not limited to Lorem Ipsum text, on our website. All content must be original, relevant, and meaningful to our audience. This ensures that our website remains a valuable and trustworthy resource for our visitors.</span><br><br><h2>GDPR Data Protection Rights <br></h2> 121 <span style="font-weight: 400;">We would like to make sure you are fully aware of all of your data protection rights. Every user is entitled to the following:</span> <br><br> 122 123 <span style="font-weight: 400;">The right to access – You have the right to request copies of your personal data. We may charge you a small fee for this service.</span> <br><br> 124 125 <span style="font-weight: 400;">The right to rectification – You have the right to request that we correct any information you believe is inaccurate. You also have the right to request that we complete the information you believe is incomplete.</span> <br><br> 126 127 <span style="font-weight: 400;">The right to erasure – You have the right to request that we erase your personal data, under certain conditions.</span> <br><br> 128 129 <span style="font-weight: 400;">The right to restrict processing – You have the right to request that we restrict the processing of your personal data, under certain conditions.</span> <br><br> 130 131 <span style="font-weight: 400;">The right to object to processing – You have the right to object to our processing of your personal data, under certain conditions.</span> <br><br> 132 133 <span style="font-weight: 400;">The right to data portability – You have the right to request that we transfer the data that we have collected to another organization, or directly to you, under certain conditions.</span> <br><br> 134 135 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 136 <h2>Children’s Information <br></h2> 137 <span style="font-weight: 400;">Another part of our priority is adding protection for children while using the internet. We encourage parents and guardians to observe, participate in, and/or monitor and guide their online activity.</span> <br><br> 138 139 <span style="font-weight: 400;">test does not knowingly collect any Personal Identifiable Information from children under the age of 13. If you think that your child provided this kind of information on our website, we strongly encourage you to contact us immediately and we will do our best efforts to promptly remove such information from our records.</span> <br><br> 140 <p>For Entity Type, we use Individual platforms.</p>${ 141 formData.state ?? 142 " " + " " + formData.country ?? 143 " " 144 }<h2>Contact Us </h2>Contact Information<br><br>Email: ${ 145 formData?.websiteEmail ?? "" 146 }<br><br> 147 <br><br> 148 Phone: ${ 149 formData?.phoneNumber ?? "" 150 } 151 `; 56 <h2> Privacy Policy </h2> 57 58 <span style="font-weight: 400;">At ${ 59 formData?.websiteName ?? "" 60 }, accessible from ${ 61 formData.websiteURL 62 }, one of our main priorities is the privacy of our visitors. This Privacy Policy document contains types of information that is collected and recorded by test and how we use it.</span> <br><br> 63 64 <span style="font-weight: 400;">If you have additional questions or require more information about our Privacy Policy, do not hesitate to contact us.</span> <br><br> 65 66 <span style="font-weight: 400;">This Privacy Policy applies only to our online activities and is valid for visitors to our website with regards to the information that they shared and/or collected in test. This policy is not applicable to any information collected offline or via channels other than this website. Our Privacy Policy was created with the help of the </span><a href="https://privacypolicy-generator.com/"><span style="font-weight: 400;">Privacy Policy Generator.</span> <br><br></a> 67 <h2>Information we collect <br></h2> 68 <span style="font-weight: 400;">The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information.</span> <br><br> 69 <span>The personal information that you are asked to provide, and the reasons why you are asked to provide it, will be made clear to you at the point we ask you to provide your personal information. We also ask users to submit new passwords, if applicable. We prioritize security and understand the importance of strong passwords. That’s why we don’t use weak passwords on our website and recommend</span><a href="https://strong-password-generator.com/"><u><span style="color:#1155cc;"> tough password generator</span></u></a><span> to help safeguard your account from unauthorized access. This commitment helps protect our users' accounts and data, giving you peace of mind while using our services.</span><span style="font-weight: 400;">When you register for an Account, we may ask for your </span> <br><br> 70 71 Personal Information We Collect from Users:<br><br> 72 ${ 73 typeof formData.types_of_data_collected !== 74 "string" && 75 formData.types_of_data_collected 76 ?.map( 77 (data) => 78 "<li>" + data + "</li>" 79 ) 80 .join("") 81 } 82 ${ 83 "<li>" + 84 typeof formData.types_of_data_collected === 85 "string" 86 ? formData.types_of_data_collected 87 : "" + "</li>" 88 } 89 <h2>How we use your information <br></h2> 90 <span style="font-weight: 400;">We use the information we collect in various ways, including to:</span> <br><br> 91 <ul> 92 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Provide, operate, and maintain our website</span> <br><br></li> 93 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Improve, personalize, and expand our website</span> <br><br></li> 94 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Understand and analyze how you use our website</span> <br><br></li> 95 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Develop new products, services, features, and functionality</span> <br><br></li> 96 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Communicate with you, either directly or through one of our partners, including for customer service, to provide you with updates and other information relating to the website, and for marketing and promotional purposes</span> <br><br></li> 97 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Send you emails</span> <br><br></li> 98 <li style="font-weight: 400;" aria-level="1"><span style="font-weight: 400;">Find and prevent fraud</span> <br><br></li> 99 </ul> 100 101 102 <h2>Log Files <br></h2> 103 <span style="font-weight: 400;">test follows a standard procedure of using log files. These files log visitors when they visit websites. All hosting companies do this as part of hosting services’ analytics. The information collected by log files include internet protocol (IP) addresses, browser type, Internet Service Provider (ISP), date and time stamp, referring/exit pages, and possibly the number of clicks. These are not linked to any information that is personally identifiable. The purpose of the information is for analyzing trends, administering the site, tracking users’ movement on the website, and gathering demographic information.</span> <br><br> 104 105 <h2>Email Privacy Policies: <br></h2><span>Your privacy and security are what we care about most. To give you a better experience, we've updated our email privacy policies. We only allow real email addresses to make the space safer for everyone, and we've improved our encryption to protect your data. We do not allow <a href="https://temp-maill.org/">tempmail</a>.</span><br><br><h2>Updated Browser Policies for Enhanced Security and Privacy <br></h2> <span><span>We are committed to your security and have updated our browser policies to improve your privacy. Our new encryption standards, reduced cookie collection, and better protection against harmful content all contribute to a safer browsing experience.</span><a href="http://updatemybrowsers.com/"><span> </span>Update your browser</a><span> today.</span></span><br><br><h2>Adult Content and Compliance with Pornography Laws:<br></h2><span>We are dedicated to providing a respectful and secure online experience by following</span> <a href="https://pornography-laws.com/"><u><span>pornography laws</span></u></a><span>. Our platform bans adult content to ensure a family-friendly atmosphere. Our effective content moderation practices prevent any adult material from being published and address any violations promptly.</span><br><br><h2>Third Party Privacy Policies <br></h2> 106 <span style="font-weight: 400;">test’s Privacy Policy does not apply to other advertisers or websites. Thus, we are advising you to consult the respective Privacy Policies of these third-party ad servers for more detailed information. It may include their practices and instructions about how to opt-out of certain options.</span> <br><br> 107 108 <span style="font-weight: 400;">You can choose to disable cookies through your individual browser options. To know more detailed information about cookie management with specific web browsers, it can be found at the browsers’ respective websites.</span> <br><br> 109 <h2>CCPA Privacy Rights (Do Not Sell My Personal Information) <br></h2> 110 <span style="font-weight: 400;">Under the CCPA, among other rights, California consumers have the right to:</span> <br><br> 111 112 <span style="font-weight: 400;">Request that a business that collects a consumer’s personal data disclose the categories and specific pieces of personal data that a business has collected about consumers.</span> <br><br> 113 114 <span style="font-weight: 400;">Request that a business delete any personal data about the consumer that a business has collected.</span> <br><br> 115 116 <span style="font-weight: 400;">Request that a business that sells a consumer’s personal data, not sell the consumer’s personal data.</span> <br><br> 117 118 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 119 <h2>Use of Content</h2><span>We are dedicated to upholding high standards for content quality and integrity. Therefore, we strictly prohibit the use of</span><a href="https://lorem-ipsumm.com/"><u><span> Lorem Ipsum Generator</span></u></a><span> content, including but not limited to Lorem Ipsum text, on our website. All content must be original, relevant, and meaningful to our audience. This ensures that our website remains a valuable and trustworthy resource for our visitors.</span><br><br><h2>GDPR Data Protection Rights <br></h2> 120 <span style="font-weight: 400;">We would like to make sure you are fully aware of all of your data protection rights. Every user is entitled to the following:</span> <br><br> 121 122 <span style="font-weight: 400;">The right to access – You have the right to request copies of your personal data. We may charge you a small fee for this service.</span> <br><br> 123 124 <span style="font-weight: 400;">The right to rectification – You have the right to request that we correct any information you believe is inaccurate. You also have the right to request that we complete the information you believe is incomplete.</span> <br><br> 125 126 <span style="font-weight: 400;">The right to erasure – You have the right to request that we erase your personal data, under certain conditions.</span> <br><br> 127 128 <span style="font-weight: 400;">The right to restrict processing – You have the right to request that we restrict the processing of your personal data, under certain conditions.</span> <br><br> 129 130 <span style="font-weight: 400;">The right to object to processing – You have the right to object to our processing of your personal data, under certain conditions.</span> <br><br> 131 132 <span style="font-weight: 400;">The right to data portability – You have the right to request that we transfer the data that we have collected to another organization, or directly to you, under certain conditions.</span> <br><br> 133 134 <span style="font-weight: 400;">If you make a request, we have one month to respond to you. If you would like to exercise any of these rights, please contact us.</span> <br><br> 135 <h2>Children’s Information <br></h2> 136 <span style="font-weight: 400;">Another part of our priority is adding protection for children while using the internet. We encourage parents and guardians to observe, participate in, and/or monitor and guide their online activity.</span> <br><br> 137 138 <span style="font-weight: 400;">test does not knowingly collect any Personal Identifiable Information from children under the age of 13. If you think that your child provided this kind of information on our website, we strongly encourage you to contact us immediately and we will do our best efforts to promptly remove such information from our records.</span> <br><br> 139 <p>For Entity Type, we use Individual platforms.</p>${ 140 formData.state ?? 141 " " + " " + formData.country ?? 142 " " 143 }<h2>Contact Us </h2>Contact Information<br><br>Email: ${ 144 formData?.websiteEmail ?? "" 145 }<br><br> 146 <br><br> 147 Phone: ${ 148 formData?.phoneNumber ?? "" 149 } 150 `; 152 151 153 152 savePost(post_content); … … 155 154 156 155 const savePost = (post_content) => { 157 console.log(post_content);158 156 159 if (typeof ajax_object=== "undefined") {160 console.error(" ajax_objectis not defined");157 if (typeof madquick_ppg_ajax === "undefined") { 158 console.error("madquick_ppg_ajax is not defined"); 161 159 return; 162 160 } … … 164 162 // Use jQuery's ajax method 165 163 jQuery.ajax({ 166 url: ajax_object.ajax_url,164 url: madquick_ppg_ajax.ajax_url, 167 165 type: "POST", 168 166 dataType: "json", … … 170 168 action: "create_custom_page", 171 169 post_content: post_content, 172 nonce: ajax_object.nonce,170 nonce: madquick_ppg_ajax.nonce, 173 171 }, 174 172 success: function (response) { -
madquick-ppg/trunk/madquick-ppg.php
r3240916 r3319446 1 1 <?php 2 3 2 /** 4 3 * Plugin Name: Privacy Policy Generator - Madquick 5 4 * Author URI: https://github.com/Madquick-Private-Limited/ 6 * Requires at least: 6. 37 * Requires PHP: 7. 2.248 * Version: 1.0. 19 * Description: A simple wordpress plugin that help us to generate privacy and policy page and other legal pages that are required inyour website.5 * Requires at least: 6.8 6 * Requires PHP: 7.4 7 * Version: 1.0.2 8 * Description: Generate privacy policy, terms, and legal pages required for your website. 10 9 * License: GPLv2 or later 11 10 * License URI: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html 12 * Keywords: privacy, policy, terms, legal, compliance, GDPR, madquick13 11 * Text Domain: madquick-ppg 14 * 12 * 15 13 * @package madquick-ppg 16 14 */ 17 15 18 defined( "ABSPATH") || exit;16 defined('ABSPATH') || exit; 19 17 20 /* imports */ 21 // require_once "Madquick_Page_CPT.php"; 22 require_once "ajax/create-ppg-page.php"; 18 define('MADQUICK_PPG_PATH', plugin_dir_path(__FILE__)); 19 define('MADQUICK_PPG_URL', plugin_dir_url(__FILE__)); 23 20 24 function madquick_enqueue_scripts($hook_suffix) 25 { 26 // Define the plugin directory path for file versioning 27 $plugin_dir = plugin_dir_path(__FILE__); 21 // Required files 22 require_once MADQUICK_PPG_PATH . 'ajax/create-ppg-page.php'; 28 23 29 // Enqueue the script and set 'jquery' as a dependency, with versioning 30 wp_enqueue_script( 31 'generate-policy-script', 32 plugin_dir_url(__FILE__) . 'assets/js/generate-policy.js', 33 ['jquery'], 34 filemtime($plugin_dir . 'assets/js/generate-policy.js'), // Dynamic version based on last modified time 35 true // Load in the footer 36 ); 24 if (!class_exists('Madquick_PPG')) { 37 25 38 // Enqueue the CSS files with dynamic versioning 39 wp_enqueue_style( 40 "home-page-css", 41 plugin_dir_url(__FILE__) . "assets/css/home-page.css", 42 [], 43 filemtime($plugin_dir . "assets/css/home-page.css") 44 ); 26 class Madquick_PPG { 45 27 46 wp_enqueue_style( 47 "plugin-page-css", 48 plugin_dir_url(__FILE__) . "assets/css/plugin-page.css", 49 [], 50 filemtime($plugin_dir . "assets/css/plugin-page.css") 51 ); 28 public function __construct() { 29 add_action('admin_menu', [$this, 'register_admin_menu']); 30 add_action('admin_enqueue_scripts', [$this, 'enqueue_admin_assets']); 31 } 52 32 53 // Localize the script immediately after enqueueing 54 wp_localize_script('generate-policy-script', 'ajax_object', [ 55 'ajax_url' => admin_url('admin-ajax.php'), 56 'nonce' => wp_create_nonce('madquick_nonce'), 57 ]); 58 } 59 add_action('admin_enqueue_scripts', 'madquick_enqueue_scripts'); 33 /** 34 * Enqueue plugin scripts and styles only on our pages. 35 */ 36 public function enqueue_admin_assets($hook) { 37 $screen = get_current_screen(); 38 if ( 39 isset($screen->id) && 40 (strpos($screen->id, 'madquick-ppg-home') !== false || 41 strpos($screen->id, 'madquick-ppg-help') !== false || 42 strpos($screen->id, 'madquick-ppg-create') !== false) 43 ) { 44 wp_enqueue_style( 45 'madquick-ppg-plugin-page', 46 MADQUICK_PPG_URL . 'assets/css/plugin-page.css', 47 [], 48 filemtime(MADQUICK_PPG_PATH . 'assets/css/plugin-page.css') 49 ); 50 wp_enqueue_style( 51 'madquick-ppg-home-page', 52 MADQUICK_PPG_URL . 'assets/css/home-page.css', 53 [], 54 filemtime(MADQUICK_PPG_PATH . 'assets/css/home-page.css') 55 ); 56 wp_enqueue_script( 57 'madquick-ppg-generate-policy', 58 MADQUICK_PPG_URL . 'assets/js/generate-policy.js', 59 ['jquery'], 60 filemtime(MADQUICK_PPG_PATH . 'assets/js/generate-policy.js'), 61 true 62 ); 63 wp_localize_script('madquick-ppg-generate-policy', 'madquick_ppg_ajax', [ 64 'ajax_url' => admin_url('admin-ajax.php'), 65 'nonce' => wp_create_nonce('madquick_nonce'), 66 ]); 67 } 68 } 60 69 70 /** 71 * Register admin menu and submenus. 72 */ 73 public function register_admin_menu() { 74 add_menu_page( 75 __('Privacy & Policy Generator', 'madquick-ppg'), 76 __('Privacy & Policy Generator', 'madquick-ppg'), 77 'manage_options', 78 'madquick-ppg-home', 79 [$this, 'render_main_page'], 80 'dashicons-shield-alt', 81 20 82 ); 61 83 62 // Hook to add the custom admin menu 63 add_action('admin_menu', 'madquick_ppg_add_admin_menu'); 84 add_submenu_page( 85 'madquick-ppg-home', 86 __('Help', 'madquick-ppg'), 87 __('Help', 'madquick-ppg'), 88 'manage_options', 89 'madquick-ppg-help', 90 [$this, 'render_help_page'] 91 ); 64 92 65 // defined in cpt page 66 // add_action('init', 'madquick_register_custom_post_type'); 93 // "Create" page, hidden from menu but routable 94 add_submenu_page( 95 null, 96 __('Create Legal Page', 'madquick-ppg'), 97 __('Create', 'madquick-ppg'), 98 'manage_options', 99 'madquick-ppg-create', 100 [$this, 'render_create_page'] 101 ); 102 } 67 103 68 function madquick_ppg_add_admin_menu() 69 { 104 /** 105 * Main dashboard/page router. 106 */ 107 public function render_main_page() { 108 $action = isset($_GET['current-action']) ? sanitize_text_field(wp_unslash($_GET['current-action'])) : ''; 109 $nonce = isset($_GET['madquick_ppg_nonce']) ? sanitize_text_field(wp_unslash($_GET['madquick_ppg_nonce'])) : ''; 70 110 71 // Main menu 72 add_menu_page( 73 'Privary & Policy Generator', // Page title 74 'Privary & Policy Generator', // Menu title 75 'manage_options', // Capability required to access the menu 76 'madquick-ppg-home', // Menu slug (unique identifier) 77 'madquick_ppg_add_legal_page_cb', // Function to display the page content 78 'dashicons-admin-generic', 79 20 80 ); 111 if ($action && $nonce && wp_verify_nonce($nonce, 'madquick_create_ppg_nonce')) { 112 $this->include_page('madquick-ppg-create.php'); 113 } else { 114 $this->include_page('madquick-ppg-main.php'); 115 } 116 } 81 117 82 add_submenu_page( 83 'madquick-ppg-home', // Parent slug (must match the slug of the main menu) 84 'Help', // Page title 85 'Help', // Submenu title 86 'manage_options', // Capability required to access this submenu 87 'madquick-ppg-help', // Submenu slug (unique identifier) 88 'madquick_ppg_help_page' // Function to display the content of the submenu page 89 ); 90 } 118 /** 119 * Help submenu page. 120 */ 121 public function render_help_page() { 122 $this->include_page('madquick-ppg-help.php'); 123 } 91 124 125 /** 126 * Create page, can be routed directly. 127 */ 128 public function render_create_page() { 129 $this->include_page('madquick-ppg-create.php'); 130 } 92 131 93 function madquick_ppg_add_legal_page_cb() 94 { 95 $current_action = "none"; 96 97 // Check for 'current-action' and 'my_nonce' in the URL 98 if (isset($_GET['current-action']) && isset($_GET['my_nonce'])) { 99 // Properly unslash and sanitize the nonce parameter before verifying 100 $nonce = sanitize_text_field(wp_unslash($_GET['my_nonce'])); 101 102 // Verify the nonce to ensure the request is valid 103 if (wp_verify_nonce($nonce, 'madquick_create_ppg_nonce')) { 104 // Properly unslash and sanitize the action parameter 105 $current_action = wp_kses_post(wp_unslash($_GET['current-action'])); 106 } else { 107 // If nonce verification fails, stop the process and show an error 108 wp_die('Unauthorized request'); 132 /** 133 * Utility to include a page from /pages. 134 */ 135 private function include_page($file) { 136 $filepath = MADQUICK_PPG_PATH . 'pages/' . $file; 137 if (file_exists($filepath)) { 138 include $filepath; 139 } else { 140 echo esc_html__('Page not found.', 'madquick-ppg'); 141 } 109 142 } 110 143 } 111 144 112 113 ?> 114 115 <!-- main page --> 116 <?php if ($current_action === "none"): ?> 117 118 <!-- link plugin-page.css --> 119 120 <div class="wrap"> 121 <h1 class="wp-heading-inline"><?php esc_html_e('All Legal Pages', 'madquick-ppg'); ?></h1> 122 123 <table class="table-container"> 124 <tbody> 125 <tr> 126 <td style="width: 40%;"> 127 <p class="policy-title"><?php esc_html_e('Privacy Policy', 'madquick-ppg'); ?></p> 128 </td> 129 <td> 130 <div class="policy-card"> 131 <p class="policy-description"> 132 <?php esc_html_e('Create a simple Privacy Policy for your WordPress website.', 'madquick-ppg'); ?> 133 </p> 134 <?php 135 $url = wp_nonce_url( 136 add_query_arg( 137 [ 138 'page' => 'madquick-ppg-home', 139 'current-action' => 'create-ppg' 140 ], 141 admin_url('admin.php') 142 ), 143 'madquick_create_ppg_nonce', 144 'my_nonce' 145 ); 146 ?> 147 <a class="button button-primary" href="<?php echo esc_url($url); ?>"> 148 <?php esc_html_e('Create', 'madquick-ppg'); ?> 149 </a> 150 151 </div> 152 </td> 153 </tr> 154 <tr> 155 <td style="width: 40%;"> 156 <p class="policy-title"><?php esc_html_e('Terms & Conditions', 'madquick-ppg'); ?></p> 157 </td> 158 <td> 159 <div class="policy-card"> 160 <p class="policy-description"> 161 <?php esc_html_e('Create Terms & Conditions for your WordPress website.', 'madquick-ppg'); ?> 162 </p> 163 <a class="button button-primary" href="#"> 164 <?php esc_html_e('Create', 'madquick-ppg'); ?> 165 </a> 166 </div> 167 </td> 168 </tr> 169 </tbody> 170 </table> 171 </div> 172 173 174 <?php endif; ?> 175 176 <!-- PPG Page --> 177 <?php if ($current_action === "create-ppg"): ?> 178 179 <!-- link css home-page.css --> 180 181 <div class="wrap-main"> 182 <h1><?php esc_html_e('All Legal Pages', 'madquick-ppg'); ?></h1> 183 184 <!-- ppg form --> 185 <form id="privacy-policy-form" method="post" action="#"> 186 <h2 style="font-size: 20px;"> 187 <?php echo esc_html_e("Website Information to generate privacy policy", "madquick-ppg"); ?> 188 </h2> 189 <!-- Website --> 190 <div class="input-field"> 191 <label for="websiteName">What is your website name?</label> 192 <input type="text" id="websiteName" name="websiteName" placeholder="website name name" class="form-control"> 193 </div> 194 <!-- Website --> 195 <div class="input-field"> 196 <label for="websiteURL">What is your website URL?</label> 197 <input type="text" id="websiteURL" name="websiteURL" placeholder="Website URL" class="form-control"> 198 </div> 199 200 <!-- Entity Type --> 201 <div class="input-field"> 202 <label for="entityType">Entity Type</label> 203 204 <div> 205 <input type="radio" name="entityType" value="Business" id="business" 206 onclick="toggleContent('companyname', true)"> 207 <label for="business">I'm a Business</label> 208 </div> 209 210 <div> 211 <input type="radio" name="entityType" value="Individual" id="individual" 212 onclick="toggleContent('companyname', false)"> 213 <label for="individual">I'm an Individual</label> 214 </div> 215 </div> 216 217 <!-- Business Details --> 218 <div id="companyname" class="inner-section" style="display: none;"> 219 <div class="input-field"> 220 <label class="title">What is the name of the business?</label> 221 <input id="company_name" name="company_name" type="text" placeholder="My Company LLC" 222 class="form-control"> 223 <div class="help-text-bottom">e.g. My Company LLC</div> 224 </div> 225 226 <div class="input-field"> 227 <label class="title">What is the address of the business?</label> 228 <input id="company_address" name="company_address" type="text" placeholder="1 Cupertino, CA 95014" 229 class="form-control"> 230 <div class="help-text-bottom">e.g. 1 Cupertino, CA 95014</div> 231 </div> 232 </div> 233 234 <!-- Country and State --> 235 <div class="input-field"> 236 <label for="country">Enter the country</label> 237 <input type="text" id="country" name="country" placeholder="Enter the country" class="form-control"> 238 </div> 239 240 <div class="input-field"> 241 <label for="state">Enter the state</label> 242 <input type="text" id="state" name="state" placeholder="Enter the state" class="form-control"> 243 </div> 244 245 <!-- Personal Information Collected --> 246 <div class="input-field"> 247 <h2 class="" style="font-size: 24px;"> 248 Data Collection Information 249 </h2> 250 <label for="personalInfo">What kind of personal information do you collect from users?</label> 251 <p>Click all that apply</p> 252 <div class="checkbox-group"> 253 <div> 254 <input type="checkbox" name="types_of_data_collected" id="email" value="Email"> 255 <label for="email">Email address</label> 256 </div> 257 <div> 258 <input type="checkbox" name="types_of_data_collected" id="name" value="Name"> 259 <label for="name">First name and last name</label> 260 </div> 261 <div> 262 <input type="checkbox" name="types_of_data_collected" id="phone" value="Phone"> 263 <label for="phone">Phone number</label> 264 </div> 265 <div> 266 <input type="checkbox" name="types_of_data_collected" id="address" value="Address"> 267 <label for="address">Address, State, Province, ZIP/Postal code, City</label> 268 </div> 269 <div> 270 <input type="checkbox" name="types_of_data_collected" id="socialMedia" value="Social Media Login"> 271 <label for="socialMedia">Social Media Profile information (e.g., from Facebook, Twitter)</label> 272 </div> 273 </div> 274 </div> 275 276 <!-- Contact Method --> 277 <div class="input-field"> 278 <h2 style="font-size: 20px;"> 279 Contact Information Want To Put In Privacy Policy 280 </h2> 281 <label for="company_contact">How can the company contact users?</label> 282 283 <div class="checkbox-group"> 284 <div> 285 <input type="checkbox" name="company_contact" id="emailCheckbox" value="Email" 286 onchange="toggleFields('email')"> 287 <label for="emailCheckbox">By email</label> 288 </div> 289 290 <div id="emailFields" style="display: none;"> 291 <input type="email" id="websiteEmail" name="websiteEmail" placeholder="Website/Email" 292 class="form-control"> 293 </div> 294 295 <div> 296 <input type="checkbox" name="company_contact" id="linkCheckbox" value="Link" 297 onchange="toggleFields('link')"> 298 <label for="linkCheckbox">By visiting a page on our website</label> 299 </div> 300 301 <div id="linkFields" style="display: none;"> 302 <input type="text" id="websitePage" name="websitePage" placeholder="Page URL" class="form-control"> 303 </div> 304 305 <div> 306 <input type="checkbox" name="company_contact" id="phoneCheckbox" value="Phone" 307 onchange="toggleFields('phone')"> 308 <label for="phoneCheckbox">By phone number</label> 309 </div> 310 311 <div id="phoneFields" style="display: none;"> 312 <input type="tel" id="phoneNumber" name="phoneNumber" placeholder="Phone number" 313 class="form-control"> 314 </div> 315 316 <div> 317 <input type="checkbox" name="company_contact" id="addressCheckbox" value="Address" 318 onchange="toggleFields('address')"> 319 <label for="addressCheckbox">By sending post mail</label> 320 </div> 321 322 <div id="addressFields" style="display: none;"> 323 <input type="text" id="postAddress" name="postAddress" placeholder="Postal Address" 324 class="form-control"> 325 </div> 326 </div> 327 </div> 328 329 <!-- Submit Button --> 330 <button class="button button-primary">Generate</button> 331 </form> 332 333 <script> 334 335 </script> 336 </div> 337 338 339 <?php endif; ?> 340 341 <?php 145 // Initialize plugin 146 new Madquick_PPG(); 342 147 } 343 344 345 // Function to display the content of the "Madquick PPG" (submenu) page346 function madquick_ppg_help_page()347 {348 ?>349 <div class="wrap">350 <h1><?php esc_html_e('Help & Documentation', 'madquick-ppg'); ?></h1>351 <p><?php esc_html_e('Welcome to the Madquick Privacy & Policy Generator Help section. Here you’ll find useful information and guides on how to use the plugin effectively.', 'madquick-ppg'); ?>352 </p>353 354 <h2><?php esc_html_e('Table of Contents', 'madquick-ppg'); ?></h2>355 <ul>356 <li><a href="#overview"><?php esc_html_e('Overview', 'madquick-ppg'); ?></a></li>357 <li><a href="#how-to-use"><?php esc_html_e('How to Use', 'madquick-ppg'); ?></a></li>358 <li><a href="#faq"><?php esc_html_e('Frequently Asked Questions', 'madquick-ppg'); ?></a></li>359 <li><a href="#support"><?php esc_html_e('Support', 'madquick-ppg'); ?></a></li>360 </ul>361 362 <hr>363 364 <h2 id="overview"><?php esc_html_e('Overview', 'madquick-ppg'); ?></h2>365 <p><?php esc_html_e('Madquick PPG helps you quickly generate essential legal pages like Privacy Policy and Terms & Conditions. It ensures your site stays compliant with privacy laws such as GDPR and CCPA.', 'madquick-ppg'); ?>366 </p>367 368 <h2 id="how-to-use"><?php esc_html_e('How to Use', 'madquick-ppg'); ?></h2>369 <ol>370 <li><?php esc_html_e('Go to the plugin settings page under "Madquick PPG".', 'madquick-ppg'); ?></li>371 <li><?php esc_html_e('Select the type of legal page you want to create (Privacy Policy or Terms & Conditions).', 'madquick-ppg'); ?>372 </li>373 <li><?php esc_html_e('Click the "Create" button.', 'madquick-ppg'); ?></li>374 <li><?php esc_html_e('Edit the generated content as needed.', 'madquick-ppg'); ?></li>375 <li><?php esc_html_e('Save and publish the page.', 'madquick-ppg'); ?></li>376 </ol>377 378 <h2 id="faq"><?php esc_html_e('Frequently Asked Questions', 'madquick-ppg'); ?></h2>379 <dl>380 <dt><?php esc_html_e('Can I customize the generated pages?', 'madquick-ppg'); ?></dt>381 <dd><?php esc_html_e('Yes, all generated pages can be edited directly within the WordPress editor.', 'madquick-ppg'); ?>382 </dd>383 384 <dt><?php esc_html_e('Does the plugin ensure GDPR compliance?', 'madquick-ppg'); ?></dt>385 <dd><?php esc_html_e('The plugin provides a template that helps you stay compliant, but we recommend reviewing it to ensure it meets your specific needs.', 'madquick-ppg'); ?>386 </dd>387 388 <dt><?php esc_html_e('Can I regenerate the legal pages if needed?', 'madquick-ppg'); ?></dt>389 <dd><?php esc_html_e('Yes, you can regenerate pages at any time by visiting the plugin settings.', 'madquick-ppg'); ?>390 </dd>391 </dl>392 393 <h2 id="support"><?php esc_html_e('Support', 'madquick-ppg'); ?></h2>394 <p><?php esc_html_e('If you encounter any issues or have questions, please contact us at', 'madquick-ppg'); ?>395 <a href="mailto:tech@madquick.in">tech@madquick.in</a>.396 </p>397 </div>398 <?php399 }400 -
madquick-ppg/trunk/readme.txt
r3240916 r3319446 1 1 === Privacy Policy Generator - Madquick === 2 Contributors: madquick 2 Contributors: madquick team 3 3 Tags: privacy, policy, terms, legal, GDPR 4 Requires at least: 6. 35 Tested up to: 6. 74 Requires at least: 6.8 5 Tested up to: 6.8 6 6 Requires PHP: 7.4 7 Stable tag: 1.0. 17 Stable tag: 1.0.2 8 8 License: GPLv2 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 13 13 == Description == 14 14 15 Privacy Policy Generator - Madquickis an easy-to-use plugin that enables website owners to quickly generate **Privacy Policies** and **Terms & Conditions** pages. This tool helps ensure that your website complies with privacy laws such as **GDPR** and **CCPA**. The generated pages are customizable, mobile-friendly, and designed to integrate seamlessly with WordPress.15 Madquick PPG is an easy-to-use plugin that enables website owners to quickly generate **Privacy Policies** and **Terms & Conditions** pages. This tool helps ensure that your website complies with privacy laws such as **GDPR** and **CCPA**. The generated pages are customizable, mobile-friendly, and designed to integrate seamlessly with WordPress. 16 16 17 17 == Features == … … 28 28 1. Upload the plugin files to the `/wp-content/plugins/madquick-ppg/` directory, or install the plugin through the WordPress plugins screen directly. 29 29 2. Activate the plugin through the 'Plugins' screen in WordPress. 30 3. Navigate to ** Privacy Policy Generator - Madquick** in the WordPress admin menu to generate legal pages.30 3. Navigate to **Madquick PPG** in the WordPress admin menu to generate legal pages. 31 31 32 32 == Frequently Asked Questions == … … 48 48 This is the first stable release. Please update regularly to benefit from new features and security fixes. 49 49 50 = 1.0.2 = 51 52 Restructure internal pages, inside /pages/madquick-*.php 53 Redesign all the pages 54 Usages OOBs System 55 Using the correct naming of identifier that start with madquick-ppg or madquick_ppg 56 50 57 == Screenshots == 51 58
Note: See TracChangeset
for help on using the changeset viewer.