Changeset 1694 for sandbox/filemanager/inc/class.uifilemanager.inc.php
- Timestamp:
- 11/23/09 10:58:52 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sandbox/filemanager/inc/class.uifilemanager.inc.php
r1693 r1694 54 54 var $current_config; 55 55 var $goto_x; 56 var $to dir;56 var $to; 57 57 var $changedir; // for switching dir. 58 58 var $cdtodir; // for switching dir. … … 79 79 var $file; // FIXME WHERE IS THIS FILLED? 80 80 var $sortby; 81 var $messages = array();81 var $messages; 82 82 var $show_upload_boxes; 83 83 … … 86 86 function uifilemanager() 87 87 { 88 // error_reporting(8); 88 $this->messages = &$_SESSION['phpgw_info']['filemanager']['user']['messages']; 89 89 90 $GLOBALS['phpgw']->browser = CreateObject('phpgwapi.browser'); 90 91 … … 124 125 'sortby' => array('sortby' => ''), 125 126 'messages' => array('messages' => ''), 126 'show_upload_boxes' => array('show_upload_boxes' => '') 127 'show_upload_boxes' => array('show_upload_boxes' => ''), 128 'to' => array('to' => '') 129 127 130 ); 128 131 … … 591 594 foreach($this->messages as $msg) 592 595 { 593 $messages.='<p>'.$msg.'</p>'; 594 } 595 } 596 596 $messages.='<span>'.$msg.'</span>'; 597 } 598 } 599 $this->messages = NULL; 600 597 601 $vars[messages]=$messages; 598 602 … … 696 700 } 697 701 $link=$this->encode_href('/index.php','menuaction=filemanager.vfs_functions.setRestricted','file='.$files['name'].'&path='.$this->path); 698 $minibar_data = '<img id="restrict_'.$files['name'].'" onClick=" cExecute(\''.$link.'\',setRestricted)" alt="'.lang("mark as restricted").'" title="'.lang("mark as restricted").'" src="'.$image.'">';702 $minibar_data = '<img id="restrict_'.$files['name'].'" onClick="setRestricted(\''.$link.'\')" alt="'.lang("mark as restricted").'" title="'.lang("mark as restricted").'" src="'.$image.'">'; 699 703 } 700 704 … … 1102 1106 function moveTo() 1103 1107 { 1104 if(!$this->to dir)1108 if(!$this->to) 1105 1109 { 1106 1110 $this->messages[] = lang('Error:').lang('Could not move file because no destination directory is given ', $this->disppath.'/'.$file); … … 1114 1118 if($this->bo->vfs->mv(array( 1115 1119 'from' => $file, 1116 'to' => $this->to dir. '/' . $file,1120 'to' => $this->to . '/' . $file, 1117 1121 'relatives' => array(RELATIVE_ALL, RELATIVE_NONE) 1118 1122 ))) 1119 1123 { 1120 1124 $moved++; 1121 $this->messages[]=lang('Moved %1 to %2', $this->disppath.'/'.$file, $this->to dir.'/'.$file);1125 $this->messages[]=lang('Moved %1 to %2', $this->disppath.'/'.$file, $this->to.'/'.$file); 1122 1126 } 1123 1127 else 1124 1128 { 1125 $this->messages[] = lang('Error:').lang('Could not move %1 to %2', $this->disppath.'/'.$file, $this->to dir.'/'.$file);1129 $this->messages[] = lang('Error:').lang('Could not move %1 to %2', $this->disppath.'/'.$file, $this->to.'/'.$file); 1126 1130 } 1127 1131 } … … 1140 1144 function copyTo() 1141 1145 { 1142 if(!$this->to dir)1146 if(!$this->to) 1143 1147 { 1144 1148 $this->messages[] = lang('Error:').lang('Could not copy file because no destination directory is given ', $this->disppath.'/'.$file); … … 1151 1155 if($this->bo->vfs->cp(array( 1152 1156 'from' => $file, 1153 'to' => $this->to dir. '/' . $file,1157 'to' => $this->to . '/' . $file, 1154 1158 'relatives' => array(RELATIVE_ALL, RELATIVE_NONE) 1155 1159 ))) 1156 1160 { 1157 1161 $copied++; 1158 $this->messages[] = lang('Copied %1 to %2', $this->disppath.'/'.$file, $this->to dir.'/'.$file);1162 $this->messages[] = lang('Copied %1 to %2', $this->disppath.'/'.$file, $this->to.'/'.$file); 1159 1163 } 1160 1164 else 1161 1165 { 1162 $this->messages[] = lang('Error:').lang('Could not copy %1 to %2', $this->disppath.'/'.$file, $this->to dir.'/'.$file);1166 $this->messages[] = lang('Error:').lang('Could not copy %1 to %2', $this->disppath.'/'.$file, $this->to.'/'.$file); 1163 1167 } 1164 1168 } … … 1531 1535 return; 1532 1536 } 1533 $_SESSION['debug'][] = $ls_array;1534 1537 if($ls_array[0]['mime_type']) 1535 1538 {
Note: See TracChangeset
for help on using the changeset viewer.