1
vote
2answers
22 views

Redirect from Angular JS not working for URL with hash '#'

Background of how I am initializing my AngularJS app is here : SCRIPT5022: 10 $digest() iterations reached. Aborting! and redirecting to index.html Summery Problem When I do a window.location = ...
0
votes
1answer
10 views

Angular app routeProvider confused in app mounted on sup path

My single page app is not mounted on the root, so the path to the app is something like http://…/sub/. I took care of the base by adding this to the HTML file: <base href="/sub/"/> My ...
1
vote
2answers
57 views

Routing issue b/w angularjs and expressjs

Express.js routing of /question/ask app.get('/question/ask', function (req, res){ console.log('index.js'); console.log('came to question/:id'); res.render('app'); }); The corresponding ...
0
votes
1answer
28 views

Cross origin requests are only supported for HTTP

I'm trying run this code: <!DOCTYPE html> <html ng-app="myApp"> <head> <title>Exemple 06</title> </head> <body> <!-- Diretiva ng-repeat --> ...
0
votes
1answer
34 views

routing bug in an angularjs app with jQuery

I'm trying to get set up an angularJS app with jQuery and I'm using the angular routing system for urls doing something like the following: var app = angular.module('app', []); ...
0
votes
1answer
42 views

Angular: How can I use different templates for different views?

I've got an AngularJS site. The index.html used to look something like this: ... <div class="layout stuff headers whatever">My awesome header layout</div> <div class="container" ...
0
votes
1answer
59 views

AngularJS redirect a route only on browser's back button

In my AngularJS application I'm redirecting the route to a specific page when the user isn't logged. To do that I'm using a variable on $rootScope. Now I would like to prevent the browser's back ...
0
votes
1answer
41 views

Angularjs: How to create a optional route map param?

On AngularJS 1.1.5, I've got two mapped routes in the form: /category/:name/:article /category/:name I'd like to only have the latest, and route the param :article to a action. This action is ...
0
votes
0answers
29 views

routingProvide not found AngularJs

I am just trying to learn Angular.Js and got stuck here watching a tutorial. I just created a demo App with the following code ... and I am getting an the following error. Any help would be greatly ...
1
vote
2answers
54 views

How to globally resolve a dependency (preload current user from server)

I know I can resolve certain dependencies for a controller based on the route. However, I have a service that I always want to be resolved: The current user. The service basically does a get request ...
2
votes
1answer
49 views

AngularJS How to get additional routes parameter

Is there a way to add extra parameters to the $routeProvider and retrieve this parameters in a directive? I need this because the variable is page specific. I would like to add a parameter pageName ...
1
vote
3answers
49 views

In Angular, is there a way to call code when $routeProvider.otherwise is fired?

I know there is no catchall controller for Angular. E.g.: $routeProvider.otherwise({ controller: 'CatchAllCtrl' }); However, is there a way to call some code if $routeProvider.otherwise is ...
0
votes
1answer
62 views

Do angular views work when a site is served from the local file system?

I'm using angular to develop an application. I'm developing off my local file system, on Windows. However, when I enable angular-route.js, whenever I hit index.html with my browser, it instead goes ...
0
votes
3answers
47 views

$location.path doesn't change in a factory with AngularJS

