Ticket #1627: 1627.patch

File 1627.patch, 10.9 KB (added by Alfonso Martínez de Lizarrondo, 12 years ago)

Proposed SVN patch

  • sample01.html

     
    4343// Automatically calculates the editor base path based on the _samples directory.
    4444// This is usefull only for these samples. A real application should use something like this:
    4545// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    46 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     46var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    4747
    4848var oFCKeditor = new FCKeditor( 'FCKeditor1' ) ;
    4949oFCKeditor.BasePath     = sBasePath ;
  • sample02.html

     
    3535        // Automatically calculates the editor base path based on the _samples directory.
    3636        // This is usefull only for these samples. A real application should use something like this:
    3737        // oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    38         var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     38        var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    3939
    4040        var oFCKeditor = new FCKeditor( 'FCKeditor1' ) ;
    4141        oFCKeditor.BasePath     = sBasePath ;
  • sample03.html

     
    7878
    7979function ChangeLanguage( languageCode )
    8080{
    81         window.location.href = window.location.pathname + "?" + languageCode ;
     81        document.location.href = document.location.href.replace( /\?.*$/, '' ) + "?" + languageCode ;
    8282}
    8383        </script>
    8484</head>
     
    111111// Automatically calculates the editor base path based on the _samples directory.
    112112// This is usefull only for these samples. A real application should use something like this:
    113113// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    114 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     114var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    115115
    116116var sLang ;
    117117if ( document.location.search.length > 1 )
  • sample04.html

     
    3939
    4040function ChangeLanguage( languageCode )
    4141{
    42         window.location.href = window.location.pathname + "?" + languageCode ;
     42        document.location.href = document.location.href.replace( /\?.*$/, '' ) + "?" + languageCode ;
    4343}
    4444
    4545        </script>
     
    7171// Automatically calculates the editor base path based on the _samples directory.
    7272// This is usefull only for these samples. A real application should use something like this:
    7373// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    74 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     74var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    7575
    7676// Get the toolbar from the URL.
    7777var sToolbar ;
  • sample05.html

     
    4444
    4545function ChangeLanguage( languageCode )
    4646{
    47         window.location.href = window.location.pathname + "?" + languageCode ;
     47        document.location.href = document.location.href.replace( /\?.*$/, '' ) + "?" + languageCode ;
    4848}
    4949
    5050        </script>
     
    7777// Automatically calculates the editor base path based on the _samples directory.
    7878// This is usefull only for these samples. A real application should use something like this:
    7979// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    80 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     80var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    8181
    8282// Get the skin from the URL.
    8383var sSkin ;
  • sample06.html

     
    5151// Automatically calculates the editor base path based on the _samples directory.
    5252// This is usefull only for these samples. A real application should use something like this:
    5353// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    54 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     54var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    5555
    5656var oFCKeditor = new FCKeditor( 'FCKeditor1' ) ;
    5757oFCKeditor.BasePath     = sBasePath ;
  • sample07.html

     
    4343// Automatically calculates the editor base path based on the _samples directory.
    4444// This is usefull only for these samples. A real application should use something like this:
    4545// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    46 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     46var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    4747
    4848var oFCKeditor = new FCKeditor( 'FCKeditor1' ) ;
    4949oFCKeditor.BasePath     = sBasePath ;
  • sample08.html

     
    154154// Automatically calculates the editor base path based on the _samples directory.
    155155// This is usefull only for these samples. A real application should use something like this:
    156156// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    157 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     157var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    158158
    159159var oFCKeditor = new FCKeditor( 'FCKeditor1' ) ;
    160160oFCKeditor.BasePath     = sBasePath ;
  • sample09.html

     
    6868// Automatically calculates the editor base path based on the _samples directory.
    6969// This is usefull only for these samples. A real application should use something like this:
    7070// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    71 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     71var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    7272
    7373var oFCKeditor = new FCKeditor( 'FCKeditor_Basic' ) ;
    7474
  • sample10.html

     
    5050// Automatically calculates the editor base path based on the _samples directory.
    5151// This is usefull only for these samples. A real application should use something like this:
    5252// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    53 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     53var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    5454
    5555var oFCKeditor = new FCKeditor( 'FCKeditor_1' ) ;
    5656oFCKeditor.BasePath     = sBasePath ;
  • sample11_frame.html

     
    4040// Automatically calculates the editor base path based on the _samples directory.
    4141// This is usefull only for these samples. A real application should use something like this:
    4242// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    43 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     43var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    4444
    4545var oFCKeditor = new FCKeditor( 'FCKeditor_1' ) ;
    4646oFCKeditor.BasePath     = sBasePath ;
  • sample12.html

     
    8282// Automatically calculates the editor base path based on the _samples directory.
    8383// This is usefull only for these samples. A real application should use something like this:
    8484// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    85 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     85var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    8686
    8787// The following are the default configurations for the Enter and Shift+Enter modes.
    8888var sEnterMode = 'p' ;
  • sample13.html

     
    8585        // Automatically calculates the editor base path based on the _samples directory.
    8686        // This is usefull only for these samples. A real application should use something like this:
    8787        // oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    88         var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     88        var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    8989
    9090        // Create an instance of FCKeditor (using the target textarea as the name).
    9191        var oFCKeditor = new FCKeditor( 'DataFCKeditor' ) ;
  • sample14.html

     
    4545// Automatically calculates the editor base path based on the _samples directory.
    4646// This is usefull only for these samples. A real application should use something like this:
    4747// oFCKeditor.BasePath = '/fckeditor/' ;        // '/fckeditor/' is the default value.
    48 var sBasePath = document.location.pathname.substring(0,document.location.pathname.lastIndexOf('_samples')) ;
     48var sBasePath = document.location.href.substring(0,document.location.href.lastIndexOf('_samples')) ;
    4949
    5050var oFCKeditor = new FCKeditor( 'FCKeditor1' ) ;
    5151oFCKeditor.BasePath     = sBasePath ;
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy