Changeset 2685 for trunk/phpgwapi


Ignore:
Timestamp:
05/03/10 10:08:55 (14 years ago)
Author:
rodsouza
Message:

Ticket #1058 - Forçando a utilização do 'FQDN' no 'xconnector.js'.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/phpgwapi/js/tools/xconnector.js

    r2642 r2685  
    303303                        if ( _argv.path && ( typeof _argv.path == 'string' ) ) 
    304304                        { 
    305                                 if ( _argv.path.indexOf('/') != 0 ) 
    306                                         _argv.path = '/' + _argv.path; 
    307  
    308                                 if ( _argv.path.lastIndexOf('/') != ( _argv.path.length - 1) ) 
     305                                var host = window.location.protocol + "//" + window.location.host; 
     306 
     307                                if ( _argv.path.indexOf( host ) != 0 && _argv.path.indexOf( '/' ) != 0 ) 
     308                                        _argv.path = host + '/' + _argv.path; 
     309 
     310                                if ( _argv.path.lastIndexOf( '/' ) != ( _argv.path.length - 1 ) ) 
    309311                                        _argv.path += '/'; 
    310312 
Note: See TracChangeset for help on using the changeset viewer.