r68541 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r68540‎ | r68541 | r68542 >
Date:02:47, 25 June 2010
Author:laner
Status:deferred
Tags:
Comment:
Add configuration option to specify the cookie path.
Modified paths:
  • /trunk/extensions/JSBreadCrumbs/JSBreadCrumbs.hooks.php (modified) (history)
  • /trunk/extensions/JSBreadCrumbs/JSBreadCrumbs.php (modified) (history)
  • /trunk/extensions/JSBreadCrumbs/js/BreadCrumbs.js (modified) (history)

Diff [purge]

Index: trunk/extensions/JSBreadCrumbs/JSBreadCrumbs.php
@@ -18,6 +18,7 @@
1919
2020 $wgJSBreadCrumbsMaxCrumbs = 5;
2121 $wgJSBreadCrumbsSeparator = "»";
 22+$wgJSBreadCrumbsCookiePath = "/";
2223
2324 // Sets Credits
2425 $wgExtensionCredits['other'][] = array(
Index: trunk/extensions/JSBreadCrumbs/js/BreadCrumbs.js
@@ -7,6 +7,9 @@
88 if ( typeof wgJSBreadCrumbsSeparator == "undefined" ) {
99 wgJSBreadCrumbsSeparator = "»";
1010 }
 11+ if ( typeof wgJSBreadCrumbsCookiePath == "undefined" ) {
 12+ wgJSBreadCrumbsCookiePath = "/";
 13+ }
1114
1215 var titleState = ( $j.cookie( 'mwext-bc-title' ) || "" ).split( wgJSBreadCrumbsSeparator );
1316 var urlState = ( $j.cookie( 'mwext-bc-url' ) || "" ).split( wgJSBreadCrumbsSeparator );
Index: trunk/extensions/JSBreadCrumbs/JSBreadCrumbs.hooks.php
@@ -20,6 +20,7 @@
2121
2222 $variables['wgJSBreadCrumbsMaxCrumbs'] = $wgJSBreadCrumbsMaxCrumbs;
2323 $variables['wgJSBreadCrumbsSeparator'] = $wgJSBreadCrumbsSeparator;
 24+ $variables['wgJSBreadCrumbsCookiePath'] = $wgJSBreadCrumbsCookiePath;
2425
2526 $vars = array_merge( $vars, $variables );
2627 return true;

Status & tagging log