From 84f3c8b6cc1060203d807ee65545478ce34f93c4 Mon Sep 17 00:00:00 2001
From: Thomas Mueller <thomas.mueller@tmit.eu>
Date: Thu, 7 Feb 2013 00:49:39 +0100
Subject: [PATCH] show webdav test results in admin section as well

---
 settings/admin.php           |  1 +
 settings/templates/admin.php | 15 +++++++++++++++
 2 files changed, 16 insertions(+)

diff --git a/settings/admin.php b/settings/admin.php
index 4d9685ab92..e256c5fe35 100755
--- a/settings/admin.php
+++ b/settings/admin.php
@@ -31,6 +31,7 @@ $tmpl->assign('entriesremain', $entriesremain);
 $tmpl->assign('htaccessworking', $htaccessworking);
 $tmpl->assign('internetconnectionworking', OC_Util::isinternetconnectionworking());
 $tmpl->assign('islocaleworking', OC_Util::issetlocaleworking());
+$tmpl->assign('isWebDavWorking', OC_Util::isWebDAVWorking());
 $tmpl->assign('backgroundjobs_mode', OC_Appconfig::getValue('core', 'backgroundjobs_mode', 'ajax'));
 $tmpl->assign('shareAPIEnabled', OC_Appconfig::getValue('core', 'shareapi_enabled', 'yes'));
 
diff --git a/settings/templates/admin.php b/settings/templates/admin.php
index 0097489743..8c2b6148a6 100644
--- a/settings/templates/admin.php
+++ b/settings/templates/admin.php
@@ -22,6 +22,21 @@ if (!$_['htaccessworking']) {
 <?php
 }
 
+// is WebDAV working ?
+if (!$_['isWebDavWorking']) {
+	?>
+<fieldset class="personalblock">
+	<legend><strong><?php echo $l->t('Setup Warning');?></strong></legend>
+
+	<span class="securitywarning">
+		<?php echo $l->t('Your web server is not yet properly setup to allow files synchronization because the WebDAV interface seems to be broken.'); ?>
+		<?php echo $l->t('Please double check the <a href=\'%s\'>installation guides</a>.', 'http://doc.owncloud.org/server/5.0/admin_manual/installation.html'); ?>
+	</span>
+
+</fieldset>
+<?php
+}
+
 // is locale working ?
 if (!$_['islocaleworking']) {
 	?>
-- 
GitLab