r114424 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r114423‎ | r114424 | r114425 >
Date:14:48, 22 March 2012
Author:rsterbin
Status:deferred
Tags:
Comment:
Pass the floating link ID through to edit, so it can be added to the edit clicktracking events
Modified paths:
  • /trunk/extensions/ArticleFeedbackv5/ArticleFeedbackv5.hooks.php (modified) (history)
  • /trunk/extensions/ArticleFeedbackv5/modules/jquery.articleFeedbackv5/jquery.articleFeedbackv5.js (modified) (history)

Diff [purge]

Index: trunk/extensions/ArticleFeedbackv5/modules/jquery.articleFeedbackv5/jquery.articleFeedbackv5.js
@@ -3069,6 +3069,7 @@
30703070 params.articleFeedbackv5_ct_token = $.cookie( 'clicktracking-session' );
30713071 params.articleFeedbackv5_bucket_id = $.articleFeedbackv5.bucketId;
30723072 params.articleFeedbackv5_cta_id = $.articleFeedbackv5.ctaId;
 3073+ params.articleFeedbackv5_f_link_id = $.articleFeedbackv5.floatingLinkId;
30733074 params.articleFeedbackv5_link_id = $.articleFeedbackv5.submittedLinkId;
30743075 params.articleFeedbackv5_location = $.articleFeedbackv5.inDialog ? 'overlay' : 'bottom';
30753076 }
Index: trunk/extensions/ArticleFeedbackv5/ArticleFeedbackv5.hooks.php
@@ -397,6 +397,7 @@
398398 $tracking = $request->getVal( 'articleFeedbackv5_click_tracking' );
399399 $bucketId = $request->getVal( 'articleFeedbackv5_bucket_id' );
400400 $ctaId = $request->getVal( 'articleFeedbackv5_cta_id' );
 401+ $flinkId = $request->getVal( 'articleFeedbackv5_f_link_id' );
401402 $location = $request->getVal( 'articleFeedbackv5_location' );
402403 $token = $request->getVal( 'articleFeedbackv5_ct_token' );
403404 $ctEvent = $request->getVal( 'articleFeedbackv5_ct_event' );
@@ -404,6 +405,7 @@
405406 $editPage->editFormTextAfterContent .= Html::hidden( 'articleFeedbackv5_click_tracking', $tracking );
406407 $editPage->editFormTextAfterContent .= Html::hidden( 'articleFeedbackv5_bucket_id', $bucketId );
407408 $editPage->editFormTextAfterContent .= Html::hidden( 'articleFeedbackv5_cta_id', $ctaId );
 409+ $editPage->editFormTextAfterContent .= Html::hidden( 'articleFeedbackv5_f_link_id', $flinkId );
408410 $editPage->editFormTextAfterContent .= Html::hidden( 'articleFeedbackv5_location', $location );
409411 $editPage->editFormTextAfterContent .= Html::hidden( 'articleFeedbackv5_ct_token', $token );
410412 $editPage->editFormTextAfterContent .= Html::hidden( 'articleFeedbackv5_ct_event', $ctEvent );
@@ -469,6 +471,7 @@
470472 $version = $wgArticleFeedbackv5Tracking['version'];
471473 $bucketId = $request->getVal( 'articleFeedbackv5_bucket_id' );
472474 $ctaId = $request->getVal( 'articleFeedbackv5_cta_id' );
 475+ $flinkId = $request->getVal( 'articleFeedbackv5_f_link_id' );
473476 $location = $request->getVal( 'articleFeedbackv5_location' );
474477 $token = $request->getVal( 'articleFeedbackv5_ct_token' );
475478 $ctEvent = $request->getVal( 'articleFeedbackv5_ct_event' );
@@ -477,7 +480,7 @@
478481 $trackingId = $ctEvent . '-' . $event;
479482 } else {
480483 $trackingId = 'ext.articleFeedbackv5@' . $version
481 - . '-option' . $bucketId
 484+ . '-option' . $bucketId . $flinkId
482485 . '-cta_' . ( isset( $ctas[$ctaId] ) ? $ctas[$ctaId] : 'unknown' )
483486 . '-' . $event
484487 . '-' . $location;

Status & tagging log