From: stronk7 Date: Mon, 2 Apr 2007 21:51:16 +0000 (+0000) Subject: Disable the "save" button if the file isn't writable. X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=208f08e2d10df60646b9c8788c06db8ab1b984f4;p=moodle.git Disable the "save" button if the file isn't writable. Merged from MOODLE_18_STABLE --- diff --git a/admin/xmldb/actions/main_view/main_view.class.php b/admin/xmldb/actions/main_view/main_view.class.php index b290d722cb..921cb711b5 100644 --- a/admin/xmldb/actions/main_view/main_view.class.php +++ b/admin/xmldb/actions/main_view/main_view.class.php @@ -152,7 +152,7 @@ class main_view extends XMLDBAction { /// The save button if ($dbdir->path_exists && file_exists($key . '/install.xml') && - is_readable($key . '/install.xml') && + is_writeable($key . '/install.xml') && is_writeable($key) && !empty($dbdir->xml_loaded) && !empty($dbdir->xml_changed)) {