Example UI Index
Welcome make yourself at home.
',
controller: PageIndex
});
});
diff --git a/example/www_static/js/example-app.js b/example/www_static/js/example-app.js
index 17bb47b..649eb9c 100644
--- a/example/www_static/js/example-app.js
+++ b/example/www_static/js/example-app.js
@@ -1,22 +1,22 @@
'use strict';
-
document.title = 'FF-Spa-Loader Example';
-$('html').attr('ng-app', 'exampleUI');
-$('html').attr('lang', 'en');
+
+var serverUrl = window.FFServerUrl;
+console.log('FF provided serverUrl: '+serverUrl);
$(document.createElement('div')).attr('id', 'wrapper').appendTo($('body'));
-$(document.createElement('div')).attr('ng-include', '\'/example-ui/thtml/layout/header\'').appendTo($('#wrapper'));
+$(document.createElement('div')).attr('ng-include', '\''+serverUrl+'/example-ui/thtml/header\'').appendTo($('#wrapper'));
$(document.createElement('div')).attr('id', 'page-wrapper').appendTo($('#wrapper'));
$(document.createElement('div')).attr('id', 'container-fluid').attr('ng-view', '').appendTo($('#page-wrapper'));
-$(document.createElement('div')).attr('ng-include', '\'/example-ui/thtml/layout/footer\'').appendTo($('body'));
+$(document.createElement('div')).attr('ng-include', '\''+serverUrl+'/example-ui/thtml/footer\'').appendTo($('body'));
var pageRouteInit = [];
-angular.module('exampleUI', ['ngRoute']).
- config(['$routeProvider', '$locationProvider', function($routeProvider, $locationProvider) {
- for (var i = 0; i < pageRouteInit.length; i++) {
- pageRouteInit[i]($routeProvider, $locationProvider);
- }
- $routeProvider.otherwise({ redirectTo: '/example-ui' });
- $locationProvider.html5Mode({enabled: true, requireBase: false});
- }]);
+angular.module('exampleUI', ['ngRoute']).config(
+ ['$routeProvider', '$locationProvider', function
+ ($routeProvider, $locationProvider) {
+
+ pageRouteInit.forEach(function(init) { init($routeProvider, $locationProvider); });
+ $routeProvider.otherwise({ redirectTo: '/example-ui' });
+ $locationProvider.html5Mode({enabled: true, requireBase: false});
+}]);
diff --git a/example/www_views/index.ejs b/example/www_views/index.ejs
index 03c00a4..9a90080 100644
--- a/example/www_views/index.ejs
+++ b/example/www_views/index.ejs
@@ -1,17 +1,17 @@
-
+