diff --git a/res/layout/account_setup_options.xml b/res/layout/account_setup_options.xml
index d2be3e97f..fbfd93059 100644
--- a/res/layout/account_setup_options.xml
+++ b/res/layout/account_setup_options.xml
@@ -1,60 +1,67 @@
-
-
+
-
-
-
-
-
-
-
-
-
-
+ android:layout_width="fill_parent"
+ android:textAppearance="?android:attr/textAppearanceSmall"
+ android:textColor="?android:attr/textColorPrimary" />
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/res/layout/accounts.xml b/res/layout/accounts.xml
index 8394ba5ab..5e5ede108 100644
--- a/res/layout/accounts.xml
+++ b/res/layout/accounts.xml
@@ -8,34 +8,41 @@
android:layout_width="fill_parent"
android:layout_height="fill_parent"
/>
-
-
+
-
-
-
-
+ android:textSize="14sp"
+ android:text="@string/accounts_welcome"
+ android:textColor="?android:attr/textColorPrimary" />
+
+
+
+
+
+
diff --git a/src/com/fsck/k9/mail/store/WebDavStore.java b/src/com/fsck/k9/mail/store/WebDavStore.java
index 226aff13c..be333bcf4 100644
--- a/src/com/fsck/k9/mail/store/WebDavStore.java
+++ b/src/com/fsck/k9/mail/store/WebDavStore.java
@@ -442,18 +442,28 @@ public class WebDavStore extends Store {
String url) throws IOException {
String authPath = "/exchweb/bin/auth/owaauth.dll";
CookieStore cookies = null;
+ String[] urlParts = url.split("/");
+ String finalUrl = "";
+
+ for (int i = 0; i <= 2; i++) {
+ if (i != 0) {
+ finalUrl = finalUrl + "/" + urlParts[i];
+ } else {
+ finalUrl = urlParts[i];
+ }
+ }
/* Browser Client */
DefaultHttpClient httpclient = new DefaultHttpClient();
/* Post Method */
- HttpPost httppost = new HttpPost(url + authPath);
+ HttpPost httppost = new HttpPost(finalUrl + authPath);
/** Build the POST data to use */
ArrayList pairs = new ArrayList();
pairs.add(new BasicNameValuePair("username", username));
pairs.add(new BasicNameValuePair("password", password));
- pairs.add(new BasicNameValuePair("destination", url + "/Exchange/"));
+ pairs.add(new BasicNameValuePair("destination", finalUrl + "/Exchange/"));
pairs.add(new BasicNameValuePair("flags", "0"));
pairs.add(new BasicNameValuePair("SubmitCreds", "Log+On"));
pairs.add(new BasicNameValuePair("forcedownlevel", "0"));