Skip to content

Commit e5f5922

Browse files
add upgrade link to dashboard nav
1 parent 7f34f71 commit e5f5922

File tree

3 files changed

+8
-7
lines changed

3 files changed

+8
-7
lines changed

src/class-notice-pro.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ public function maybe_show(): void
8484
</summary>
8585
<p><?php printf(esc_html__('If you enjoy using this free plugin, consider %1$supgrading to Koko Analytics Pro%2$s to get access to several powerful benefits:', 'koko-analytics'), '<a href="https://www.kokoanalytics.com/pricing/">', '</a>'); ?></p>
8686
<ul class="ul-square">
87+
<li><a href="https://www.kokoanalytics.com/features/geo-location/"><?php esc_html_e('Geo-location', 'koko-analytics'); ?></a></li>
8788
<li><a href="https://www.kokoanalytics.com/features/email-reports/"><?php esc_html_e('Periodic email reports', 'koko-analytics'); ?></a></li>
8889
<li><a href="https://www.kokoanalytics.com/features/custom-event-tracking/"><?php esc_html_e('Custom event tracking', 'koko-analytics'); ?></a></li>
8990
<li><a href="https://www.kokoanalytics.com/features/admin-bar/"><?php esc_html_e('Stats in your admin bar', 'koko-analytics'); ?></a></li>
@@ -93,7 +94,7 @@ public function maybe_show(): void
9394

9495
<p><?php printf(esc_html__('Alternatively, %1$sleaving a plugin review on WordPress.org%2$s helps us a great deal as well.', 'koko-analytics'), '<a href="https://wordpress.org/support/view/plugin-reviews/koko-analytics?rate=5#postform">', '</a>'); ?></p>
9596
<p>
96-
<?php esc_html_e('We thank you for your consideration.', 'koko-analytics'); ?><br />
97+
<?php esc_html_e('Thank you for your consideration.', 'koko-analytics'); ?><br />
9798
~ Danny, Harish and Arne
9899
</p>
99100
<p><a href="https://www.kokoanalytics.com/pricing/" class="button button-primary"><?php esc_html_e('Learn more about Koko Analytics Pro', 'koko-analytics'); ?></a> &nbsp; <a href="<?php echo esc_attr(add_query_arg(['ka-notice-pro-dismiss' => 1])); ?>" style="color: #CC0000;"><?php esc_html_e('Never show again', 'koko-analytics'); ?></a></p>

src/views/nav.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@
99
<?php if ($tab === 'dashboard') { ?>
1010
<?php if (isset($_GET['koko-analytics-dashboard'])) { ?>
1111
<li><a href="<?php echo admin_url('index.php?page=koko-analytics'); ?>">
12-
<?php esc_html_e('Switch to admin view', 'koko-analytics'); ?>
12+
<?php esc_html_e('Admin view', 'koko-analytics'); ?>
1313
</a></li>
1414
<?php } else { ?>
1515
<li><a href="<?php echo esc_attr(add_query_arg(['koko-analytics-dashboard' => 1], home_url())); ?>"">
16-
<?php esc_html_e('Switch to standalone view', 'koko-analytics'); ?>
16+
<?php esc_html_e('Standalone view', 'koko-analytics'); ?>
1717
</a></li>
1818
<?php } ?>
1919
<?php } else { ?>
@@ -25,5 +25,9 @@
2525
<li><a href="<?php echo admin_url('index.php?page=koko-analytics&tab=settings'); ?>" class="<?php echo $tab === 'settings' ? 'current' : ''; ?>">
2626
<?php esc_html_e('Settings', 'koko-analytics'); ?>
2727
</a></li>
28+
<?php if (!defined('KOKO_ANALYTICS_PRO_VERSION')) { ?>
29+
<li><a href="https://www.kokoanalytics.com/pricing/" style="color:#b60205;">Upgrade to Pro</a></li>
30+
<?php } ?>
2831
</nav>
2932
<?php } ?>
33+
<?php // background:#b60205; color: white; display: inline-block; padding: 0.5em 1em; border-radius: 8px; line-height: 1; text-decoration: none; font-weight: bold;" ?>

src/views/settings-page.php

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,6 @@
4545
<?php } ?>
4646
<?php } // end if endpoint-installed ?>
4747

48-
<?php if (class_exists('Jetpack')) { ?>
49-
<div class="notice notice-info is-dismissible"><p><?php printf(__('We noticed you have Jetpack enabled. Do you want to <a href="%1$s">import your historical statistics data from JetPack stats into Koko Analytics</a>?', 'koko-analytics'), esc_attr(add_query_arg(['tab' => 'jetpack_importer']))); ?></p></div>
50-
<?php } ?>
51-
5248
<form method="POST" action="<?php echo esc_attr(add_query_arg(['koko_analytics_action' => 'save_settings'])); ?>">
5349
<?php wp_nonce_field('koko_analytics_save_settings'); ?>
5450
<?php wp_referer_field(); ?>

0 commit comments

Comments
 (0)