JFIF $ d d 7 * Z qn )ZP 0 !1 A "#a$2Qr D8 a Ri [f \m I ykI w0 c u F c Rı?lO7 к _f˓ [C $殷WF< _W ԣ s Kc ëI zyQy /_LK ℂ ;C",p F A : /] =H ~ , l s / 9 ć: [=/#f ; ) x { ٛE Q )~ = 𘙲r*2~ a _V = ' ku m F D } KYYC )( { * g& f `툪 r y ` = ^ c J. I ]( * `wq 1dđ #̩ ͑ 0 ; H ] u 搂 @:~ ו K L N s h } O I R* 8 :2 ! lD JV o ( 3 = M ( z Ȱ+i *N A r6K n S l ) ! J J Ӂ* % ݉?|D } d5: eP0 R; {$X' x F @ .ÊB {,WJ uQ ɲRI ;9 Q E琯 6 2fT .DU J ;*c P A\IL Nj! J ۱+ O\ ͔ ] ޒ S J ȧ c%A N ol ՎprU L Zԛe r E2= X D Xg VQeӓ k y P7 U* o m Q I s ,K `) 6\G3t?pgjr m ۛجw luGt f h 9uyP 0D;Uڽ"OXl i f $ ) &|ML 0 Z rm1 [ H XP l P R0 'G=i 2N +0 e 2 ]] 9 VT P O 7 h(F * 癈 ' = Q VZD F,d ߬ ~ T X G[ `le 69C R(!S2! P < 0 x < !1AQ "Raq 02Br #S CTb ? Ζ "]mH5WR 7 k.ۛ ! } Q~ + yԏ z |@ T20 S~ K e k *zF f^2X *( @ 8 r ? C I uI|֓>^Ex LgNU Y+{.R Ѫ τV YT D I 6 2 '8Y2 7'\T P.6 d &˦ @V q i |8 -O Ε ] ʔ U= T L 8= ;6c | !qfF3 a ů& ~$ l} 'NW U s$U k^S V : U#6w + +s &r+n ڐ { @ 29gL u " T Ù M=6 (^ "7 r}=6Yݾ lC u hquymp Ǧ G jhs ǜNl ɻ} o 7 #S6 a w 4 ! OS r D 5 7 % | ?x> L | / nD 6?/8 w # [ ) L 7 +6〼T A T g ! %5 Mm Z /c -{1_Je "| ^$ 'O & ޱմ < H vNqϡQ$ < 6 &Nݛ ֨tǻN (9 n ru~'όN sMG& ,uH Kw *Ī 5@ u6 BԒ i YN * f 0 _ GhKW u lT <nj- 0{ M L~ | /a v\ E = ?1 \ɟuq Ђ Y O a K ޡP q $ H8o Q˼EV ~ k 0 h' L Pp M -M" m^ !6l nմ 쮝C U T . ! :vMǨb h ډ Vc r @~p # !1QAa q ? AL0L x LU 4 d ; x " 16ad0 7.\ߋ 0 = P l v/ " c A Ay A|2pO8"d MV #1] = \ " ˡ ] k v I9 d ۓ & q ) ǐq E ꞅ v "P )q X &Q З non]я u ג./ ; gZ$ M QР 2M ]h ni 0 P $ێ 3CɏGjώy : m c # S_ l@ '_ \m|C 2`K _ 1 cIvGc $? PCQ S+D ? K aײ k Fr b 8 ύ NEدg ĝ U 3 6 #Ik+ v { v i ( ވ ? a e) X xy/*@Q Ǽ Ծ ) $ IWO l c G; !i k{ gOŀ L ('x T rb $ w) R $ & N1E td U3Uȉ1p M"N* (DNy d96.(jQ) X 5 c QɎMy W ? Q *!R > 6=7)Xj 5`J ] e 8%t ! + ' ! 1Q 5 !1 AQaq ё #2 "0BRb ? G t^ ## .l lQ T $ v , ,m 㵜5u bV =sY+ @d { N ! dn O < .- B; _w J t 6;Q Jd. Q c%p{ 1 ,sND dF H I0 Гo X ш e黅X ۢ F :)[ F G X ƹ / w _c MeD ,ʡc c . W D tA $ j@ : ) - #u c1< @ۗ9F ) KJ- hpP] _ x [ q B lb p ʖ w q " LFGd ƶ * s +ډ_Zc " ? % t[I P 6 J ]# =ɺ V v v CGs Gh1 > )6 |e y ? L ӣ m,4 G W Ui ` ] uJVo VDG< SB 6ϏQ @ TiU l y O U 0 kfV ~ ~}S Z @ *WU Ui ## ; s /[ = ! 7}" W N ] ' (L ! ~ y5 g9T̅J kbM' +s :S +B) v @ M j e C f j E 0 Y\Qn z G 1 д~ W o{T 9?` Rm yhsy3 !HAD ] m c1 ~ 2 L S u7x T ;j$ `} 4-> L# vzŏ I L S ֭ T { r jGK C ; b pU= - ` Bs K. S F w4 M q] Z dH S 0 ) tLg
<?php
// phpcs:disable Generic.Commenting.DocComment.MissingShort
/** @noinspection AutoloadingIssuesInspection */
/** @noinspection PhpIllegalPsrClassPathInspection */
// phpcs:enable Generic.Commenting.DocComment.MissingShort
use WPForms\Migrations\Base as MigrationsBase;
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
/**
* Welcome page class.
*
* This page is shown when the plugin is activated.
*
* @since 1.0.0
*/
class WPForms_Welcome {
/**
* Hidden welcome page slug.
*
* @since 1.5.6
*/
private const SLUG = 'wpforms-getting-started';
/**
* Primary class constructor.
*
* @since 1.0.0
*/
public function __construct() { // phpcs:ignore WPForms.PHP.HooksMethod.InvalidPlaceForAddingHooks
add_action( 'plugins_loaded', [ $this, 'hooks' ] );
}
/**
* Register all WP hooks.
*
* @since 1.5.6
*/
public function hooks(): void {
// If the user is in admin ajax or doing cron, return.
if ( wp_doing_ajax() || wp_doing_cron() ) {
return;
}
// If the user cannot manage_options, return.
if ( ! wpforms_current_user_can() ) {
return;
}
add_action( 'admin_menu', [ $this, 'register' ] );
add_action( 'admin_head', [ $this, 'hide_menu' ] );
add_action( 'admin_init', [ $this, 'redirect' ], 9999 );
}
/**
* Register the pages to be used for the Welcome screen (and tabs).
*
* These pages will be removed from the Dashboard menu, so they will be not shown.
* Sneaky, sneaky.
*
* @since 1.0.0
*/
public function register(): void {
// Getting started - shows after installation.
add_dashboard_page(
esc_html__( 'Welcome to WPForms', 'wpforms-lite' ),
esc_html__( 'Welcome to WPForms', 'wpforms-lite' ),
/**
* Filter the capability to add the Welcome page.
*
* @since 1.5.6
*
* @param string $capability The capability to manage everything for WPForms.
*/
apply_filters( 'wpforms_welcome_cap', wpforms_get_capability_manage_options() ),
self::SLUG,
[ $this, 'output' ]
);
}
/**
* Removed the dashboard pages from the admin menu.
*
* This means the pages are still available to us but hidden.
*
* @since 1.0.0
*/
public function hide_menu(): void {
remove_submenu_page( 'index.php', self::SLUG );
}
/**
* Welcome screen redirect.
*
* This function checks if a new installation or update has just occurred.
* If so, then we redirect the user to the appropriate page.
*
* @since 1.0.0
*/
public function redirect(): void {
// Check if we should consider redirection.
if ( ! get_transient( 'wpforms_activation_redirect' ) ) {
return;
}
// If we are redirecting, clear the transient so it only happens once.
delete_transient( 'wpforms_activation_redirect' );
// Check an option to disable welcome redirect.
if ( get_option( 'wpforms_activation_redirect', false ) ) {
return;
}
// Only do this for a single site installs.
// phpcs:ignore WordPress.Security.NonceVerification.Recommended
if ( isset( $_GET['activate-multi'] ) || is_network_admin() ) {
return;
}
global $pagenow;
/**
* When installing the plugin using the WPForms Gutenberg block, we should not redirect to the Getting Started page.
* It causes the WPForms block rendering error.
*/
if ( in_array( $pagenow, [ 'edit.php', 'post.php', 'post-new.php', 'site-editor.php' ], true ) ) {
return;
}
/**
* We should not redirect from the Form Builder.
*/
if ( wpforms_is_admin_page( 'builder' ) ) {
return;
}
// The wizard kill switch disables the whole first-run experience: when
// the Setup Wizard is disabled via its option, constant, or filter,
// this fallback redirect must not fire either.
if ( $this->is_setup_wizard_disabled() ) {
return;
}
// The Setup Wizard owns the first-run experience. Defer to it when it
// auto-launches on this request and stands down entirely once it has finished.
// This page is only the fallback when the wizard cannot run.
if ( $this->setup_wizard_handles_first_run() ) {
return;
}
// Check if this is an update or first install.
$upgrade = get_option( MigrationsBase::PREVIOUS_CORE_VERSION_OPTION_NAME );
if ( ! $upgrade ) {
// Initial install.
wp_safe_redirect( admin_url( 'index.php?page=' . self::SLUG ) );
exit;
}
}
/**
* Whether the Setup Wizard, not this page, owns the first-run experience.
*
* True when the wizard will auto-launch on this request or has already
* finished. Guarded so the page degrades to its legacy behaviour if the
* wizard class is unavailable (e.g. filtered out).
*
* @since 2.0.0
*
* @return bool
* @noinspection ClassConstantCanBeUsedInspection
*/
private function setup_wizard_handles_first_run(): bool {
$wizard = '\WPForms\SetupWizard\SetupWizard';
if ( ! class_exists( $wizard ) || ! method_exists( $wizard, 'will_auto_launch' ) ) {
return false;
}
// Already finished: never bounce the user to the getting-started screen.
if ( get_option( $wizard::OPTION_COMPLETED ) ) {
return true;
}
return $wizard::will_auto_launch();
}
/**
* Whether the Setup Wizard kill switch suppresses this redirect too.
*
* The `wpforms_setup_wizard_disabled` option, the
* `WPFORMS_SETUP_WIZARD_DISABLED` constant, and the
* `wpforms_setup_wizard_setup_wizard_is_disabled` filter disable the whole
* first-run experience, not only the wizard, so provisioning flows get zero
* unintended screens from a single switch. Guarded so the page degrades to
* its legacy behaviour if the wizard class is unavailable.
*
* @since 2.0.1
*
* @return bool
* @noinspection ClassConstantCanBeUsedInspection
*/
private function is_setup_wizard_disabled(): bool {
$wizard = '\WPForms\SetupWizard\SetupWizard';
if ( ! class_exists( $wizard ) || ! method_exists( $wizard, 'is_disabled' ) ) {
return false;
}
return $wizard::is_disabled();
}
/**
* Output a notice offering to launch the Setup Wizard manually.
*
* Shown on the Welcome page so users who landed here as the wizard fallback
* can still start the guided setup on demand. Hidden when the wizard class is
* unavailable (e.g. filtered out).
*
* @since 2.0.0
*/
private function output_setup_wizard_notice(): void {
$wizard = '\WPForms\SetupWizard\SetupWizard';
if ( ! class_exists( $wizard ) || ! method_exists( $wizard, 'get_manual_launch_url' ) ) {
return;
}
$url = $wizard::get_manual_launch_url();
?>
<div class="wpforms-welcome-setup-wizard-notice">
<p>
<?php
$wizard_link = sprintf(
'<a href="%1$s">%2$s</a>',
esc_url( $url ),
esc_html__( 'WPForms Setup Wizard', 'wpforms-lite' )
);
printf(
wp_kses(
/* translators: %s - WPForms Setup Wizard link. */
__( 'Prefer a guided setup? Launch the %s to configure your site step-by-step.', 'wpforms-lite' ),
[
'a' => [
'href' => [],
],
]
),
$wizard_link // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
);
?>
</p>
</div>
<?php
}
/**
* Getting Started screen. Shows after the first installation.
*
* @since 1.0.0
*/
public function output(): void {
$class = wpforms()->is_pro() ? 'pro' : 'lite';
?>
<div id="wpforms-welcome" class="<?php echo sanitize_html_class( $class ); ?>">
<div class="container">
<?php $this->output_setup_wizard_notice(); ?>
<div class="intro">
<div class="sullie">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/sullie.png' ); ?>" alt="<?php esc_attr_e( 'Sullie the WPForms mascot', 'wpforms-lite' ); ?>">
</div>
<div class="block">
<h1><?php esc_html_e( 'Welcome to WPForms', 'wpforms-lite' ); ?></h1>
<h6><?php esc_html_e( 'Thank you for choosing WPForms - the most powerful drag & drop WordPress form builder in the market.', 'wpforms-lite' ); ?></h6>
</div>
<a href="#" class="play-video" title="<?php esc_attr_e( 'Watch how to create your first form', 'wpforms-lite' ); ?>">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-video.png' ); ?>" alt="<?php esc_attr_e( 'Watch how to create your first form', 'wpforms-lite' ); ?>" class="video-thumbnail">
</a>
<div class="block">
<h6><?php esc_html_e( 'WPForms makes it easy to create forms in WordPress. You can watch the video tutorial or read our guide on how to create your first form.', 'wpforms-lite' ); ?></h6>
<div class="button-wrap wpforms-clear">
<div class="left">
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wpforms-builder' ) ); ?>" class="wpforms-btn wpforms-btn-block wpforms-btn-lg wpforms-btn-orange">
<?php esc_html_e( 'Create Your First Form', 'wpforms-lite' ); ?>
</a>
</div>
<div class="right">
<a href="<?php echo esc_url( wpforms_utm_link( 'https://wpforms.com/docs/creating-first-form/', 'welcome-page', 'Read the Full Guide' ) ); ?>"
class="wpforms-btn wpforms-btn-block wpforms-btn-lg wpforms-btn-grey" target="_blank" rel="noopener noreferrer">
<?php esc_html_e( 'Read the Full Guide', 'wpforms-lite' ); ?>
</a>
</div>
</div>
</div>
</div><!-- /.intro -->
<?php
/**
* Fires after Welcome Intro.
*
* @since 1.5.6
*/
do_action( 'wpforms_welcome_intro_after' );
?>
<div class="features">
<div class="block">
<h1><?php esc_html_e( 'WPForms Features & Addons', 'wpforms-lite' ); ?></h1>
<h6><?php esc_html_e( 'WPForms is both easy to use and extremely powerful. We have tons of helpful features that allow us to give you everything you need from a form builder.', 'wpforms-lite' ); ?></h6>
<div class="feature-list wpforms-clear">
<div class="feature-block first">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-1.png' ); ?>">
<h5><?php esc_html_e( 'Drag & Drop Form Builder', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Easily create an amazing form in just a few minutes without writing any code.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block last">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-2.png' ); ?>">
<h5><?php esc_html_e( 'Form Templates', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Start with pre-built form templates to save even more time.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block first">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-3.png' ); ?>">
<h5><?php esc_html_e( 'Responsive Mobile Friendly', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'WPForms is 100% responsive meaning it works on mobile, tablets & desktop.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block last">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-4.png' ); ?>">
<h5><?php esc_html_e( 'Smart Conditional Logic', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Easily create high performance forms with our smart conditional logic.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block first">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-5.png' ); ?>">
<h5><?php esc_html_e( 'Instant Notifications', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Respond to leads quickly with our instant form notification feature for your team.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block last">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-6.png' ); ?>">
<h5><?php esc_html_e( 'Entry Management', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'View all your leads in one place to streamline your workflow.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block first">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-7.png' ); ?>">
<h5><?php esc_html_e( 'Payments Made Easy', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Easily collect payments, donations, and online orders without hiring a developer.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block last">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-8.png' ); ?>">
<h5><?php esc_html_e( 'Marketing & Subscriptions', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Create subscription forms and connect with your email marketing service.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block first">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-9.png' ); ?>">
<h5><?php esc_html_e( 'Easy to Embed', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Easily embed your forms in blog posts, pages, sidebar widgets, footer, etc.', 'wpforms-lite' ); ?></p>
</div>
<div class="feature-block last">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-feature-icon-10.png' ); ?>">
<h5><?php esc_html_e( 'Spam Protection', 'wpforms-lite' ); ?></h5>
<p><?php esc_html_e( 'Our smart captcha and spam protection automatically prevents spam submissions.', 'wpforms-lite' ); ?></p>
</div>
</div>
<div class="button-wrap">
<a href="<?php echo esc_url( wpforms_utm_link( 'https://wpforms.com/features/', 'welcome-page', 'See All Features' ) ); ?>"
class="wpforms-btn wpforms-btn-lg wpforms-btn-grey" rel="noopener noreferrer" target="_blank">
<?php esc_html_e( 'See All Features', 'wpforms-lite' ); ?>
</a>
</div>
</div>
</div><!-- /.features -->
<div class="upgrade-cta upgrade">
<div class="block wpforms-clear">
<div class="left">
<h2><?php esc_html_e( 'Upgrade to PRO', 'wpforms-lite' ); ?></h2>
<ul>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Advanced Fields', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Conditional Logic', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Payment Forms', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Surveys & Polls', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Signatures', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Form Abandonment', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Entry Management', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'File Uploads', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Geolocation', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Conversational Forms', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'User Registration', 'wpforms-lite' ); ?></li>
<li><span class="dashicons dashicons-yes"></span> <?php esc_html_e( 'Marketing Integrations', 'wpforms-lite' ); ?></li>
</ul>
</div>
<div class="right">
<h2><span>PRO</span></h2>
<div class="price">
<span class="amount">199</span><br>
<span class="term"><?php esc_html_e( 'per year', 'wpforms-lite' ); ?></span>
</div>
<a href="<?php echo esc_url( wpforms_admin_upgrade_link( 'welcome', 'Upgrade Now CTA Section' ) ); ?>" rel="noopener noreferrer" target="_blank"
class="wpforms-btn wpforms-btn-block wpforms-btn-lg wpforms-btn-orange wpforms-upgrade-modal">
<?php esc_html_e( 'Upgrade Now', 'wpforms-lite' ); ?>
</a>
</div>
</div>
</div>
<div class="testimonials upgrade">
<div class="block">
<h1><?php esc_html_e( 'Testimonials', 'wpforms-lite' ); ?></h1>
<div class="testimonial-block wpforms-clear">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-testimonial-bill.jpg' ); ?>">
<p><?php esc_html_e( 'WPForms is by far the easiest form plugin to use. My clients love it – it’s one of the few plugins they can use without any training. As a developer I appreciate how fast, modern, clean and extensible it is.', 'wpforms-lite' ); ?>
<p>
<p><strong>Bill Erickson</strong>, Erickson Web Consulting</p>
</div>
<div class="testimonial-block wpforms-clear">
<img src="<?php echo esc_url( WPFORMS_PLUGIN_URL . 'assets/images/welcome-testimonial-david.jpg' ); ?>">
<p><?php esc_html_e( 'As a business owner, time is my most valuable asset. WPForms allow me to create smart online forms with just a few clicks. With their pre-built form templates and the drag & drop builder, I can create a new form that works in less than 2 minutes without writing a single line of code. Well worth the investment.', 'wpforms-lite' ); ?>
<p>
<p><strong>David Henzel</strong>, MaxCDN</p>
</div>
</div>
</div><!-- /.testimonials -->
<div class="footer">
<div class="block wpforms-clear">
<div class="button-wrap wpforms-clear">
<div class="left">
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wpforms-builder' ) ); ?>"
class="wpforms-btn wpforms-btn-block wpforms-btn-lg wpforms-btn-orange">
<?php esc_html_e( 'Create Your First Form', 'wpforms-lite' ); ?>
</a>
</div>
<div class="right">
<a href="<?php echo esc_url( wpforms_admin_upgrade_link( 'welcome', 'Upgrade to WPForms Pro' ) ); ?>" target="_blank" rel="noopener noreferrer"
class="wpforms-btn wpforms-btn-block wpforms-btn-lg wpforms-btn-trans-green wpforms-upgrade-modal">
<span class="underline">
<?php esc_html_e( 'Upgrade to WPForms Pro', 'wpforms-lite' ); ?> <span class="dashicons dashicons-arrow-right"></span>
</span>
</a>
</div>
</div>
</div>
</div><!-- /.footer -->
</div><!-- /.container -->
</div><!-- /#wpforms-welcome -->
<?php
}
}
new WPForms_Welcome();