My factory looks like: 'use strict'; angular.module('myApp') .factory('httpInterceptor',['$q','$location', '$rootScope', function($q, $location, $rootScope){ return { response: ...
1
vote
0answers
36 views

AngularJS: remembering state/setup of complex views with routes

In a single page application, is there a way of switching back and forth to an AngularJS route and to display it back in the same state as it was shown before? Usually this would be implemented by ...
0
votes
0answers
118 views

adding angularjs to spring mvc

i am trying to add angularjs to my spring 3.0 project. I am not able to add angularjs as front end technology for my project. here is my web.xml file. <?xml version="1.0" encoding="UTF-8"?> ...
0
votes
1answer
45 views

Request url when html5Mode(true)

I have enabled $locationProvider.html5Mode(true). However I have django as backend. On /logout/ I need to ask the url directly to the server as if $locationProvider.html5Mode(false) or simply ...
0
votes
1answer
40 views

AngularJS. ui-view included in ng-view

I try to use ui-view included in ng-view, and it does not work. But when I use ui-view near ng-view, ui-view work and in ng-view. Don't work: <div ng-view id="body-div"></div> Work: ...
0
votes
1answer
156 views

Angularjs routing and html5

I have some routes for my application: $routeProvider. when('/user', {templateUrl: 'user/partials/userlist.html', controller: 'userListController'}). ...
0
votes
2answers
64 views

ngClick on anchor tags causing problems in Angular

I've got ngClick directives on the anchors tags inside my main navigation, to make the menu "disappear" off canvas after clicking it: <a href="/#/profile" ng-click="showNav = false"> It's ...
0
votes
1answer
335 views

AngularJS 1.2.0: Lazy load controllers and templates

I am newbie to AngularJS. I am using the following code to achieve the lazy load dependency. https://github.com/matys84pl/angularjs-requirejs-lazy-controllers/ This was working great with 1.0.7, ...
0
votes
1answer
45 views

How to pass objects into angular.js directives? Interpolated argument appears to be serialised

I'm trying to pass a JavaScript object into an angular directive. I'm invoking it like this: <thing-badge thing="{{thing}}"></thing> The directive looks something like this: ...
0
votes
1answer
47 views

Angular routing with a star doesn't seem to work

The angular docs say: path can contain named groups starting with a colon (:name). All characters up to the next slash are matched and stored in $routeParams under the given name when the ...
0
votes
0answers
68 views

Dynamic routing with dynamic controllers in AngularJS

I am currently using require.js and angular. Since I have a very long list of custom views, each for a different task, I've cooked up a way of including them dynamically using requirejs. First a ...
2
votes
1answer
151 views

How to check for the existence of a module without an error being raised?

In Angular 1.2, ngRoute is a separate module so you can use other community routers like ui.router instead. I'm writing an open-source module that aims to work for multiple different router ...
0
votes
1answer
68 views

Google bar chart won't show up inside ng-view html partials

Given the code below which I copy-pasted from Google Charts, (I've just removed the html, head and body tags). This code performs really well if I simply add it inside my index.html page, the bar ...
0
votes
2answers
69 views

server-side changes for $locationProvider.html5Mode(true);

server code: app.get('/', function(req, res){ console.log('executed "/"') res.render('home'); }); app.get('/partials/:name', function (req, res) { console.log('executed partials:name'); ...
0
votes
1answer
69 views

How to get rid of `/#/` in url when using Angularjs?

using ng-view and myApp.config(['$routeProvider', function($routeProvider) { $routeProvider. when('/', { templateUrl: '/partials/home', controller: 'homePage' }). ...
0
votes
1answer
45 views

AngularJS route without slash

in AngularJS can I set up a style route like this: http://www.mydomain.com/title-and-more-irrelevant-text-123456-category.html where '123546' is an indentifier ? with: ...
0
votes
1answer
90 views

IIS URL rewrite module with angularJS does not work

I have a single page webapp where any request that begins with request for e.g. http://localhost/appname/request* , the home page is sent back to the client using IIS URL rewrite module. When Angular ...
1
vote
2answers
196 views

Force AngularJS to reload a route although option reloadOnSearch is set to false

In the route configuration of my AngularJS application most of the routes are defined with the option reloadOnSearch set to false as most of the time a page should not reload when search parameter ...
0
votes
2answers
55 views

Does AngularJS have required route segments?

I've got routing that looks like this: .when "/:locale", templateUrl: "/views/index.html" ... .otherwise redirectTo: "/en" The issue is that the first route also matches /. Is there a way to add ...
0
votes
1answer
58 views

getting data via $.ajax how can i do it the “angular” way. Does $http replace $.ajax

here is my code. .state("dynamic", { url: "/:name", controller : 'AppHomeCtrl', templateUrl: function (params){ var myURL = params.name + '.html'; ...
0
votes
1answer
59 views

AngularJs routing issue

I have some problem with angularjs routing. My goal is to append different view depending on the path. I want to implement this using different ng-apps in one html document like this: <body> ...
0
votes
2answers
75 views

AngularJS and IE9 page refresh issue

My single page angularjs application seems to work fine in IE9+ until you edit an object and reload the page. If you modify a field (change Name from "You" to "Me") then press save the server gets the ...
3
votes
2answers
162 views

AngularJS change route without pushing a history state

I'm working on an AngularJS app that has a catch all route (eg, .when('/:slug', {...)) which is necessary to support legacy url formats from a previous (non-angular) version of the app. The controller ...
0
votes
1answer
97 views

AngularJS - Adding class to $routeProvider placeholder links

A follow up to the answer provided here: AngularJS - Changing a query param term within $routeProvider? When using route params, is it possible to set an 'active' class to the element or it's parent ...
0
votes
2answers
115 views

Angularjs routing issue, controller not loading

I have 4 files: index.html logic.js controller.js homepage.html index.html <html ng-app="sample"> <head> <script src="angular.js"></script> </head> <body> ...
0
votes
1answer
114 views

angularjs - After changing views using routing the jquery elements doesn`t get rendered

My issue is that after changing views using routing, the jquery components in my page doesn´t get rendered. I have customized ui components like dropdowns that are not being processed. I saw this ...
2
votes
1answer
61 views

prevent re initialization of controller on $location.path()

I am working on a application where I have to insert a back navigation link to main page from details page. Controller for both views are different. I am using $location.path('/') to navigate back to ...
0
votes
1answer
94 views

Route provider cannot access controllers definitions

I am trying to learn the route features of angularJS, but what I have happened so far doesn't work. If I ever click Load, Display, or Play (in my example: the links to possible action urls) then ...
2
votes
2answers
239 views

Angularjs routing with django's urls

I am using AngularJS for my front-end and Django as a back-end. I am doing very simple things at the back-end so I have not considered using tastypie. The problem where I am stuck is the ...
1
vote
1answer
110 views

method overloading \ overriding in AngularJS

I have a scenario, i which I have a share button, I have a container controller, called metaCtrl, which is on the html tag. And also inner controllers. I have a share button, that calls the ...
1
vote
4answers
551 views

AngularJS | handle routing before they load

I wish to create a simple authentication check for my routes by external service. I define the access requirements on the route object: $routeProvider .when('/', { templateUrl: ...
0
votes
1answer
176 views

angularjs $routeProvider does not include views (unknow provider)

I'm having trouble finding out why ngRouts doesn't include the views i have set. When i look at the javascript console i do get the following error. Error: unknown provider. I looked that up and ...
2
votes
1answer
88 views

ngGrid not displayed when used with route provider

Below is my HTML and the code to do a web service call and display the data in ngGrid. The problem is with the route provider, I'm not being able to show the grid in my separate view, but if I do the ...
0
votes
1answer
121 views

How to redirect in AngularJS without rendering template

I'm trying to redirect to an external page from my AngularJS file if the user enter a special url, for instance /test. I have gotten this to work in multiple different ways but all the different ways ...
1
vote
2answers
305 views

Is there a way to preload templates and controllers when using AngularJS routing?

After the Angular app is loaded I need some of the templates to be available without a network connection. Something like this would be ideal: $routeProvider .when('/p1', { controller: ...
0
votes
0answers
94 views

Angular-ui-router : Extend new state

Recently, I started try AngularJS, but I have some problem about ui-router, I have some requirement about dynamic extend router table, for example : Lets start at home router like below ...
0
votes
1answer
136 views

Sharing a webservice's data across controllers in AngularJS

I have 2 big issues with an Angular app, I'm completely stuck and hoping someone out there can help me. My method of sharing data from a web-service out to multiple controllers is flawed and I don't ...

15 30 50 per page