0

I am developing an Angular 1.6 app and using Angular UI-Router.

In my config.router.js file I have a state:

$stateProvider.state('myapp.edit', {
                    url: '/edit/:id',
                    templateUrl: 'views/actions/edit.html',
                    controller: ['$http','$rootScope',function( $http, $rootScope){
                            $rootScope.displaySideBar = true;

                        }]

                    });

In the application layout file layout.html file I have included navbar navbar.html file using data-ng-include

<div data-ng-include=" 'views/partials/navbar.html' "></div>

But when I run the application and check the browser console its checking for myapp/edit/views/partials/navbar.html instead of myapp/views/partials/navbar.html . The state url is getting prepended while performing ng-include and ending up in 404 only in IE. In other browsers its working fine.

Can somebody kindly help me on this.

2
  • What is the url for myapp state? Commented Jul 28, 2017 at 11:21
  • It is '/myapp' . Commented Jul 28, 2017 at 11:23

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.