Question

I am using angularjs and it automatically appends

#index.html to url

http://localhost/index.html so the path will look like

http://localhost/index.html#/index.html

when i commented the ng-include wrapped <div ng-include="'temp.html'></div> the url reverted back to localhost/index.html

but as i uncommented the <div ng-include="'temp.html'></div> it reverted back to localhost/index.html#/index.html

so,

  1. why is it happening ?
  2. is there a work-around ? so that i can use ng-include and keep the url intact .

Note : I am not using any routing

Was it helpful?

Solution

There are several bug reports since angularjs 1.1.5 added this problem:

This bug ist fixed in release 1.2.1 which is available for download.

Changeset: https://github.com/angular/angular.js/commit/d4d34aba6efbd98050235f5b264899bb788117df

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top