Skip to content

Commit cbd5252

Browse files
committed
Fix issue on servers that can't redirect to proper url. add a / to path when it doesn't end by this and not index.html
1 parent 09038e5 commit cbd5252

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

index.html

+12-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,19 @@
77
<link rel="stylesheet" type="text/css" href="css/wuala_style-all.min.css"/>
88
<link rel="stylesheet" type="text/css" href="css/wuala_theme.css"/>
99
<link rel="stylesheet" type="text/css" href="css/main.css"/>
10-
10+
<script>
11+
function loaded(){
12+
if ((-1 == location.pathname.indexOf("index.html")) && (location.pathname[location.pathname.length-1] != "/"))
13+
{
14+
//redirect from javascript poor host may not be able to this properly
15+
var url = location.origin + location.pathname + "/" + location.search;
16+
window.location = url;
17+
}
18+
init();
19+
}
20+
</script>
1121
</head>
12-
<body onload="init()" class="metro">
22+
<body onload="loaded()" class="metro">
1323
<div id="navigation_bar" class="large-11 columns"></div>
1424
<div id="browsing"></div>
1525
<div id="window_popup_id"></div>

0 commit comments

Comments
 (0)