diff --git a/apps/calendar/templates/calendar.php b/apps/calendar/templates/calendar.php
index 7e767e367324ef006152cc0d85e384a6c2f1e117..19c9a4d8d765eb149a74f270d22deb09d0738f30 100755
--- a/apps/calendar/templates/calendar.php
+++ b/apps/calendar/templates/calendar.php
@@ -19,7 +19,7 @@
 				var missing_field_totime = '<?php echo addslashes($l->t('To Time')) ?>';
 				var missing_field_startsbeforeends = '<?php echo addslashes($l->t('The event ends before it starts')) ?>';
 				var missing_field_dberror = '<?php echo addslashes($l->t('There was a database fail')) ?>';
-				var totalurl = '<?php echo OCP\Util::linkToAbsolute('calendar', 'caldav.php'); ?>/calendars';
+				var totalurl = '<?php echo OCP\Util::linkToAbsolute('remote.php', 'caldav'); ?>/calendars';
 				var firstDay = '<?php echo (OCP\Config::getUserValue(OCP\USER::getUser(), 'calendar', 'firstday', 'mo') == 'mo' ? '1' : '0'); ?>';
 				$(document).ready(function() {
 				<?php