PageRenderTime 61ms CodeModel.GetById 19ms RepoModel.GetById 1ms app.codeStats 0ms

/wp-content/plugins/wpforms-lite/includes/admin/class-about.php

https://gitlab.com/ebrjose/comcebu
PHP | 1207 lines | 931 code | 133 blank | 143 comment | 34 complexity | f21926326ff7c434eae7b338e89eb49f MD5 | raw file
  1. <?php
  2. /**
  3. * About WPForms admin page class.
  4. *
  5. * @since 1.5.0
  6. */
  7. class WPForms_About {
  8. /**
  9. * Admin menu page slug.
  10. *
  11. * @since 1.5.0
  12. *
  13. * @var string
  14. */
  15. const SLUG = 'wpforms-about';
  16. /**
  17. * Default view for a page.
  18. *
  19. * @since 1.5.0
  20. *
  21. * @var string
  22. */
  23. const DEFAULT_TAB = 'about';
  24. /**
  25. * Array of license types, that are considered being top level and has no features difference.
  26. *
  27. * @since 1.5.0
  28. *
  29. * @var array
  30. */
  31. public static $licenses_top = array( 'pro', 'agency', 'ultimate', 'elite' );
  32. /**
  33. * List of features that licenses are different with.
  34. *
  35. * @since 1.5.0
  36. *
  37. * @var array
  38. */
  39. public static $licenses_features = array();
  40. /**
  41. * The current active tab.
  42. *
  43. * @since 1.5.0
  44. *
  45. * @var string
  46. */
  47. public $view;
  48. /**
  49. * The core views.
  50. *
  51. * @since 1.5.0
  52. *
  53. * @var array
  54. */
  55. public $views = array();
  56. /**
  57. * Primary class constructor.
  58. *
  59. * @since 1.5.0
  60. */
  61. public function __construct() {
  62. // In old PHP we can't define this elsewhere.
  63. self::$licenses_features = array(
  64. 'entries' => esc_html__( 'Form Entries', 'wpforms-lite' ),
  65. 'fields' => esc_html__( 'Form Fields', 'wpforms-lite' ),
  66. 'templates' => esc_html__( 'Form Templates', 'wpforms-lite' ),
  67. 'conditionals' => esc_html__( 'Smart Conditional Logic', 'wpforms-lite' ),
  68. 'marketing' => esc_html__( 'Marketing Integrations', 'wpforms-lite' ),
  69. 'payments' => esc_html__( 'Payment Forms', 'wpforms-lite' ),
  70. 'surveys' => esc_html__( 'Surveys & Polls', 'wpforms-lite' ),
  71. 'advanced' => esc_html__( 'Advanced Form Features', 'wpforms-lite' ),
  72. 'addons' => esc_html__( 'WPForms Addons', 'wpforms-lite' ),
  73. 'support' => esc_html__( 'Customer Support', 'wpforms-lite' ),
  74. 'sites' => esc_html__( 'Number of Sites', 'wpforms-lite' ),
  75. );
  76. // Maybe load tools page.
  77. add_action( 'admin_init', array( $this, 'init' ) );
  78. }
  79. /**
  80. * Determining if the user is viewing the our page, if so, party on.
  81. *
  82. * @since 1.5.0
  83. */
  84. public function init() {
  85. // Check what page we are on.
  86. $page = isset( $_GET['page'] ) ? $_GET['page'] : '';
  87. // Only load if we are actually on the settings page.
  88. if ( self::SLUG !== $page ) {
  89. return;
  90. }
  91. /*
  92. * Define the core views for the our tab.
  93. */
  94. $this->views = apply_filters(
  95. 'wpforms_admin_about_views',
  96. array(
  97. esc_html__( 'About Us', 'wpforms-lite' ) => array( 'about' ),
  98. esc_html__( 'Getting Started', 'wpforms-lite' ) => array( 'getting-started' ),
  99. )
  100. );
  101. $license = $this->get_license_type();
  102. if (
  103. (
  104. $license === 'pro' ||
  105. ! in_array( $license, self::$licenses_top, true )
  106. ) ||
  107. wpforms_debug()
  108. ) {
  109. $vs_tab_name = sprintf( /* translators: %1$s - current license type; %2$s - suggested license type. */
  110. esc_html__( '%1$s vs %2$s', 'wpforms-lite' ),
  111. ucfirst( $license ),
  112. $this->get_next_license( $license )
  113. );
  114. $this->views[ $vs_tab_name ] = array( 'versus' );
  115. }
  116. // Determine the current active settings tab.
  117. $this->view = ! empty( $_GET['view'] ) ? esc_html( $_GET['view'] ) : self::DEFAULT_TAB;
  118. // If the user tries to load an invalid view - fallback to About Us.
  119. if (
  120. ! in_array( $this->view, call_user_func_array( 'array_merge', array_values( $this->views ) ), true ) &&
  121. ! has_action( 'wpforms_admin_about_display_tab_' . sanitize_key( $this->view ) )
  122. ) {
  123. $this->view = self::DEFAULT_TAB;
  124. }
  125. add_action( 'wpforms_admin_page', array( $this, 'output' ) );
  126. // Hook for addons.
  127. do_action( 'wpforms_admin_about_init' );
  128. }
  129. /**
  130. * Output the basic page structure.
  131. *
  132. * @since 1.5.0
  133. */
  134. public function output() {
  135. $show_nav = false;
  136. foreach ( $this->views as $view ) {
  137. if ( in_array( $this->view, (array) $view, true ) ) {
  138. $show_nav = true;
  139. break;
  140. }
  141. }
  142. ?>
  143. <div id="wpforms-admin-about" class="wrap wpforms-admin-wrap">
  144. <?php
  145. if ( $show_nav ) {
  146. $license = $this->get_license_type();
  147. $next_license = $this->get_next_license( $license );
  148. echo '<ul class="wpforms-admin-tabs">';
  149. foreach ( $this->views as $label => $view ) {
  150. $class = in_array( $this->view, $view, true ) ? 'active' : '';
  151. echo '<li>';
  152. printf(
  153. '<a href="%s" class="%s">%s</a>',
  154. esc_url( admin_url( 'admin.php?page=' . self::SLUG . '&view=' . sanitize_key( $view[0] ) ) ),
  155. esc_attr( $class ),
  156. esc_html( $label )
  157. );
  158. echo '</li>';
  159. }
  160. echo '</ul>';
  161. }
  162. ?>
  163. <h1 class="wpforms-h1-placeholder"></h1>
  164. <?php
  165. switch ( $this->view ) {
  166. case 'about':
  167. $this->output_about();
  168. break;
  169. case 'getting-started':
  170. $this->output_getting_started();
  171. break;
  172. case 'versus':
  173. $this->output_versus();
  174. break;
  175. default:
  176. do_action( 'wpforms_admin_about_display_tab_' . sanitize_key( $this->view ) );
  177. break;
  178. }
  179. ?>
  180. </div>
  181. <?php
  182. }
  183. /**
  184. * Display the About tab content.
  185. *
  186. * @since 1.5.0
  187. */
  188. protected function output_about() {
  189. $this->output_about_info();
  190. $this->output_about_addons();
  191. }
  192. /**
  193. * Display the General Info section of About tab.
  194. *
  195. * @since 1.5.8
  196. */
  197. protected function output_about_info() {
  198. ?>
  199. <div class="wpforms-admin-about-section wpforms-admin-columns">
  200. <div class="wpforms-admin-column-60">
  201. <h3>
  202. <?php esc_html_e( 'Hello and welcome to WPForms, the most beginner friendly drag & drop WordPress forms plugin. At WPForms, we build software that helps you create beautiful responsive online forms for your website in minutes.', 'wpforms-lite' ); ?>
  203. </h3>
  204. <p>
  205. <?php esc_html_e( 'Over the years, we found that most WordPress contact form plugins were bloated, buggy, slow, and very hard to use. So we started with a simple goal: build a WordPress forms plugin that’s both easy and powerful.', 'wpforms-lite' ); ?>
  206. </p>
  207. <p>
  208. <?php esc_html_e( 'Our goal is to take the pain out of creating online forms and make it easy.', 'wpforms-lite' ); ?>
  209. </p>
  210. <p>
  211. <?php
  212. printf(
  213. wp_kses(
  214. /* translators: %1$s - WPBeginner URL; %2$s - OptinMonster URL; %3$s - MonsterInsights URL. */
  215. __( 'WPForms is brought to you by the same team that’s behind the largest WordPress resource site, <a href="%1$s" target="_blank" rel="noopener noreferrer">WPBeginner</a>, the most popular lead-generation software, <a href="%2$s" target="_blank" rel="noopener noreferrer">OptinMonster</a>, the best WordPress analytics plugin, <a href="%3$s" target="_blank" rel="noopener noreferrer">MonsterInsights</a>, and more!', 'wpforms-lite' ),
  216. [
  217. 'a' => [
  218. 'href' => [],
  219. 'rel' => [],
  220. 'target' => [],
  221. ],
  222. ]
  223. ),
  224. 'https://www.wpbeginner.com/?utm_source=wpformsplugin&utm_medium=pluginaboutpage&utm_campaign=aboutwpforms',
  225. 'https://optinmonster.com/?utm_source=wpformsplugin&utm_medium=pluginaboutpage&utm_campaign=aboutwpforms',
  226. 'https://www.monsterinsights.com/?utm_source=wpformsplugin&utm_medium=pluginaboutpage&utm_campaign=aboutwpforms'
  227. );
  228. ?>
  229. </p>
  230. <p>
  231. <?php esc_html_e( 'Yup, we know a thing or two about building awesome products that customers love.', 'wpforms-lite' ); ?>
  232. </p>
  233. </div>
  234. <div class="wpforms-admin-column-40 wpforms-admin-column-last">
  235. <figure>
  236. <img src="<?php echo WPFORMS_PLUGIN_URL; ?>assets/images/about/team.jpg" alt="<?php esc_attr_e( 'The WPForms Team photo', 'wpforms-lite' ); ?>">
  237. <figcaption>
  238. <?php esc_html_e( 'The WPForms Team', 'wpforms-lite' ); ?><br>
  239. </figcaption>
  240. </figure>
  241. </div>
  242. </div>
  243. <?php
  244. }
  245. /**
  246. * Display the Addons section of About tab.
  247. *
  248. * @since 1.5.8
  249. */
  250. protected function output_about_addons() {
  251. if ( ! wpforms_current_user_can() ) {
  252. return;
  253. }
  254. $all_plugins = get_plugins();
  255. $am_plugins = $this->get_am_plugins();
  256. $can_install_plugins = wpforms_can_install( 'plugin' );
  257. $can_activate_plugins = wpforms_can_activate( 'plugin' );
  258. ?>
  259. <div id="wpforms-admin-addons">
  260. <div class="addons-container">
  261. <?php
  262. foreach ( $am_plugins as $plugin => $details ) :
  263. $plugin_data = $this->get_plugin_data( $plugin, $details, $all_plugins );
  264. $plugin_ready_to_activate = $can_activate_plugins
  265. && isset( $plugin_data['status_class'] )
  266. && $plugin_data['status_class'] === 'status-installed';
  267. $plugin_not_activated = ! isset( $plugin_data['status_class'] )
  268. || $plugin_data['status_class'] !== 'status-active';
  269. ?>
  270. <div class="addon-container">
  271. <div class="addon-item">
  272. <div class="details wpforms-clear">
  273. <img src="<?php echo esc_url( $plugin_data['details']['icon'] ); ?>" alt="<?php echo esc_attr( $plugin_data['details']['name'] ); ?>">
  274. <h5 class="addon-name">
  275. <?php echo esc_html( $plugin_data['details']['name'] ); ?>
  276. </h5>
  277. <p class="addon-desc">
  278. <?php echo wp_kses_post( $plugin_data['details']['desc'] ); ?>
  279. </p>
  280. </div>
  281. <div class="actions wpforms-clear">
  282. <div class="status">
  283. <strong>
  284. <?php
  285. printf(
  286. /* translators: %s - addon status label. */
  287. esc_html__( 'Status: %s', 'wpforms-lite' ),
  288. '<span class="status-label ' . esc_attr( $plugin_data['status_class'] ) . '">' . wp_kses_post( $plugin_data['status_text'] ) . '</span>'
  289. );
  290. ?>
  291. </strong>
  292. </div>
  293. <div class="action-button">
  294. <?php if ( $can_install_plugins || $plugin_ready_to_activate || ! $details['wporg'] ) { ?>
  295. <button class="<?php echo esc_attr( $plugin_data['action_class'] ); ?>" data-plugin="<?php echo esc_attr( $plugin_data['plugin_src'] ); ?>" data-type="plugin">
  296. <?php echo wp_kses_post( $plugin_data['action_text'] ); ?>
  297. </button>
  298. <?php } elseif ( $plugin_not_activated ) { ?>
  299. <a href="<?php echo esc_url( $details['wporg'] ); ?>" target="_blank" rel="noopener noreferrer">
  300. <?php esc_html_e( 'WordPress.org', 'wpforms-lite' ); ?>
  301. <span aria-hidden="true" class="dashicons dashicons-external"></span>
  302. </a>
  303. <?php } ?>
  304. </div>
  305. </div>
  306. </div>
  307. </div>
  308. <?php endforeach; ?>
  309. </div>
  310. </div>
  311. <?php
  312. }
  313. /**
  314. * Get AM plugin data to display in the Addons section of About tab.
  315. *
  316. * @since 1.5.8
  317. *
  318. * @param string $plugin Plugin slug.
  319. * @param array $details Plugin details.
  320. * @param array $all_plugins List of all plugins.
  321. *
  322. * @return array
  323. */
  324. protected function get_plugin_data( $plugin, $details, $all_plugins ) {
  325. $have_pro = ( ! empty( $details['pro'] ) && ! empty( $details['pro']['plug'] ) );
  326. $show_pro = false;
  327. $plugin_data = array();
  328. if ( $have_pro ) {
  329. if ( array_key_exists( $plugin, $all_plugins ) ) {
  330. if ( is_plugin_active( $plugin ) ) {
  331. $show_pro = true;
  332. }
  333. }
  334. if ( array_key_exists( $details['pro']['plug'], $all_plugins ) ) {
  335. $show_pro = true;
  336. }
  337. if ( $show_pro ) {
  338. $plugin = $details['pro']['plug'];
  339. $details = $details['pro'];
  340. }
  341. }
  342. if ( array_key_exists( $plugin, $all_plugins ) ) {
  343. if ( is_plugin_active( $plugin ) ) {
  344. // Status text/status.
  345. $plugin_data['status_class'] = 'status-active';
  346. $plugin_data['status_text'] = esc_html__( 'Active', 'wpforms-lite' );
  347. // Button text/status.
  348. $plugin_data['action_class'] = $plugin_data['status_class'] . ' button button-secondary disabled';
  349. $plugin_data['action_text'] = esc_html__( 'Activated', 'wpforms-lite' );
  350. $plugin_data['plugin_src'] = esc_attr( $plugin );
  351. } else {
  352. // Status text/status.
  353. $plugin_data['status_class'] = 'status-installed';
  354. $plugin_data['status_text'] = esc_html__( 'Inactive', 'wpforms-lite' );
  355. // Button text/status.
  356. $plugin_data['action_class'] = $plugin_data['status_class'] . ' button button-secondary';
  357. $plugin_data['action_text'] = esc_html__( 'Activate', 'wpforms-lite' );
  358. $plugin_data['plugin_src'] = esc_attr( $plugin );
  359. }
  360. } else {
  361. // Doesn't exist, install.
  362. // Status text/status.
  363. $plugin_data['status_class'] = 'status-missing';
  364. if ( isset( $details['act'] ) && 'go-to-url' === $details['act'] ) {
  365. $plugin_data['status_class'] = 'status-go-to-url';
  366. }
  367. $plugin_data['status_text'] = esc_html__( 'Not Installed', 'wpforms-lite' );
  368. // Button text/status.
  369. $plugin_data['action_class'] = $plugin_data['status_class'] . ' button button-primary';
  370. $plugin_data['action_text'] = esc_html__( 'Install Plugin', 'wpforms-lite' );
  371. $plugin_data['plugin_src'] = esc_url( $details['url'] );
  372. }
  373. $plugin_data['details'] = $details;
  374. return $plugin_data;
  375. }
  376. /**
  377. * Display the Getting Started tab content.
  378. *
  379. * @since 1.5.0
  380. */
  381. protected function output_getting_started() {
  382. $license = $this->get_license_type();
  383. $utm_campaign = $license === 'lite' ? 'liteplugin' : 'plugin';
  384. $links = [
  385. 'add-new' => "https://wpforms.com/docs/creating-first-form/?utm_source=WordPress&utm_medium=wpforms-about-page&utm_campaign={$utm_campaign}&utm_content=How to Add a New Form#add-new",
  386. 'customize-fields' => "https://wpforms.com/docs/creating-first-form/?utm_source=WordPress&utm_medium=wpforms-about-page&utm_campaign={$utm_campaign}&utm_content=How to Customize Form Fields#customize-fields",
  387. 'display-form' => "https://wpforms.com/docs/creating-first-form/?utm_source=WordPress&utm_medium=wpforms-about-page&utm_campaign={$utm_campaign}&utm_content=How to Display Forms on Your Site#display-form",
  388. 'right-form-field' => "https://wpforms.com/docs/how-to-choose-the-right-form-field-for-your-forms/?utm_source=WordPress&utm_medium=wpforms-about-page&utm_campaign={$utm_campaign}&utm_content=How to Choose the Right Form Field",
  389. 'complete-guide' => "https://wpforms.com/docs/a-complete-guide-to-wpforms-settings/?utm_source=WordPress&utm_medium=wpforms-about-page&utm_campaign={$utm_campaign}&utm_content=A Complete Guide to WPForms Settings",
  390. 'gdpr-compliant' => "https://wpforms.com/docs/how-to-create-gdpr-compliant-forms/?utm_source=WordPress&utm_medium=wpforms-about-page&utm_campaign={$utm_campaign}&utm_content=How to Create GDPR Complaint Forms",
  391. 'install-activate-addons' => "https://wpforms.com/docs/install-activate-wpforms-addons/?utm_source=WordPress&utm_medium=wpforms-about-page&utm_campaign={$utm_campaign}&utm_content=How to Install and Activate WPForms Addons",
  392. ];
  393. ?>
  394. <div class="wpforms-admin-about-section wpforms-admin-about-section-first-form" style="display:flex;">
  395. <div class="wpforms-admin-about-section-first-form-text">
  396. <h2>
  397. <?php esc_html_e( 'Creating Your First Form', 'wpforms-lite' ); ?>
  398. </h2>
  399. <p>
  400. <?php esc_html_e( 'Want to get started creating your first form with WPForms? By following the step by step instructions in this walkthrough, you can easily publish your first form on your site.', 'wpforms-lite' ); ?>
  401. </p>
  402. <p>
  403. <?php esc_html_e( 'To begin, you’ll need to be logged into the WordPress admin area. Once there, click on WPForms in the admin sidebar to go the Forms Overview page.', 'wpforms-lite' ); ?>
  404. </p>
  405. <p>
  406. <?php esc_html_e( 'In the Forms Overview page, the forms list will be empty because there are no forms yet. To create a new form, click on the Add New button, and this will launch the WPForms Form Builder.', 'wpforms-lite' ); ?>
  407. </p>
  408. <ul class="list-plain">
  409. <li>
  410. <a href="<?php echo esc_url( $links['add-new'] ); ?>" target="_blank" rel="noopener noreferrer">
  411. <?php esc_html_e( 'How to Add a New Form', 'wpforms-lite' ); ?>
  412. </a>
  413. </li>
  414. <li>
  415. <a href="<?php echo esc_url( $links['customize-fields'] ); ?>" target="_blank" rel="noopener noreferrer">
  416. <?php esc_html_e( 'How to Customize Form Fields', 'wpforms-lite' ); ?>
  417. </a>
  418. </li>
  419. <li>
  420. <a href="<?php echo esc_url( $links['display-form'] ); ?>" target="_blank" rel="noopener noreferrer">
  421. <?php esc_html_e( 'How to Display Forms on Your Site', 'wpforms-lite' ); ?>
  422. </a>
  423. </li>
  424. </ul>
  425. </div>
  426. <div class="wpforms-admin-about-section-first-form-video">
  427. <iframe src="https://www.youtube-nocookie.com/embed/o2nE1P74WxQ?rel=0" width="540" height="304" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen></iframe>
  428. </div>
  429. </div>
  430. <?php if ( ! in_array( $license, self::$licenses_top, true ) ) { ?>
  431. <div class="wpforms-admin-about-section wpforms-admin-about-section-hero">
  432. <div class="wpforms-admin-about-section-hero-main">
  433. <h2>
  434. <?php esc_html_e( 'Get WPForms Pro and Unlock all the Powerful Features', 'wpforms-lite' ); ?>
  435. </h2>
  436. <p class="bigger">
  437. <?php
  438. echo wp_kses(
  439. __( 'Thanks for being a loyal WPForms Lite user. <strong>Upgrade to WPForms Pro</strong> to unlock all the awesome features and experience<br>why WPForms is consistently rated the best WordPress form builder.', 'wpforms-lite' ),
  440. [
  441. 'br' => [],
  442. 'strong' => [],
  443. ]
  444. );
  445. ?>
  446. </p>
  447. <p>
  448. <?php
  449. printf(
  450. wp_kses( /* translators: %s - stars. */
  451. __( 'We know that you will truly love WPForms. It has over <strong>10,000+ five star ratings</strong> (%s) and is active on over 5 million websites.', 'wpforms-lite' ),
  452. [
  453. 'strong' => [],
  454. ]
  455. ),
  456. '<i class="fa fa-star" aria-hidden="true"></i>' .
  457. '<i class="fa fa-star" aria-hidden="true"></i>' .
  458. '<i class="fa fa-star" aria-hidden="true"></i>' .
  459. '<i class="fa fa-star" aria-hidden="true"></i>' .
  460. '<i class="fa fa-star" aria-hidden="true"></i>'
  461. );
  462. ?>
  463. </p>
  464. </div>
  465. <div class="wpforms-admin-about-section-hero-extra">
  466. <div class="wpforms-admin-columns">
  467. <div class="wpforms-admin-column-50">
  468. <ul class="list-features list-plain">
  469. <li>
  470. <i class="fa fa-check" aria-hidden="true"></i>
  471. <?php esc_html_e( '300+ customizable form templates', 'wpforms-lite' ); ?>
  472. </li>
  473. <li>
  474. <i class="fa fa-check" aria-hidden="true"></i>
  475. <?php esc_html_e( 'Store and manage form entries in WordPress', 'wpforms-lite' ); ?>
  476. </li>
  477. <li>
  478. <i class="fa fa-check" aria-hidden="true"></i>
  479. <?php esc_html_e( 'Unlock all fields & features, including Rich Text & conditional logic', 'wpforms-lite' ); ?>
  480. </li>
  481. <li>
  482. <i class="fa fa-check" aria-hidden="true"></i>
  483. <?php esc_html_e( 'Make Surveys and Polls and create reports', 'wpforms-lite' ); ?>
  484. </li>
  485. <li>
  486. <i class="fa fa-check" aria-hidden="true"></i>
  487. <?php esc_html_e( 'Accept user-submitted content with the Post Submissions addon', 'wpforms-lite' ); ?>
  488. </li>
  489. </ul>
  490. </div>
  491. <div class="wpforms-admin-column-50 wpforms-admin-column-last">
  492. <ul class="list-features list-plain">
  493. <li>
  494. <i class="fa fa-check" aria-hidden="true"></i>
  495. <?php esc_html_e( '500+ integrations with marketing and payment services', 'wpforms-lite' ); ?>
  496. </li>
  497. <li>
  498. <i class="fa fa-check" aria-hidden="true"></i>
  499. <?php esc_html_e( 'Let users Save and Resume submissions to prevent abandonment', 'wpforms-lite' ); ?>
  500. </li>
  501. <li>
  502. <i class="fa fa-check" aria-hidden="true"></i>
  503. <?php esc_html_e( 'Take payments with Stripe, Square, Authorize.Net, and PayPal', 'wpforms-lite' ); ?>
  504. </li>
  505. <li>
  506. <i class="fa fa-check" aria-hidden="true"></i>
  507. <?php esc_html_e( 'Collect signatures, geolocation data, and file uploads', 'wpforms-lite' ); ?>
  508. </li>
  509. <li>
  510. <i class="fa fa-check" aria-hidden="true"></i>
  511. <?php esc_html_e( 'Create user registration and login forms', 'wpforms-lite' ); ?>
  512. </li>
  513. </ul>
  514. </div>
  515. </div>
  516. <hr />
  517. <h3 class="call-to-action">
  518. <?php
  519. printf(
  520. '<a href="%s" target="_blank" rel="noopener noreferrer">',
  521. esc_url( wpforms_admin_upgrade_link( 'wpforms-about-page', 'Get WPForms Pro Today' ) )
  522. );
  523. esc_html_e( 'Get WPForms Pro Today and Unlock all the Powerful Features', 'wpforms-lite' );
  524. ?>
  525. </a>
  526. </h3>
  527. <?php if ( $license === 'lite' ) { ?>
  528. <p>
  529. <?php
  530. echo wp_kses(
  531. __( 'Bonus: WPForms Lite users get <span class="price-20-off">50% off regular price</span>, automatically applied at checkout.', 'wpforms-lite' ),
  532. [
  533. 'span' => [
  534. 'class' => [],
  535. ],
  536. ]
  537. );
  538. ?>
  539. </p>
  540. <?php } ?>
  541. </div>
  542. </div>
  543. <?php } ?>
  544. <div class="wpforms-admin-about-section wpforms-admin-about-section-squashed wpforms-admin-about-section-post wpforms-admin-columns">
  545. <div class="wpforms-admin-column-20">
  546. <img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/about/how-choose-right-form-field.png' ); ?>" alt="">
  547. </div>
  548. <div class="wpforms-admin-column-80">
  549. <h2>
  550. <?php esc_html_e( 'How to Choose the Right Form Field', 'wpforms-lite' ); ?>
  551. </h2>
  552. <p>
  553. <?php esc_html_e( 'Are you wondering which form fields you have access to in WPForms and what each field does? WPForms has lots of field types to make creating and filling out forms easy. In this tutorial, we’ll cover all of the fields available in WPForms.', 'wpforms-lite' ); ?>
  554. </p>
  555. <a href="<?php echo esc_url( $links['right-form-field'] ); ?>" target="_blank" rel="noopener noreferrer" class="wpforms-admin-about-section-post-link">
  556. <?php esc_html_e( 'Read Documentation', 'wpforms-lite' ); ?><i class="fa fa-external-link" aria-hidden="true"></i>
  557. </a>
  558. </div>
  559. </div>
  560. <div class="wpforms-admin-about-section wpforms-admin-about-section-squashed wpforms-admin-about-section-post wpforms-admin-columns">
  561. <div class="wpforms-admin-column-20">
  562. <img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/about/complete-guide-to-wpforms-settings.png' ); ?>" alt="">
  563. </div>
  564. <div class="wpforms-admin-column-80">
  565. <h2>
  566. <?php esc_html_e( 'A Complete Guide to WPForms Settings', 'wpforms-lite' ); ?>
  567. </h2>
  568. <p>
  569. <?php esc_html_e( 'Would you like to learn more about all of the settings available in WPForms? In addition to tons of customization options within the form builder, WPForms has an extensive list of plugin-wide options available. This includes choosing your currency, adding GDPR enhancements, setting up integrations.', 'wpforms-lite' ); ?>
  570. </p>
  571. <a href="<?php echo esc_url( $links['complete-guide'] ); ?>" target="_blank" rel="noopener noreferrer" class="wpforms-admin-about-section-post-link">
  572. <?php esc_html_e( 'Read Documentation', 'wpforms-lite' ); ?><i class="fa fa-external-link" aria-hidden="true"></i>
  573. </a>
  574. </div>
  575. </div>
  576. <div class="wpforms-admin-about-section wpforms-admin-about-section-squashed wpforms-admin-about-section-post wpforms-admin-columns">
  577. <div class="wpforms-admin-column-20">
  578. <img src="<?php echo WPFORMS_PLUGIN_URL; ?>assets/images/about/how-create-gdpr-compliant-forms.png" alt="">
  579. </div>
  580. <div class="wpforms-admin-column-80">
  581. <h2>
  582. <?php esc_html_e( 'How to Create GDPR Compliant Forms', 'wpforms-lite' ); ?>
  583. </h2>
  584. <p>
  585. <?php esc_html_e( 'Do you need to check that your forms are compliant with the European Union’s General Data Protection Regulation? The best way to ensure GDPR compliance for your specific site is always to consult legal counsel. In this guide, we’ll discuss general considerations for GDPR compliance in your WordPress forms.', 'wpforms-lite' ); ?>
  586. </p>
  587. <a href="<?php echo esc_url( $links['gdpr-compliant'] ); ?>" target="_blank" rel="noopener noreferrer" class="wpforms-admin-about-section-post-link">
  588. <?php esc_html_e( 'Read Documentation', 'wpforms-lite' ); ?><i class="fa fa-external-link" aria-hidden="true"></i>
  589. </a>
  590. </div>
  591. </div>
  592. <div class="wpforms-admin-about-section wpforms-admin-about-section-squashed wpforms-admin-about-section-post wpforms-admin-columns">
  593. <div class="wpforms-admin-column-20">
  594. <img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/about/how-install-activate-wpforms-addons.png' ); ?>" alt="">
  595. </div>
  596. <div class="wpforms-admin-column-80">
  597. <h2>
  598. <?php esc_html_e( 'How to Install and Activate WPForms Addons', 'wpforms-lite' ); ?>
  599. </h2>
  600. <p>
  601. <?php esc_html_e( 'Would you like to access WPForms addons to extend the functionality of your forms? The first thing you need to do is install WPForms. Once that’s done, let’s go ahead and look at the process of activating addons.', 'wpforms-lite' ); ?>
  602. </p>
  603. <a href="<?php echo esc_url( $links['install-activate-addons'] ); ?>" target="_blank" rel="noopener noreferrer" class="wpforms-admin-about-section-post-link">
  604. <?php esc_html_e( 'Read Documentation', 'wpforms-lite' ); ?><i class="fa fa-external-link" aria-hidden="true"></i>
  605. </a>
  606. </div>
  607. </div>
  608. <?php
  609. }
  610. /**
  611. * Get the next license type. Helper for Versus tab content.
  612. *
  613. * @since 1.5.5
  614. *
  615. * @param string $current Current license type slug.
  616. *
  617. * @return string Next license type slug.
  618. */
  619. protected function get_next_license( $current ) {
  620. $current = ucfirst( $current );
  621. $license_pairs = array(
  622. 'Lite' => 'Pro',
  623. 'Basic' => 'Pro',
  624. 'Plus' => 'Pro',
  625. 'Pro' => 'Elite',
  626. );
  627. return ! empty( $license_pairs[ $current ] ) ? $license_pairs[ $current ] : 'Elite';
  628. }
  629. /**
  630. * Display the Versus tab content.
  631. *
  632. * @since 1.5.0
  633. */
  634. protected function output_versus() {
  635. $license = $this->get_license_type();
  636. $next_license = $this->get_next_license( $license );
  637. ?>
  638. <div class="wpforms-admin-about-section wpforms-admin-about-section-squashed">
  639. <h1 class="centered">
  640. <strong><?php echo esc_html( ucfirst( $license ) ); ?></strong> vs <strong><?php echo esc_html( $next_license ); ?></strong>
  641. </h1>
  642. <p class="centered">
  643. <?php esc_html_e( 'Get the most out of WPForms by upgrading to Pro and unlocking all of the powerful features.', 'wpforms-lite' ); ?>
  644. </p>
  645. </div>
  646. <div class="wpforms-admin-about-section wpforms-admin-about-section-squashed wpforms-admin-about-section-hero wpforms-admin-about-section-table">
  647. <div class="wpforms-admin-about-section-hero-main wpforms-admin-columns">
  648. <div class="wpforms-admin-column-33">
  649. <h3 class="no-margin">
  650. <?php esc_html_e( 'Feature', 'wpforms-lite' ); ?>
  651. </h3>
  652. </div>
  653. <div class="wpforms-admin-column-33">
  654. <h3 class="no-margin">
  655. <?php echo esc_html( ucfirst( $license ) ); ?>
  656. </h3>
  657. </div>
  658. <div class="wpforms-admin-column-33">
  659. <h3 class="no-margin">
  660. <?php echo esc_html( $next_license ); ?>
  661. </h3>
  662. </div>
  663. </div>
  664. <div class="wpforms-admin-about-section-hero-extra no-padding wpforms-admin-columns">
  665. <table>
  666. <?php
  667. foreach ( self::$licenses_features as $slug => $name ) {
  668. $current = $this->get_license_data( $slug, $license );
  669. $next = $this->get_license_data( $slug, strtolower( $next_license ) );
  670. if ( empty( $current ) || empty( $next ) ) {
  671. continue;
  672. }
  673. $current_status = $current['status'];
  674. if ( $current['text'] !== $next['text'] && $current_status === 'full' ) {
  675. $current_status = 'partial';
  676. }
  677. ?>
  678. <tr class="wpforms-admin-columns">
  679. <td class="wpforms-admin-column-33">
  680. <p><?php echo esc_html( $name ); ?></p>
  681. </td>
  682. <td class="wpforms-admin-column-33">
  683. <?php if ( is_array( $current ) ) : ?>
  684. <p class="features-<?php echo esc_attr( $current_status ); ?>">
  685. <?php echo wp_kses_post( implode( '<br>', $current['text'] ) ); ?>
  686. </p>
  687. <?php endif; ?>
  688. </td>
  689. <td class="wpforms-admin-column-33">
  690. <?php if ( is_array( $current ) ) : ?>
  691. <p class="features-full">
  692. <?php echo wp_kses_post( implode( '<br>', $next['text'] ) ); ?>
  693. </p>
  694. <?php endif; ?>
  695. </td>
  696. </tr>
  697. <?php
  698. }
  699. ?>
  700. </table>
  701. </div>
  702. </div>
  703. <div class="wpforms-admin-about-section wpforms-admin-about-section-hero">
  704. <div class="wpforms-admin-about-section-hero-main no-border">
  705. <h3 class="call-to-action centered">
  706. <?php
  707. printf(
  708. '<a href="%s" target="_blank" rel="noopener noreferrer">',
  709. esc_url( wpforms_admin_upgrade_link( 'wpforms-about-page', 'Get WPForms Pro Today' ) )
  710. );
  711. printf( /* translators: %s - next license level. */
  712. esc_html__( 'Get WPForms %s Today and Unlock all the Powerful Features', 'wpforms-lite' ),
  713. esc_html( $next_license )
  714. );
  715. ?>
  716. </a>
  717. </h3>
  718. <?php if ( $license === 'lite' ) { ?>
  719. <p class="centered">
  720. <?php
  721. echo wp_kses(
  722. __( 'Bonus: WPForms Lite users get <span class="price-20-off">50% off regular price</span>, automatically applied at checkout.', 'wpforms-lite' ),
  723. [
  724. 'span' => [
  725. 'class' => [],
  726. ],
  727. ]
  728. );
  729. ?>
  730. </p>
  731. <?php } ?>
  732. </div>
  733. </div>
  734. <?php
  735. }
  736. /**
  737. * List of AM plugins that we propose to install.
  738. *
  739. * @since 1.5.0
  740. *
  741. * @return array
  742. */
  743. protected function get_am_plugins() {
  744. $images_url = WPFORMS_PLUGIN_URL . 'assets/images/about/';
  745. return [
  746. 'optinmonster/optin-monster-wp-api.php' => [
  747. 'icon' => $images_url . 'plugin-om.png',
  748. 'name' => esc_html__( 'OptinMonster', 'wpforms-lite' ),
  749. 'desc' => esc_html__( 'Instantly get more subscribers, leads, and sales with the #1 conversion optimization toolkit. Create high converting popups, announcement bars, spin a wheel, and more with smart targeting and personalization.', 'wpforms-lite' ),
  750. 'wporg' => 'https://wordpress.org/plugins/optinmonster/',
  751. 'url' => 'https://downloads.wordpress.org/plugin/optinmonster.zip',
  752. ],
  753. 'google-analytics-for-wordpress/googleanalytics.php' => [
  754. 'icon' => $images_url . 'plugin-mi.png',
  755. 'name' => esc_html__( 'MonsterInsights', 'wpforms-lite' ),
  756. 'desc' => esc_html__( 'The leading WordPress analytics plugin that shows you how people find and use your website, so you can make data driven decisions to grow your business. Properly set up Google Analytics without writing code.', 'wpforms-lite' ),
  757. 'wporg' => 'https://wordpress.org/plugins/google-analytics-for-wordpress/',
  758. 'url' => 'https://downloads.wordpress.org/plugin/google-analytics-for-wordpress.zip',
  759. 'pro' => [
  760. 'plug' => 'google-analytics-premium/googleanalytics-premium.php',
  761. 'icon' => $images_url . 'plugin-mi.png',
  762. 'name' => esc_html__( 'MonsterInsights Pro', 'wpforms-lite' ),
  763. 'desc' => esc_html__( 'The leading WordPress analytics plugin that shows you how people find and use your website, so you can make data driven decisions to grow your business. Properly set up Google Analytics without writing code.', 'wpforms-lite' ),
  764. 'url' => 'https://www.monsterinsights.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  765. 'act' => 'go-to-url',
  766. ],
  767. ],
  768. 'wp-mail-smtp/wp_mail_smtp.php' => [
  769. 'icon' => $images_url . 'plugin-smtp.png',
  770. 'name' => esc_html__( 'WP Mail SMTP', 'wpforms-lite' ),
  771. 'desc' => esc_html__( "Improve your WordPress email deliverability and make sure that your website emails reach user's inbox with the #1 SMTP plugin for WordPress. Over 2 million websites use it to fix WordPress email issues.", 'wpforms-lite' ),
  772. 'wporg' => 'https://wordpress.org/plugins/wp-mail-smtp/',
  773. 'url' => 'https://downloads.wordpress.org/plugin/wp-mail-smtp.zip',
  774. 'pro' => [
  775. 'plug' => 'wp-mail-smtp-pro/wp_mail_smtp.php',
  776. 'icon' => $images_url . 'plugin-smtp.png',
  777. 'name' => esc_html__( 'WP Mail SMTP Pro', 'wpforms-lite' ),
  778. 'desc' => esc_html__( "Improve your WordPress email deliverability and make sure that your website emails reach user's inbox with the #1 SMTP plugin for WordPress. Over 2 million websites use it to fix WordPress email issues.", 'wpforms-lite' ),
  779. 'url' => 'https://wpmailsmtp.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  780. 'act' => 'go-to-url',
  781. ],
  782. ],
  783. 'all-in-one-seo-pack/all_in_one_seo_pack.php' => [
  784. 'icon' => $images_url . 'plugin-aioseo.png',
  785. 'name' => esc_html__( 'AIOSEO', 'wpforms-lite' ),
  786. 'desc' => esc_html__( "The original WordPress SEO plugin and toolkit that improves your website's search rankings. Comes with all the SEO features like Local SEO, WooCommerce SEO, sitemaps, SEO optimizer, schema, and more.", 'wpforms-lite' ),
  787. 'wporg' => 'https://wordpress.org/plugins/all-in-one-seo-pack/',
  788. 'url' => 'https://downloads.wordpress.org/plugin/all-in-one-seo-pack.zip',
  789. 'pro' => [
  790. 'plug' => 'all-in-one-seo-pack-pro/all_in_one_seo_pack.php',
  791. 'icon' => $images_url . 'plugin-aioseo.png',
  792. 'name' => esc_html__( 'AIOSEO Pro', 'wpforms-lite' ),
  793. 'desc' => esc_html__( "The original WordPress SEO plugin and toolkit that improves your website's search rankings. Comes with all the SEO features like Local SEO, WooCommerce SEO, sitemaps, SEO optimizer, schema, and more.", 'wpforms-lite' ),
  794. 'url' => 'https://aioseo.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  795. 'act' => 'go-to-url',
  796. ],
  797. ],
  798. 'coming-soon/coming-soon.php' => [
  799. 'icon' => $images_url . 'plugin-seedprod.png',
  800. 'name' => esc_html__( 'SeedProd', 'wpforms-lite' ),
  801. 'desc' => esc_html__( 'The fastest drag & drop landing page builder for WordPress. Create custom landing pages without writing code, connect them with your CRM, collect subscribers, and grow your audience. Trusted by 1 million sites.', 'wpforms-lite' ),
  802. 'wporg' => 'https://wordpress.org/plugins/coming-soon/',
  803. 'url' => 'https://downloads.wordpress.org/plugin/coming-soon.zip',
  804. 'pro' => [
  805. 'plug' => 'seedprod-coming-soon-pro-5/seedprod-coming-soon-pro-5.php',
  806. 'icon' => $images_url . 'plugin-seedprod.png',
  807. 'name' => esc_html__( 'SeedProd Pro', 'wpforms-lite' ),
  808. 'desc' => esc_html__( 'The fastest drag & drop landing page builder for WordPress. Create custom landing pages without writing code, connect them with your CRM, collect subscribers, and grow your audience. Trusted by 1 million sites.', 'wpforms-lite' ),
  809. 'url' => 'https://www.seedprod.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  810. 'act' => 'go-to-url',
  811. ],
  812. ],
  813. 'rafflepress/rafflepress.php' => [
  814. 'icon' => $images_url . 'plugin-rp.png',
  815. 'name' => esc_html__( 'RafflePress', 'wpforms-lite' ),
  816. 'desc' => esc_html__( 'Turn your website visitors into brand ambassadors! Easily grow your email list, website traffic, and social media followers with the most powerful giveaways & contests plugin for WordPress.', 'wpforms-lite' ),
  817. 'wporg' => 'https://wordpress.org/plugins/rafflepress/',
  818. 'url' => 'https://downloads.wordpress.org/plugin/rafflepress.zip',
  819. 'pro' => [
  820. 'plug' => 'rafflepress-pro/rafflepress-pro.php',
  821. 'icon' => $images_url . 'plugin-rp.png',
  822. 'name' => esc_html__( 'RafflePress Pro', 'wpforms-lite' ),
  823. 'desc' => esc_html__( 'Turn your website visitors into brand ambassadors! Easily grow your email list, website traffic, and social media followers with the most powerful giveaways & contests plugin for WordPress.', 'wpforms-lite' ),
  824. 'url' => 'https://rafflepress.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  825. 'act' => 'go-to-url',
  826. ],
  827. ],
  828. 'pushengage/main.php' => [
  829. 'icon' => $images_url . 'plugin-pushengage.png',
  830. 'name' => esc_html__( 'PushEngage', 'wpforms-lite' ),
  831. 'desc' => esc_html__( 'Connect with your visitors after they leave your website with the leading web push notification software. Over 10,000+ businesses worldwide use PushEngage to send 9 billion notifications each month.', 'wpforms-lite' ),
  832. 'wporg' => 'https://wordpress.org/plugins/pushengage/',
  833. 'url' => 'https://downloads.wordpress.org/plugin/pushengage.zip',
  834. ],
  835. 'instagram-feed/instagram-feed.php' => [
  836. 'icon' => $images_url . 'plugin-sb-instagram.png',
  837. 'name' => esc_html__( 'Smash Balloon Instagram Feeds', 'wpforms-lite' ),
  838. 'desc' => esc_html__( 'Easily display Instagram content on your WordPress site without writing any code. Comes with multiple templates, ability to show content from multiple accounts, hashtags, and more. Trusted by 1 million websites.', 'wpforms-lite' ),
  839. 'wporg' => 'https://wordpress.org/plugins/instagram-feed/',
  840. 'url' => 'https://downloads.wordpress.org/plugin/instagram-feed.zip',
  841. 'pro' => [
  842. 'plug' => 'instagram-feed-pro/instagram-feed.php',
  843. 'icon' => $images_url . 'plugin-sb-instagram.png',
  844. 'name' => esc_html__( 'Smash Balloon Instagram Feeds Pro', 'wpforms-lite' ),
  845. 'desc' => esc_html__( 'Easily display Instagram content on your WordPress site without writing any code. Comes with multiple templates, ability to show content from multiple accounts, hashtags, and more. Trusted by 1 million websites.', 'wpforms-lite' ),
  846. 'url' => 'https://smashballoon.com/instagram-feed/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  847. 'act' => 'go-to-url',
  848. ],
  849. ],
  850. 'custom-facebook-feed/custom-facebook-feed.php' => [
  851. 'icon' => $images_url . 'plugin-sb-fb.png',
  852. 'name' => esc_html__( 'Smash Balloon Facebook Feeds', 'wpforms-lite' ),
  853. 'desc' => esc_html__( 'Easily display Facebook content on your WordPress site without writing any code. Comes with multiple templates, ability to embed albums, group content, reviews, live videos, comments, and reactions.', 'wpforms-lite' ),
  854. 'wporg' => 'https://wordpress.org/plugins/custom-facebook-feed/',
  855. 'url' => 'https://downloads.wordpress.org/plugin/custom-facebook-feed.zip',
  856. 'pro' => [
  857. 'plug' => 'custom-facebook-feed-pro/custom-facebook-feed.php',
  858. 'icon' => $images_url . 'plugin-sb-fb.png',
  859. 'name' => esc_html__( 'Smash Balloon Facebook Feeds Pro', 'wpforms-lite' ),
  860. 'desc' => esc_html__( 'Easily display Facebook content on your WordPress site without writing any code. Comes with multiple templates, ability to embed albums, group content, reviews, live videos, comments, and reactions.', 'wpforms-lite' ),
  861. 'url' => 'https://smashballoon.com/custom-facebook-feed/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  862. 'act' => 'go-to-url',
  863. ],
  864. ],
  865. 'feeds-for-youtube/youtube-feed.php' => [
  866. 'icon' => $images_url . 'plugin-sb-youtube.png',
  867. 'name' => esc_html__( 'Smash Balloon YouTube Feeds', 'wpforms-lite' ),
  868. 'desc' => esc_html__( 'Easily display YouTube videos on your WordPress site without writing any code. Comes with multiple layouts, ability to embed live streams, video filtering, ability to combine multiple channel videos, and more.', 'wpforms-lite' ),
  869. 'wporg' => 'https://wordpress.org/plugins/feeds-for-youtube/',
  870. 'url' => 'https://downloads.wordpress.org/plugin/feeds-for-youtube.zip',
  871. 'pro' => [
  872. 'plug' => 'youtube-feed-pro/youtube-feed.php',
  873. 'icon' => $images_url . 'plugin-sb-youtube.png',
  874. 'name' => esc_html__( 'Smash Balloon YouTube Feeds Pro', 'wpforms-lite' ),
  875. 'desc' => esc_html__( 'Easily display YouTube videos on your WordPress site without writing any code. Comes with multiple layouts, ability to embed live streams, video filtering, ability to combine multiple channel videos, and more.', 'wpforms-lite' ),
  876. 'url' => 'https://smashballoon.com/youtube-feed/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  877. 'act' => 'go-to-url',
  878. ],
  879. ],
  880. 'custom-twitter-feeds/custom-twitter-feed.php' => [
  881. 'icon' => $images_url . 'plugin-sb-twitter.png',
  882. 'name' => esc_html__( 'Smash Balloon Twitter Feeds', 'wpforms-lite' ),
  883. 'desc' => esc_html__( 'Easily display Twitter content in WordPress without writing any code. Comes with multiple layouts, ability to combine multiple Twitter feeds, Twitter card support, tweet moderation, and more.', 'wpforms-lite' ),
  884. 'wporg' => 'https://wordpress.org/plugins/custom-twitter-feeds/',
  885. 'url' => 'https://downloads.wordpress.org/plugin/custom-twitter-feeds.zip',
  886. 'pro' => [
  887. 'plug' => 'custom-twitter-feeds-pro/custom-twitter-feed.php',
  888. 'icon' => $images_url . 'plugin-sb-twitter.png',
  889. 'name' => esc_html__( 'Smash Balloon Twitter Feeds Pro', 'wpforms-lite' ),
  890. 'desc' => esc_html__( 'Easily display Twitter content in WordPress without writing any code. Comes with multiple layouts, ability to combine multiple Twitter feeds, Twitter card support, tweet moderation, and more.', 'wpforms-lite' ),
  891. 'url' => 'https://smashballoon.com/custom-twitter-feeds/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  892. 'act' => 'go-to-url',
  893. ],
  894. ],
  895. 'trustpulse-api/trustpulse.php' => [
  896. 'icon' => $images_url . 'plugin-trustpulse.png',
  897. 'name' => esc_html__( 'TrustPulse', 'wpforms-lite' ),
  898. 'desc' => esc_html__( 'Boost your sales and conversions by up to 15% with real-time social proof notifications. TrustPulse helps you show live user activity and purchases to help convince other users to purchase.', 'wpforms-lite' ),
  899. 'wporg' => 'https://wordpress.org/plugins/trustpulse-api/',
  900. 'url' => 'https://downloads.wordpress.org/plugin/trustpulse-api.zip',
  901. ],
  902. 'searchwp/index.php' => [
  903. 'icon' => $images_url . 'plugin-searchwp.png',
  904. 'name' => esc_html__( 'SearchWP', 'wpforms-lite' ),
  905. 'desc' => esc_html__( 'The most advanced WordPress search plugin. Customize your WordPress search algorithm, reorder search results, track search metrics, and everything you need to leverage search to grow your business.', 'wpforms-lite' ),
  906. 'wporg' => false,
  907. 'url' => 'https://searchwp.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  908. 'act' => 'go-to-url',
  909. ],
  910. 'affiliate-wp/affiliate-wp.php' => [
  911. 'icon' => $images_url . 'plugin-affwp.png',
  912. 'name' => esc_html__( 'AffiliateWP', 'wpforms-lite' ),
  913. 'desc' => esc_html__( 'The #1 affiliate management plugin for WordPress. Easily create an affiliate program for your eCommerce store or membership site within minutes and start growing your sales with the power of referral marketing.', 'wpforms-lite' ),
  914. 'wporg' => false,
  915. 'url' => 'https://affiliatewp.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  916. 'act' => 'go-to-url',
  917. ],
  918. 'stripe/stripe-checkout.php' => [
  919. 'icon' => $images_url . 'plugin-wp-simple-pay.png',
  920. 'name' => esc_html__( 'WP Simple Pay', 'wpforms-lite' ),
  921. 'desc' => esc_html__( 'The #1 Stripe payments plugin for WordPress. Start accepting one-time and recurring payments on your WordPress site without setting up a shopping cart. No code required.', 'wpforms-lite' ),
  922. 'wporg' => 'https://wordpress.org/plugins/stripe/',
  923. 'url' => 'https://downloads.wordpress.org/plugin/stripe.zip',
  924. 'pro' => [
  925. 'plug' => 'wp-simple-pay-pro-3/simple-pay.php',
  926. 'icon' => $images_url . 'plugin-wp-simple-pay.png',
  927. 'name' => esc_html__( 'WP Simple Pay Pro', 'wpforms-lite' ),
  928. 'desc' => esc_html__( 'The #1 Stripe payments plugin for WordPress. Start accepting one-time and recurring payments on your WordPress site without setting up a shopping cart. No code required.', 'wpforms-lite' ),
  929. 'url' => 'https://wpsimplepay.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  930. 'act' => 'go-to-url',
  931. ],
  932. ],
  933. 'easy-digital-downloads/easy-digital-downloads.php' => [
  934. 'icon' => $images_url . 'plugin-edd.png',
  935. 'name' => esc_html__( 'Easy Digital Downloads', 'wpforms-lite' ),
  936. 'desc' => esc_html__( 'The best WordPress eCommerce plugin for selling digital downloads. Start selling eBooks, software, music, digital art, and more within minutes. Accept payments, manage subscriptions, advanced access control, and more.', 'wpforms-lite' ),
  937. 'wporg' => 'https://wordpress.org/plugins/easy-digital-downloads/',
  938. 'url' => 'https://downloads.wordpress.org/plugin/easy-digital-downloads.zip',
  939. ],
  940. 'sugar-calendar-lite/sugar-calendar-lite.php' => [
  941. 'icon' => $images_url . 'plugin-sugarcalendar.png',
  942. 'name' => esc_html__( 'Sugar Calendar', 'wpforms-lite' ),
  943. 'desc' => esc_html__( 'A simple & powerful event calendar plugin for WordPress that comes with all the event management features including payments, scheduling, timezones, ticketing, recurring events, and more.', 'wpforms-lite' ),
  944. 'wporg' => 'https://wordpress.org/plugins/sugar-calendar-lite/',
  945. 'url' => 'https://downloads.wordpress.org/plugin/sugar-calendar-lite.zip',
  946. 'pro' => [
  947. 'plug' => 'sugar-calendar/sugar-calendar.php',
  948. 'icon' => $images_url . 'plugin-sugarcalendar.png',
  949. 'name' => esc_html__( 'Sugar Calendar Pro', 'wpforms-lite' ),
  950. 'desc' => esc_html__( 'A simple & powerful event calendar plugin for WordPress that comes with all the event management features including payments, scheduling, timezones, ticketing, recurring events, and more.', 'wpforms-lite' ),
  951. 'url' => 'https://sugarcalendar.com/?utm_source=wpformsplugin&utm_medium=link&utm_campaign=About%20WPForms',
  952. 'act' => 'go-to-url',
  953. ],
  954. ],
  955. ];
  956. }
  957. /**
  958. * Get the array of data that compared the license data.
  959. *
  960. * @since 1.5.0
  961. *
  962. * @param string $feature Feature name.
  963. * @param string $license License type to get data for.
  964. *
  965. * @return array|false
  966. */
  967. protected function get_license_data( $feature, $license ) {
  968. $data = [
  969. 'entries' => [
  970. 'lite' => [
  971. 'status' => 'partial',
  972. 'text' => [
  973. '<strong>' . esc_html__( 'Entries via Email Only', 'wpforms-lite' ) . '</strong>',
  974. ],
  975. ],
  976. 'basic' => [
  977. 'status' => 'full',
  978. 'text' => [
  979. '<strong>' . esc_html__( 'Complete Entry Management inside WordPress', 'wpforms-lite' ) . '</strong>',
  980. ],
  981. ],
  982. 'plus' => [
  983. 'status' => 'full',
  984. 'text' => [
  985. '<strong>' . esc_html__( 'Complete Entry Management inside WordPress', 'wpforms-lite' ) . '</strong>',
  986. ],
  987. ],
  988. 'pro' => [
  989. 'status' => 'full',
  990. 'text' => [
  991. '<strong>' . esc_html__( 'Complete Entry Management inside WordPress', 'wpforms-lite' ) . '</strong>',
  992. ],
  993. ],
  994. ],
  995. 'fields' => [
  996. 'lite' => [
  997. 'status' => 'partial',
  998. 'text' => [
  999. '<strong>' . esc_html__( 'Standard Fields Only', 'wpforms-lite' ) . '</strong>',
  1000. esc_html__( 'Name, Email, Single Line Text, Paragraph Text, Dropdown, Multiple Choice, Checkboxes, Numbers, and Number Slider', 'wpforms-lite' ),
  1001. ],
  1002. ],
  1003. 'basic' => [
  1004. 'status' => 'full',
  1005. 'text' => [
  1006. '<strong>' . esc_html__( 'Access to all Standard and Fancy Fields', 'wpforms-lite' ) . '</strong>',
  1007. esc_html__( 'Address, Phone, Website / URL, Date / Time, Password, File Upload, HTML, Pagebreaks, Entry Preview, Section Dividers, Ratings, Rich Text, and Hidden Field', 'wpforms-lite' ),
  1008. ],
  1009. ],
  1010. 'plus' => [
  1011. 'status' => 'full',
  1012. 'text' => [
  1013. '<strong>' . esc_html__( 'Access to all Standard and Fancy Fields', 'wpforms-lite' ) . '</strong>',
  1014. esc_html__( 'Address, Phone, Website URL, Date/Time, Password, File Upload, HTML, Pagebreaks, Entry Preview, Section Dividers, Ratings, Rich Text, and Hidden Field', 'wpforms-lite' ),
  1015. ],
  1016. ],
  1017. 'pro' => [
  1018. 'status' => 'full',
  1019. 'text' => [
  1020. '<strong>' . esc_html__( 'Access to all Standard and Fancy Fields', 'wpforms-lite' ) . '</strong>',
  1021. esc_html__( 'Address, Phone, Website URL, Date/Time, Password, File Upload, HTML, Pagebreaks, Entry Preview, Section Dividers, Ratings, Rich Text, Hidden, and Payment fields', 'wpforms-lite' ),
  1022. ],
  1023. ],
  1024. ],
  1025. 'conditionals' => [
  1026. 'lite' => [
  1027. 'status' => 'none',
  1028. 'text' => [
  1029. '<strong>' . esc_html__( 'Not available', 'wpforms-lite' ) . '</strong>',
  1030. ],
  1031. ],
  1032. 'basic' => [
  1033. 'status' => 'full',
  1034. 'text' => [
  1035. '<strong>' . esc_html__( 'Powerful Form Logic for Building Smart Forms', 'wpforms-lite' ) . '</strong>',
  1036. ],
  1037. ],
  1038. 'plus' => [
  1039. 'status' => 'full',
  1040. 'text' => [
  1041. '<strong>' . esc_html__( 'Powerful Form Logic for Building Smart Forms', 'wpforms-lite' ) . '</strong>',
  1042. ],
  1043. ],
  1044. 'pro' => [
  1045. 'status' => 'full',
  1046. 'text' => [
  1047. '<strong>' . esc_html__( 'Powerful Form Logic for Building Smart Forms', 'wpforms-lite' ) . '</strong>',
  1048. ],
  1049. ],
  1050. ],
  1051. 'templates' => [
  1052. 'lite' => [
  1053. 'status' => 'partial',
  1054. 'text' => [
  1055. '<strong>' . esc_html__( 'Basic Form Templates', 'wpforms-lite' ) . '</strong>',
  1056. ],
  1057. ],
  1058. 'basic' => [
  1059. 'status' => 'partial',
  1060. 'text' => [
  1061. '<strong>' . esc_html__( 'Basic Form Templates', 'wpforms-lite' ) . '</strong>',
  1062. ],
  1063. ],
  1064. 'plus' => [
  1065. 'status' => 'partial',
  1066. 'text' => [
  1067. '<strong>' . esc_html__( 'Basic Form Templates', 'wpforms-lite' ) . '</strong>',
  1068. ],
  1069. ],
  1070. 'pro' => [
  1071. 'status' => 'full',
  1072. 'text' => [
  1073. '<strong>' . esc_html__( 'All Form Templates including Bonus 300+ pre-made form templates', 'wpforms-lite' ) . '</strong>',
  1074. ],