Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthieu Aubry <mattab@users.noreply.github.com>2016-11-15 18:14:15 +0300
committerGitHub <noreply@github.com>2016-11-15 18:14:15 +0300
commitcd6af07f42a9558c2243b44dc3c45c4963b9a944 (patch)
tree802a311abcdab482ec4ab8bc9ba7a81b28b981c7 /plugins/ProfessionalServices
parent2258605179eaf3e86cf5d0bf2c1f367011abeac6 (diff)
Link to plugins (#10862)
* new SecurityInfo plugin release * Linking to plugins * Port * fix system test * Footer event message * Content tracking ad * No infobox in widget in dashboard to keep it lean
Diffstat (limited to 'plugins/ProfessionalServices')
-rw-r--r--plugins/ProfessionalServices/ProfessionalServices.php40
-rw-r--r--plugins/ProfessionalServices/Promo.php108
-rw-r--r--plugins/ProfessionalServices/Widgets/PromoServices.php2
-rw-r--r--plugins/ProfessionalServices/lang/en.json2
4 files changed, 116 insertions, 36 deletions
diff --git a/plugins/ProfessionalServices/ProfessionalServices.php b/plugins/ProfessionalServices/ProfessionalServices.php
index 203c3bb6f6..442f29edfe 100644
--- a/plugins/ProfessionalServices/ProfessionalServices.php
+++ b/plugins/ProfessionalServices/ProfessionalServices.php
@@ -8,6 +8,8 @@
namespace Piwik\Plugins\ProfessionalServices;
+use Piwik\Common;
+
class ProfessionalServices extends \Piwik\Plugin
{
/**
@@ -18,6 +20,8 @@ class ProfessionalServices extends \Piwik\Plugin
return array(
'AssetManager.getStylesheetFiles' => 'getStylesheetFiles',
'Request.getRenamedModuleAndAction' => 'renameProfessionalServicesModule',
+ 'Template.afterGoalConversionOverviewReport' => 'getGoalOverviewPromo',
+ 'Template.afterEventsReport' => 'getEventsPromo',
);
}
@@ -45,4 +49,40 @@ class ProfessionalServices extends \Piwik\Plugin
}
}
}
+
+ public function isRequestForDashboardWidget()
+ {
+ $isWidget = Common::getRequestVar('widget', 0, 'int');
+ return $isWidget;
+ }
+
+ public function getGoalOverviewPromo(&$out)
+ {
+ if(\Piwik\Plugin\Manager::getInstance()->isPluginActivated('AbTesting')
+ || $this->isRequestForDashboardWidget()) {
+ return;
+ }
+
+ $out .= '
+ <p style="margin-top:3em" class=" alert-info alert">Did you know?
+ With <a target="_blank" rel="noreferrer" href="https://piwik.org/recommends/ab-testing-learn-more/">A/B Testing for Piwik</a> you can immediately increase conversions and sales by creating different versions of a page to see which grows your business.
+ </p>
+ ';
+ }
+
+ public function getEventsPromo(&$out)
+ {
+ if($this->isRequestForDashboardWidget()) {
+ return;
+ }
+ $inlineAd = '';
+ if(!\Piwik\Plugin\Manager::getInstance()->isPluginActivated('MediaAnalytics')) {
+ $inlineAd = '<br/>When you publish videos or audios, <a target="_blank" rel="noreferrer" href="https://piwik.org/recommends/media-analytics-website">Media Analytics gives deep insights into your audience</a> and how they watch your videos or listens to your music.';
+ }
+ $out .= '<p style="margin-top:3em" class=" alert-info alert">Did you know?
+ <br/>Using Events you can measure any user interaction and gain amazing insights into your audience. <a target="_blank" href="?module=Proxy&action=redirect&url=http://piwik.org/docs/event-tracking/">Learn more</a>.
+ <br/> To measure blocks of content such as image galleries, listings or ads: use <a target="_blank" href="?module=Proxy&action=redirect&url=http://developer.piwik.org/guides/content-tracking">Content Tracking</a> and see exactly which content is viewed and clicked.
+ ' . $inlineAd . '
+ </p>';
+ }
}
diff --git a/plugins/ProfessionalServices/Promo.php b/plugins/ProfessionalServices/Promo.php
index 36f8ae155d..afbe6d0bd0 100644
--- a/plugins/ProfessionalServices/Promo.php
+++ b/plugins/ProfessionalServices/Promo.php
@@ -8,44 +8,84 @@
namespace Piwik\Plugins\ProfessionalServices;
+use Piwik\ProfessionalServices\Advertising;
+
class Promo
{
protected $linkTitles = array('Read more', 'Learn more');
- protected $content = array(
- array(
- 'campaignContent' => 'discoverPower',
- 'text' => 'Discover the power of open-source combined with enterprise-grade support and premium functionalities.'
- ),
- array(
- 'campaignContent' => 'bringEnterpriseLevel',
- 'text' => 'Bring your analytics to enterprise level. Upgrade your Piwik platform and receive access to numerous premium features and assistance from experts.'
- ),
- array(
- 'campaignContent' => 'funnelAnalytics',
- 'text' => 'Want Funnel Analytics? Get Premium features and enterprise-grade support.'
- ),
- array(
- 'campaignContent' => 'monitoringAndIncident',
- 'text' => 'Do you need 24/7 Monitoring and Incident Handling for your Piwik? Get Premium features and enterprise-grade support.'
- ),
- array(
- 'campaignContent' => 'slowingDown',
- 'text' => 'Is your Piwik slowing down? Piwik experts can help with your server setup!'
- ),
- array(
- 'campaignContent' => 'excitingFeatures',
- 'text' => 'Want to know how to use all the exciting features in Piwik? Try a User training to be up to speed with working with Piwik.'
- ),
- array(
- 'campaignContent' => 'slowingDown',
- 'text' => 'Did you know you can adjust the look and feel of Piwik to your brand, and even replace "Piwik" with your product name? Try the White Label product!',
- ),
- array(
- 'campaignContent' => 'metaSites',
- 'text' => 'Did you know you can aggregate the tracked data across hundreds of sites and display it in a single dashboard? Get Premium features and enterprise-grade support.',
- ),
- );
+ protected $content = array();
+
+ public function __construct()
+ {
+ $this->content = array(
+ // A/B Testing
+ array(
+ 'campaignContent' => 'abTesting',
+ 'url' => 'https://piwik.org/recommends/ab-testing-learn-more',
+ 'text' => 'Ever wondered what A/B testing is and why it is so important? Check out how you can increase conversions and sales on your website and app.'
+ ),
+ array(
+ 'campaignContent' => 'abTesting',
+ 'url' => ' https://piwik.org/recommends/ab-testing-website',
+ 'text' => 'Increase revenue and conversions by comparing different versions of your websites or apps, ad detect the winning variation that will grow your business!'
+ ),
+
+ // Media Analytics
+ array(
+ 'campaignContent' => 'mediaAnalytics',
+ 'url' => 'https://piwik.org/recommends/media-analytics-website',
+ 'text' => 'Ever wondered how people interact and engage with videos or audios on your website? Well now you can, and it integrates perfectly into your Piwik.',
+ ),
+
+ array(
+ 'campaignContent' => 'mediaAnalytics',
+ 'url' => 'https://piwik.org/recommends/media-analytics',
+ 'text' => 'Get powerful insights into how your audience watches your videos and listens to your audio. Media Analytics is now available on the Marketplace.',
+ ),
+
+ // Piwik training
+ array(
+ 'campaignContent' => 'userTraining',
+ 'url' => 'https://piwik.org/training/?pk_campaign=' . Advertising::CAMPAIGN_NAME_PROFESSIONAL_SERVICES . '&pk_source=Piwik_App',
+ 'text' => 'Want to know how to use all the exciting features in Piwik? Try a User training to be up to speed with working with Piwik.'
+ ),
+
+
+ // Piwik PRO
+ // https://piwik.org/recommends/piwik-pro-from-app
+ array(
+ 'campaignContent' => 'discoverPower',
+ 'url' => 'https://piwik.org/recommends/piwik-pro-from-app',
+ 'text' => 'Discover the power of open-source combined with enterprise-grade support and premium functionalities.'
+ ),
+ array(
+ 'campaignContent' => 'bringEnterpriseLevel',
+ 'url' => 'https://piwik.org/recommends/piwik-pro-from-app',
+ 'text' => 'Bring your analytics to enterprise level. Upgrade your Piwik platform and receive access to numerous premium features and assistance from experts.'
+ ),
+ array(
+ 'campaignContent' => 'monitoringAndIncident',
+ 'url' => 'https://piwik.org/recommends/piwik-pro-from-app',
+ 'text' => 'Do you need 24/7 Monitoring and Incident Handling for your Piwik? Get Premium features and enterprise-grade support.'
+ ),
+ array(
+ 'campaignContent' => 'slowingDown',
+ 'url' => 'https://piwik.org/recommends/piwik-pro-from-app',
+ 'text' => 'Is your Piwik slowing down? Piwik experts can help with your server setup!'
+ ),
+ array(
+ 'campaignContent' => 'whiteLabel',
+ 'url' => 'https://piwik.org/recommends/piwik-pro-from-app',
+ 'text' => 'Did you know you can adjust the look and feel of Piwik to your brand, and even replace "Piwik" with your product name? Try the White Label product!',
+ ),
+ array(
+ 'campaignContent' => 'metaSites',
+ 'url' => 'https://piwik.org/recommends/piwik-pro-from-app',
+ 'text' => 'Did you know you can aggregate the collected data across hundreds of sites and display it in a single dashboard? Get Premium features and enterprise-grade support.',
+ )
+ );
+ }
public function getLinkTitle()
{
diff --git a/plugins/ProfessionalServices/Widgets/PromoServices.php b/plugins/ProfessionalServices/Widgets/PromoServices.php
index 516d5860c6..8a34d5500e 100644
--- a/plugins/ProfessionalServices/Widgets/PromoServices.php
+++ b/plugins/ProfessionalServices/Widgets/PromoServices.php
@@ -47,7 +47,7 @@ class PromoServices extends \Piwik\Widget\Widget
$promo = $this->promo->getContent();
- $view->ctaLinkUrl = $this->advertising->getPromoUrlForPiwikProUpgrade();
+ $view->ctaLinkUrl = $promo['url'];
$view->ctaText = $promo['text'];
$view->ctaLinkTitle = $this->promo->getLinkTitle();
diff --git a/plugins/ProfessionalServices/lang/en.json b/plugins/ProfessionalServices/lang/en.json
index 1f275d103f..86d44f4d0a 100644
--- a/plugins/ProfessionalServices/lang/en.json
+++ b/plugins/ProfessionalServices/lang/en.json
@@ -1,5 +1,5 @@
{
"ProfessionalServices": {
- "WidgetProfessionalServicesForPiwik": "Professional Services for Piwik"
+ "WidgetProfessionalServicesForPiwik": "Premium Products & Services for Piwik"
}
} \ No newline at end of file