Ticket #1690: FCKeditorSkin.body.patch.php

File FCKeditorSkin.body.patch.php, 808 bytes (added by Justin McCormick, 13 years ago)

Proposed fix to the problem

Line 
1--- FCKeditorSkin.body.php      2007-12-21 09:17:41.000000000 -0600
2+++ FCKeditorSkin.body.fixed.php        2007-12-21 09:16:41.000000000 -0600
3@@ -231,7 +231,15 @@
4                 }
5             }
6             //see ticket 1386 why it is commented
7-            //$u .= $nt->getFragmentForURL();
8+                       /*
9+                        * Strictly commenting out the following code caused issues with urls structed as
10+                        * only fragments, ie "[[#Anchor|Link]]" would become [[|Link]].  By changing it
11+                        * to check for the Partial URL, it allows the original fix to still be valid but
12+                        * removing the issues it caused with same-page anchors.
13+                        */
14+                       if( $nt->getPartialUrl() == '' ) {
15+                               $u .= $nt->getFragmentForURL();
16+                       }
17         }
18         if ( $text == '' ) {
19             $text = htmlspecialchars( $nt->getPrefixedText() );
© 2003 – 2020 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy