diff options
author | mattab <matthieu.aubry@gmail.com> | 2014-11-27 06:05:39 +0300 |
---|---|---|
committer | mattab <matthieu.aubry@gmail.com> | 2014-11-27 06:05:39 +0300 |
commit | 9c165f4ce96b96ac0d77d6d86ebf21ca49405f1c (patch) | |
tree | 0b1e579cc8fcb281c9d8279138666dfac69e865a /plugins/Goals | |
parent | edae22dc793608cc713ac11baf6cfa5706302c49 (diff) |
Fixes #3147 Add rel="noreferrer" to all outgoing links . This works in Firefox so far and only for "left clicks". Not perfect, but hopefully other browsers will implement this in the future, as it's a useful privacy enhancing feature!
Diffstat (limited to 'plugins/Goals')
-rw-r--r-- | plugins/Goals/API.php | 2 | ||||
-rw-r--r-- | plugins/Goals/Goals.php | 2 | ||||
-rw-r--r-- | plugins/Goals/Visualizations/Goals.php | 2 | ||||
-rw-r--r-- | plugins/Goals/templates/_addEditGoal.twig | 8 | ||||
-rw-r--r-- | plugins/Goals/templates/_formAddGoal.twig | 2 | ||||
-rw-r--r-- | plugins/Goals/templates/addNewGoal.twig | 2 |
6 files changed, 9 insertions, 9 deletions
diff --git a/plugins/Goals/API.php b/plugins/Goals/API.php index 735b647866..076269ff6f 100644 --- a/plugins/Goals/API.php +++ b/plugins/Goals/API.php @@ -35,7 +35,7 @@ use Piwik\Tracker\GoalManager; * If you wish to request specific metrics about Ecommerce goals, you can set the parameter &idGoal=ecommerceAbandonedCart to get metrics about abandoned carts (including Lost revenue, and number of items left in the cart) * or &idGoal=ecommerceOrder to get metrics about Ecommerce orders (number of orders, visits with an order, subtotal, tax, shipping, discount, revenue, items ordered) * - * See also the documentation about <a href='http://piwik.org/docs/tracking-goals-web-analytics/' target='_blank'>Tracking Goals</a> in Piwik. + * See also the documentation about <a href='http://piwik.org/docs/tracking-goals-web-analytics/' rel='noreferrer' target='_blank'>Tracking Goals</a> in Piwik. * * @method static \Piwik\Plugins\Goals\API getInstance() */ diff --git a/plugins/Goals/Goals.php b/plugins/Goals/Goals.php index 381c37f7ee..a5659183ba 100644 --- a/plugins/Goals/Goals.php +++ b/plugins/Goals/Goals.php @@ -24,7 +24,7 @@ class Goals extends \Piwik\Plugin public function getInformation() { $suffix = Piwik::translate('SitesManager_PiwikOffersEcommerceAnalytics', - array('<a href="http://piwik.org/docs/ecommerce-analytics/" target="_blank">', '</a>')); + array('<a href="http://piwik.org/docs/ecommerce-analytics/" rel="noreferrer" target="_blank">', '</a>')); $info = parent::getInformation(); $info['description'] .= ' ' . $suffix; return $info; diff --git a/plugins/Goals/Visualizations/Goals.php b/plugins/Goals/Visualizations/Goals.php index 9808621b14..c373e5bac7 100644 --- a/plugins/Goals/Visualizations/Goals.php +++ b/plugins/Goals/Visualizations/Goals.php @@ -57,7 +57,7 @@ class Goals extends HtmlTable if (1 == Common::getRequestVar('documentationForGoalsPage', 0, 'int')) { // TODO: should not use query parameter $this->config->documentation = Piwik::translate('Goals_ConversionByTypeReportDocumentation', - array('<br />', '<br />', '<a href="http://piwik.org/docs/tracking-goals-web-analytics/" target="_blank">', '</a>')); + array('<br />', '<br />', '<a href="http://piwik.org/docs/tracking-goals-web-analytics/" rel="noreferrer" target="_blank">', '</a>')); } parent::beforeRender(); diff --git a/plugins/Goals/templates/_addEditGoal.twig b/plugins/Goals/templates/_addEditGoal.twig index f9449d8ce9..f7373b6b8e 100644 --- a/plugins/Goals/templates/_addEditGoal.twig +++ b/plugins/Goals/templates/_addEditGoal.twig @@ -4,7 +4,7 @@ <p>{{ 'Goals_NewGoalDescription'|translate }} {{ 'Goals_NewWhatDoYouWantUsersToDo'|translate }} {{ 'Goals_NewGoalYouWillBeAbleTo'|translate }}</p> - <p>{{ 'Goals_LearnMoreAboutGoalTrackingDocumentation'|translate("<a href='?module=Proxy&action=redirect&url=http://piwik.org/docs/tracking-goals-web-analytics/' target='_blank'>","</a>")|raw }} + <p>{{ 'Goals_LearnMoreAboutGoalTrackingDocumentation'|translate("<a href='?module=Proxy&action=redirect&url=http://piwik.org/docs/tracking-goals-web-analytics/' rel='noreferrer' target='_blank'>","</a>")|raw }} </p> {% else %} <div class="clear"></div> @@ -13,7 +13,7 @@ <ul class='listCircle'> <li><a onclick='' name='linkAddNewGoal'>{{ 'Goals_CreateNewGOal'|translate }}</a></li> <li><a onclick='' name='linkEditGoals'>{{ 'Goals_ViewAndEditGoals'|translate }}</a></li> - <li>{{ 'Goals_LearnMoreAboutGoalTrackingDocumentation'|translate("<a href='?module=Proxy&action=redirect&url=http://piwik.org/docs/tracking-goals-web-analytics/' target='_blank'>","</a>")|raw }}</li> + <li>{{ 'Goals_LearnMoreAboutGoalTrackingDocumentation'|translate("<a href='?module=Proxy&action=redirect&url=http://piwik.org/docs/tracking-goals-web-analytics/' rel='noreferrer' target='_blank'>","</a>")|raw }}</li> <li> {% if not ecommerceEnabled %} @@ -21,11 +21,11 @@ <a href='{{ linkTo({'module':'SitesManager','action':'index' }) }}'>{{ 'SitesManager_WebsitesManagement'|translate }}</a> {% endset %} {% set ecommerceReportText %} - <a href="http://piwik.org/docs/ecommerce-analytics/" target="_blank">{{ 'Goals_EcommerceReports'|translate }}</a> + <a href="http://piwik.org/docs/ecommerce-analytics/" rel="noreferrer" target="_blank">{{ 'Goals_EcommerceReports'|translate }}</a> {% endset %} {{ 'Goals_Optional'|translate }} {{ 'Goals_Ecommerce'|translate }}: {{ 'Goals_YouCanEnableEcommerceReports'|translate(ecommerceReportText,websiteManageText)|raw }} {% else %} - {{ 'SitesManager_PiwikOffersEcommerceAnalytics'|translate('<a href="http://piwik.org/docs/ecommerce-analytics/" target="_blank">',"</a>")|raw }} + {{ 'SitesManager_PiwikOffersEcommerceAnalytics'|translate('<a href="http://piwik.org/docs/ecommerce-analytics/" rel="noreferrer" target="_blank">',"</a>")|raw }} {% endif %} </li> </ul> diff --git a/plugins/Goals/templates/_formAddGoal.twig b/plugins/Goals/templates/_formAddGoal.twig index 7bff75f8cb..e2da3c1ffb 100644 --- a/plugins/Goals/templates/_formAddGoal.twig +++ b/plugins/Goals/templates/_formAddGoal.twig @@ -67,7 +67,7 @@ <tbody id="manual_trigger_section" style="display:none;"> <tr> <td colspan="2" class="first"> - {{ 'Goals_WhereVisitedPageManuallyCallsJavascriptTrackerLearnMore'|translate("<a target='_blank' href='?module=Proxy&action=redirect&url=http://piwik.org/docs/javascript-tracking/%23toc-manually-trigger-a-conversion-for-a-goal'>","</a>")|raw }} + {{ 'Goals_WhereVisitedPageManuallyCallsJavascriptTrackerLearnMore'|translate("<a rel='noreferrer' target='_blank' href='?module=Proxy&action=redirect&url=http://piwik.org/docs/javascript-tracking/%23toc-manually-trigger-a-conversion-for-a-goal'>","</a>")|raw }} </td> </tr> </tbody> diff --git a/plugins/Goals/templates/addNewGoal.twig b/plugins/Goals/templates/addNewGoal.twig index e4cbaea787..6d227bc11c 100644 --- a/plugins/Goals/templates/addNewGoal.twig +++ b/plugins/Goals/templates/addNewGoal.twig @@ -6,6 +6,6 @@ {{ 'Goals_NoGoalsNeedAccess'|translate|raw }} </p> <p> - {{ 'Goals_LearnMoreAboutGoalTrackingDocumentation'|translate("<a href='?module=Proxy&action=redirect&url=http://piwik.org/docs/tracking-goals-web-analytics/' target='_blank'>","</a>")|raw }} + {{ 'Goals_LearnMoreAboutGoalTrackingDocumentation'|translate("<a href='?module=Proxy&action=redirect&url=http://piwik.org/docs/tracking-goals-web-analytics/' rel='noreferrer' target='_blank'>","</a>")|raw }} </p> {% endif %} |