- Timestamp:
- 2008-03-25 14:01:57 (8 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
FCKeditor/trunk/editor/filemanager/connectors/lasso/upload.lasso
r1565 r1797 57 57 ); 58 58 59 60 59 /*..................................................................... 61 60 Custom tag sets the HTML response. … … 78 77 $__html_reply__ = '\ 79 78 <script type="text/javascript"> 79 (function() 80 { 81 var d = document.domain ; 82 83 while ( true ) 84 { 85 // Test if we can access a parent property. 86 try 87 { 88 var test = window.top.opener.document.domain ; 89 break ; 90 } 91 catch( e ) {} 92 93 // Remove a domain part: www.mytest.example.com => mytest.example.com => example.com ... 94 d = d.replace( /.*?(?:\\.|$)/, "" ) ; 95 96 if ( d.length == 0 ) 97 break ; // It was not able to detect the domain. 98 99 try 100 { 101 document.domain = d ; 102 } 103 catch (e) 104 { 105 break ; 106 } 107 } 108 })() ; 80 109 window.parent.OnUploadCompleted(' + #errorNumber + ',"' 81 110 + string_replace(#fileUrl, -find='"', -replace='\\"') + '","' … … 86 115 /define_tag; 87 116 117 if($CurrentFolder->(Find: '..') || $CurrentFolder->(Find: '\\')); 118 $errorNumber = 102; 119 /if; 88 120 89 121 if($config->find('Enabled')); … … 95 127 Was a file actually uploaded? 96 128 */ 97 file_uploads->size ? $NewFile = file_uploads->get(1) | $errorNumber = 202; 129 if($errorNumber != '102'); 130 file_uploads->size ? $NewFile = file_uploads->get(1) | $errorNumber = 202; 131 /if; 98 132 99 133 if($errorNumber == 0);