diff --git a/inc/html.php b/inc/html.php
index 809db30bdc8d07aea0db1314c5f102852e956464..ee0711b6a3d21280339843df25b4d7a13eac4e3c 100644
--- a/inc/html.php
+++ b/inc/html.php
@@ -449,7 +449,10 @@ function html_revisions($first=0, $media_id = false){
 
     if (!$media_id) print p_locale_xhtml('revisions');
 
-    $form = new Doku_Form(array('id' => 'page__revisions'));
+    $params = array('id' => 'page__revisions');
+    if ($media_id) $params['action'] = media_managerURL(array('image' => $media_id));
+
+    $form = new Doku_Form($params);
     $form->addElement(form_makeOpenTag('ul'));
 
     if (!$media_id) $exists = $INFO['exists'];
diff --git a/inc/media.php b/inc/media.php
index b668e7be2c35ff71e8e6e58b3547bb31a4062a6e..5a1da55cd7d8ddeebb7f7fdf77c3c1a045f65433 100644
--- a/inc/media.php
+++ b/inc/media.php
@@ -110,11 +110,12 @@ function media_metaform($id,$auth,$fullscreen = false){
     // output
     if (!$fullscreen) {
         echo '<h1>'.hsc(noNS($id)).'</h1>'.NL;
-        echo '<form action="'.DOKU_BASE.'lib/exe/mediamanager.php" accept-charset="utf-8" method="post" class="meta">'.NL;
+        $action = DOKU_BASE.'lib/exe/mediamanager.php';
     } else {
-        echo '<form action="'.media_managerURL(array('tab_details' => 'view')).
-            '" accept-charset="utf-8" method="post" class="meta">'.NL;
+        $action = media_managerURL(array('tab_details' => 'view'));
     }
+    echo '<form action="'.$action.'" id="mediamanager__save_meta" accept-charset="utf-8" method="post" class="meta">'.NL;
+
     formSecurityToken();
     foreach($fields as $key => $field){
         // get current value
@@ -150,8 +151,12 @@ function media_metaform($id,$auth,$fullscreen = false){
     }
     echo '<div class="buttons">'.NL;
     echo '<input type="hidden" name="img" value="'.hsc($id).'" />'.NL;
-    if (!$fullscreen) $do = 'do';
-    else $do = 'mediado';
+    if (!$fullscreen) {
+        $do = 'do';
+    } else {
+        echo '<input type="hidden" name="mediado" value="save" />';
+        $do = 'mediado';
+    }
     echo '<input name="'.$do.'[save]" type="submit" value="'.$lang['btn_save'].
         '" title="'.$lang['btn_save'].' [S]" accesskey="s" class="button" />'.NL;
     if (!$fullscreen)
@@ -803,7 +808,8 @@ function media_preview($image, $auth, $rev=false) {
 
     // delete button
     if($auth >= AUTH_DELETE && !$rev){
-        $form = new Doku_Form(array('action'=>media_managerURL(array('delete' => $image))));
+        $form = new Doku_Form(array('id' => 'mediamanager__btn_delete',
+            'action'=>media_managerURL(array('delete' => $image))));
         $form->addElement(form_makeButton('submit','',$lang['btn_delete']));
         $form->printForm();
 
@@ -813,7 +819,8 @@ function media_preview($image, $auth, $rev=false) {
         $form->printForm();
     }
     if($auth >= AUTH_DELETE && $rev){
-        $form = new Doku_Form(array('action'=>media_managerURL(array('image' => $image))));
+        $form = new Doku_Form(array('id' => 'mediamanager__btn_restore',
+            'action'=>media_managerURL(array('image' => $image))));
         $form->addHidden('mediado','restore');
         $form->addHidden('rev',$rev);
         $form->addElement(form_makeButton('submit','',$lang['media_restore']));
diff --git a/lib/exe/ajax.php b/lib/exe/ajax.php
index 8ff0f8edab2cd5afb12a6d27c67771f77200ec9f..59953ddc38d31d1559a2c3f2aa8d3004307b6f10 100644
--- a/lib/exe/ajax.php
+++ b/lib/exe/ajax.php
@@ -224,12 +224,17 @@ function ajax_medialist(){
  * @author Kate Arzamastseva <pshns@ukr.net>
  */
 function ajax_mediadetails(){
-    global $conf;
-    global $NS;
+    global $DEL, $NS, $IMG, $AUTH, $JUMPTO, $REV, $lang, $fullscreen;
+    $fullscreen = true;
+    require_once(DOKU_INC.'lib/exe/mediamanager.php');
 
-    $NS = $_POST['ns'];
-    $image = $_POST['image'];
-    tpl_fileDetails($image, false);
+    if ($_REQUEST['image']) $image = cleanID($_REQUEST['image']);
+    if (isset($IMG)) $image = $IMG;
+    if (isset($JUMPTO)) $image = $JUMPTO;
+    if (isset($REV) && !$JUMPTO) $rev = $REV;
+
+    html_msgarea();
+    tpl_fileDetails($image, $rev);
 }
 
 /**
diff --git a/lib/exe/mediamanager.php b/lib/exe/mediamanager.php
index 46257a9a7b7ae4295f3c5b4969014bdbd0a17f34..77eb2facb86eb0805c99c09573ee3186b7a9a9e4 100644
--- a/lib/exe/mediamanager.php
+++ b/lib/exe/mediamanager.php
@@ -80,7 +80,7 @@
         $JUMPTO = media_metasave($IMG,$AUTH,$_REQUEST['meta']);
     }
 
-    if($IMG && @array_key_exists('save', $_REQUEST['mediado'])){
+    if($IMG && $_REQUEST['mediado'] == 'save') {
         $JUMPTO = media_metasave($IMG,$AUTH,$_REQUEST['meta']);
     }
 
@@ -98,7 +98,7 @@
         }
         if ($res & DOKU_MEDIA_DELETED) {
             $msg = sprintf($lang['deletesucc'], noNS($DEL));
-            if ($res & DOKU_MEDIA_EMPTY_NS) {
+            if ($res & DOKU_MEDIA_EMPTY_NS && !$fullscreen) {
                 // current namespace was removed. redirecting to root ns passing msg along
                 send_redirect(DOKU_URL.'lib/exe/mediamanager.php?msg1='.
                         rawurlencode($msg).'&edid='.$_REQUEST['edid']);
diff --git a/lib/scripts/media.js b/lib/scripts/media.js
index a7574b804bfe6a616e6fec3f6fe92236fa91193c..245519cbc39eddefe68fcf848f7a3c4c107b8c26 100644
--- a/lib/scripts/media.js
+++ b/lib/scripts/media.js
@@ -11,7 +11,7 @@
  * @author Pierre Spring <pierre.spring@caillou.ch>
  */
 (function ($) {
-    var toggle, list, prepare_content, insert, confirmattach, attachoptions, initpopup, updatehide, setalign, setsize, inSet, outSet, media_manager, hasFlash, form_params, list_view, details;
+    var toggle, list, prepare_content, insert, confirmattach, attachoptions, initpopup, updatehide, setalign, setsize, inSet, outSet, media_manager, hasFlash, form_params, list_view, details, update_content;
 
     var media_manager = {
         keepopen: false,
@@ -331,6 +331,7 @@
         if (document.getElementById('media__content')) {
             //popup
             content = $('#media__content');
+            content.html('<img src="' + DOKU_BASE + 'lib/images/loading.gif" alt="..." class="load" />');
 
         } else {
             //fullscreen media manager
@@ -340,6 +341,8 @@
                 //changing namespace
                 $('#mediamanager__layout_detail').empty();
             }
+
+            $('.scroll-container', content).html('<img src="' + DOKU_BASE + 'lib/images/loading.gif" alt="..." class="load" />');
         }
 
         params = '';
@@ -350,19 +353,8 @@
             params = form_params(link)+'&call=medialist';
         }
 
-        $('.scroll-container', content).html('<img src="' + DOKU_BASE + 'lib/images/loading.gif" alt="..." class="load" />');
-
         // fetch the subtree
-        $.post(
-            DOKU_BASE + 'lib/exe/ajax.php',
-            params,
-            function (data) {
-                content.html(data);
-                prepare_content(content);
-                updatehide();
-            },
-            'html'
-        );
+        update_content(content, params);
 
     };
 
@@ -406,7 +398,7 @@
      * @author Kate Arzamastseva <pshns@ukr.net>
      */
     details = function (event) {
-        var link, content;
+        var link, content, params, update_list;
         link = $(this);
 
         event.preventDefault();
@@ -416,9 +408,32 @@
         content = $('#mediamanager__layout_detail');
         $('.scroll-container', content).html('<img src="' + DOKU_BASE + 'lib/images/loading.gif" alt="..." class="load" />');
 
+        params = '';
+
+        if (link[0].search) {
+            params = link[0].search.substr(1)+'&call=mediadetails';
+        } else {
+            params = form_params(link)+'&call=mediadetails';
+        }
+
+        update_content(content, params);
+
+        update_list = (link[0].id == 'mediamanager__btn_delete' || link[0].id == 'mediamanager__btn_restore');
+        if (update_list) {
+            var link1, content1, params1;
+            link1 = $('a.files');
+            params1 = link1[0].search.substr(1)+'&call=medialist';
+            content1 = $('#mediamanager__layout_list');
+            $('.scroll-container', content1).html('<img src="' + DOKU_BASE + 'lib/images/loading.gif" alt="..." class="load" />');
+
+            update_content(content1, params1);
+        }
+    };
+
+    update_content = function (content, params) {
         $.post(
             DOKU_BASE + 'lib/exe/ajax.php',
-            link[0].search.substr(1)+'&call=mediadetails',
+            params,
             function (data) {
                 content.html(data);
             },
@@ -832,9 +847,15 @@
 
         $('#mediamanager__layout_list').delegate('#mediamanager__tabs_files a', 'click', list)
             .delegate('#mediamanager__tabs_list a', 'click', list_view)
-            .delegate('#mediamanager__file_list a', 'click', details);
+            .delegate('#mediamanager__file_list a', 'click', details)
+            .delegate('#dw__mediasearch', 'submit', list);
 
         $('#mediamanager__layout_detail').delegate('#mediamanager__tabs_details a', 'click', details)
-            .delegate('#mediamanager__btn_update', 'submit', list);
+            .delegate('#mediamanager__btn_update', 'submit', list)
+            .delegate('#page__revisions', 'submit', details)
+            .delegate('#page__revisions a', 'click', details)
+            .delegate('#mediamanager__save_meta', 'submit', details)
+            .delegate('#mediamanager__btn_delete', 'submit', details)
+            .delegate('#mediamanager__btn_restore', 'submit', details);
     });
 }(jQuery));