Index: t3lib/class.t3lib_tceforms.php =================================================================== --- t3lib/class.t3lib_tceforms.php (revision 2530) +++ t3lib/class.t3lib_tceforms.php (working copy) @@ -2060,7 +2060,8 @@ 'style' => isset($config['selectedListStyle']) ? ' style="'.htmlspecialchars($config['selectedListStyle']).'"' : ' style="'.$this->defaultMultipleSelectorStyle.'"', 'info' => $info, 'thumbnails' => $thumbsnail, - 'readOnly' => $disabled + 'readOnly' => $disabled, + 'alert' => $PA['fieldChangeFunc']['alert'] ); $item.= $this->dbFileIcons($PA['itemFormElName'],'db',implode(',',$tempFT),$itemArray,'',$params,$PA['onFocus'],$table,$field,$row['uid']); @@ -3215,25 +3216,26 @@ $rOnClickInline = 'inline.revertUnique(\''.$objectPrefix.'\',null,\''.$uid.'\');'; } } - $aOnClick='setFormValueOpenBrowser(\''.$mode.'\',\''.($fName.'|||'.$allowed.'|'.$aOnClickInline).'\'); return false;'; + $refresh = $params['alert']? "1" : "0"; + $aOnClick='setFormValueOpenBrowser(\''.$mode.'\',\''.($fName.'|||'.$allowed.'|'.$aOnClickInline.'||||'.$refresh).'\'); return false;'; $icons['R'][]=''. 'backPath,'gfx/insert3.gif','width="14" height="14"').' border="0" '.t3lib_BEfunc::titleAltAttrib($this->getLL('l_browse_'.($mode=='file'?'file':'db'))).' />'. ''; } if (!$params['dontShowMoveIcons']) { if ($sSize>=5) { - $icons['L'][]=''. + $icons['L'][]=''. 'backPath,'gfx/group_totop.gif','width="14" height="14"').' border="0" '.t3lib_BEfunc::titleAltAttrib($this->getLL('l_move_to_top')).' />'. ''; } - $icons['L'][]=''. + $icons['L'][]=''. 'backPath,'gfx/up.gif','width="14" height="14"').' border="0" '.t3lib_BEfunc::titleAltAttrib($this->getLL('l_move_up')).' />'. ''; - $icons['L'][]=''. + $icons['L'][]=''. 'backPath,'gfx/down.gif','width="14" height="14"').' border="0" '.t3lib_BEfunc::titleAltAttrib($this->getLL('l_move_down')).' />'. ''; if ($sSize>=5) { - $icons['L'][]=''. + $icons['L'][]=''. 'backPath,'gfx/group_tobottom.gif','width="14" height="14"').' border="0" '.t3lib_BEfunc::titleAltAttrib($this->getLL('l_move_to_bottom')).' />'. ''; } @@ -3261,7 +3263,7 @@ 'backPath,'gfx/insert5.png','width="14" height="14"').' border="0" '.t3lib_BEfunc::titleAltAttrib(sprintf($this->getLL('l_clipInsert_'.($mode=='file'?'file':'db')),count($clipElements))).' />'. ''; } - $rOnClick = $rOnClickInline.'setFormValueManipulate(\''.$fName.'\',\'Remove\'); return false'; + $rOnClick = $rOnClickInline.'setFormValueManipulate(\''.$fName.'\',\'Remove\');'.$params['alert'].'return false'; $icons['L'][]=''. 'backPath,'gfx/group_clear.gif','width="14" height="14"').' border="0" '.t3lib_BEfunc::titleAltAttrib($this->getLL('l_remove_selected')).' />'. ''; Index: typo3/class.browse_links.php =================================================================== --- typo3/class.browse_links.php (revision 2530) +++ typo3/class.browse_links.php (working copy) @@ -1014,7 +1014,14 @@ focusOpenerAndClose(close); '; } - + if($pArr[8]){ + $JSrefresh = ' + p = parent.window.opener; + if(confirm(p.TBE_EDITOR.labels.onChangeAlert) && p.TBE_EDITOR.checkSubmit(-1)){ + p.TBE_EDITOR.submitForm() + }; + '; + } $JScode.=' var elRef=""; var targetDoc=""; @@ -1051,6 +1058,7 @@ function addElement(elName,elValue,altElValue,close) { // if (parent.window.opener && parent.window.opener.setFormValueFromBrowseWin) { parent.window.opener.setFormValueFromBrowseWin("'.$pArr[0].'",altElValue?altElValue:elValue,elName); + '.$JSrefresh.' focusOpenerAndClose(close); } else { alert("Error - reference to main window is not set properly!"); @@ -2392,4 +2400,4 @@ } -?> \ No newline at end of file +?>