Tagged Questions
1
vote
1answer
16 views
AngularJS: Highly Dynamic Routing
Hi,
I am currently looking to implement something like this (AngularJS):
$routeProvider
.when('/root/:controllerName/blah/:blahId/blah/:blah', {
templateUrl: ...
3
votes
2answers
17 views
specifying AngularJS controller: benefits using ngController vs. $routeProvider
There are two ways (AFAIK) to associate a controller with a view template/partial: the route specified in $routeProvider and the ngController directive. Especially (but not exclusively) for simple ...
1
vote
0answers
31 views
How to use ASP.NET MVC and AngularJS routing?
I’m working on a new ASP.NET MVC and AngularJS application that is intended to be a collection of SPAs. I’m using the MVC areas concept to separate each individual SPA, and then I’m using AngularJS ...
0
votes
2answers
20 views
angularjs, use a function in the routing as the templateUrl
It's possible to use a function as the templateUrl. The official documentation for $routeProvider states:
templateUrl – {string=|function()=}
$routeProvider official documentation
In ...
1
vote
0answers
16 views
Angular mangles weird URLs
Our legacy website had URLs that looked like
ouroldsite.com/Script?key=val1=val2
These are now 301 redirected to:
ournewsite.com/#!/Script?key=val1=val2
When angular recieves these requests, it ...
0
votes
1answer
16 views
Loading the partial files after the http call inside the controller
I am having a controller and a partial file. The partial file tries to access a variable which was set by the controller. But the issue here is that the controller populates the scope object with the ...
0
votes
1answer
36 views
Passing javascript variables from controller to partial file in AngularJs
I am new to AngularJs. I have put a url value in the scope variable inside a controller. This value should be used in the partial file corresponding to the controller inside a javascript function. How ...
0
votes
0answers
34 views
Incorporating a Angular SPA into an existing web-site. Routing problems
So as a proof of concept, I built a Angular SPA to demonstrate to the rest of my team its potential. They were impressed and have now asked me that I incorporate it into our existing web-site under a ...
0
votes
1answer
27 views
Angular Routing isn't being intercepted
I have the following in my app.js file:
// Declare app level module which depends on filters, and services
var APP = angular.module('DiagsDashboard', ['ngRoute', 'DiagsDashboard.filters',
...
0
votes
1answer
46 views
Couldn't navigate from one page to another
I am new to angularjs...i am trying to navigate from login page to next page using router functionality....My login page is as follows
<body>
<div id='content' ng-app='myApp' ...
0
votes
0answers
20 views
Angular with Rails - Angular template will not load properly
i am learning how to use angularjs routing and templating, and i have come across a problem. I have added the gem in Gemfile, added //= require angular-rails-templates in application.js, and added the ...
0
votes
1answer
37 views
angular routing and templating issue
i am learning how to use angularjs routing and templating, and i have come across a problem. I have added the gem in Gemfile, added //= require angular-rails-templates in application.js, and added the ...
0
votes
1answer
22 views
Offline routing wih angular maks jQuery say operation is insecure
I'm trying to ue Angularjs in my offline application. All files get loaded directly, without a webserver (so from file://[PATH]). This works the first time, but then angular appends #/ to the back of ...
0
votes
1answer
97 views
AngularJS routed page refresh never loads
I'm trying to use AngularJS in a salesforce local hybrid android app, and while a simple test of the angular code works in firefox, when I run it in the Android emulator it loads for a fraction of a ...
0
votes
1answer
38 views
Set radio button state based on a value received from REST in AngularJS
What I would like to achieve is set a radio button's state according to the data retrieved from the server in AngularJS.
What makes this more special is that I need to show a div based on a condition ...
0
votes
2answers
15 views
Pass parameters to controller in defined route?
Say I have an app defined as such:
angular.module('myApp', ['myControllers'])
.config(['$routeProvider', function($routeProvider) {
$routeProvider.when('/', {
templateUrl: ...
0
votes
4answers
45 views
angularjs maintain the scope variable across routes
How do I maintain the model across routes. for eg I have a list of profiles loaded onto the home page. The home page also contains a "load more" action to load more profiles, basically pushing data to ...
0
votes
2answers
60 views
bootstrap carousel does not work correctly using partial file
I am new to bootstrap and AngularJs. I am using bootstrap and Angular Js for my current application. When I use the bootstrap carousel directly inside the index page, the carousel's slide link are ...
1
vote
3answers
36 views
Angularjs route executes twice with particular querystring
I'm developing a SPA AngularJs application, that has to deal with some particular legacy URL's.
I am using the basic $routeProvider that works fine, with one exception: when i invoke a special url ...
0
votes
1answer
18 views
Should resolved objects be tested in routes unit test in Angular?
Currently in routes unit test I'm testing if appropriate controller and template are called, like seen here.
Also, in some routes I have resolved object. I can access them like:
...
0
votes
3answers
33 views
Dynamic routes for angularjs
I want to have a routes that would look like such:
$routeProvider.when('/trial/:extention/:id', {templateUrl: 'partials/quran.html', controller: 'QCtrl'});
$routeProvider.otherwise({redirectTo: ...
0
votes
1answer
67 views
angularJS template url is not loading automatically
It's loading when I type a char in input type="search".
Page is calling 'ajax call' twice. request is fire twice on 'single click' or 'onPageload'
index.Html
This is my html file which has a ...
0
votes
1answer
34 views
Resolve in router is not updating scope in time
Hello there,
I have issue with manipulating with scope variables (with resolve in router) before angular view content is renderer. I am using AngularJS 1.2.16
I have view, where is DIV displayed ...
0
votes
1answer
40 views
AngularJS: multiple edit forms routing?
I have a listing of Requests each with a Request_Type_Id which maps to a feeder list (which could grow as the application evolves). For example, we might have (id, request_type) 1 - Sales Information, ...
1
vote
2answers
35 views
AngularJS: Recommendation on rendering different view when HTTP 404
What I am doing
I am trying to create a service which loads the user budgets for current month. The code looks like
$scope.thisMonthBudgetSummary = function () {
console.log('retrieving ...
1
vote
1answer
42 views
Can we make hidden routes with angularjs?
I want to know if it's possible to make some hidden routes with angularjs, for example I have a category and sub category, in my application I have
.when('/category/new' ,{
controller : ...
3
votes
2answers
227 views
AngularJS: Two Parallel Views, One URL
I'm building a dashboard/control panel app that is basically made up of two tabs (bootstrap) at the root level, called "dispatch" and "admin". Each tab has a good bit of its own multi-tiered ...
0
votes
1answer
97 views
Single Page Application angularJS
I was developing a sample application to learn AngularJs.
There are three links that show up three different templates in the ng-view .
main.html has the three links.
...
0
votes
1answer
59 views
ngRouter/uiRouter preserve controllers when changing view
Is there anyway to preserve route controllers in Angular when using routing?
Everytime I change the view, the old controller is destroyed and a new one created, but I was wondering if there was a way ...
2
votes
2answers
45 views
How to reuse controllers in AngularJs when success locations are different and $location.path('..') is not supported?
Right now the $location service is getting in the way. Suppose one wants to use the same controller for multiple routes, however the expectation is that upon a successful 'save' the destination ...
1
vote
1answer
35 views
AngularJS $location not updated properly when using $routeProvider
I have an Angular JS application with a defaultController which controls the header of the app. Then I have some other controllers one for each view. The views are loaded in the <main>. I load ...
0
votes
0answers
11 views
Routing dynamic Paths recursively in AngularJS
I want to build something like a directory browser with AngularJS. Is is possible to route paths with ng-route? I'd like to parse URLs like this: myapp.com/#/folder1/folder2/.../folderN
2
votes
0answers
57 views
IE favicon disappeared when navigating other page in angular application
I found an issue with angular application.
I have a the location provider setup to use the html5Mode true:
$locationProvider.html5Mode(true);
I noticed that the favicon is disappearing when ...
0
votes
0answers
23 views
AngularJS remembering page scroll location
I have multiple pages of data that lists publications by author. The first page lists all the publications and has infinity-scrolling implemented.
Another page allows you to filter by author, and ...
0
votes
1answer
53 views
AngularJS Routing not doing anything not working
I have following PhoneCat tutorial combined with an angular seed project. Now i come into the problem, i can't get routing to work / load, no errors occur and everything seems fine. Can't even seem to ...
0
votes
1answer
32 views
AngularJS Multi-Level Default Routes
In AngularJS, I wanted to send all my routes to a single controller - so I figured - why set up routing at all?
It seems simpler to get route information with $window.location.pathname.split("/");
...
2
votes
1answer
38 views
Responsability of a controller in AngularJS - More than two views?
I come from the Rails world, where a controller is responsible to do business logic but a single controller can render several views, depending on the action that is supposed to do.
However, and ...
0
votes
1answer
83 views
Routing with controllers in these html pages, is it possible?
I'm new in AngularJS development and I'm actually in front of a problem.
In my index.html I have already many scripts included like that :
<script type="text/javascript" ...
0
votes
0answers
35 views
Angularjs routing manual refresh
I have an SPA anularjs app with a few pages.
Router Provider is configured as follows:
$locationProvider.html5Mode(true);
var path = 'web/partials/views/';
$routeProvider
.when('/', {
...
1
vote
1answer
181 views
AngularJS how to change location path in routeChangeStart event?
in my application I'm using some query string parameters to resolve links for preselecting some data. But this parameters I would like to hide for users. For example I'm using routes like this ...
0
votes
1answer
58 views
AngularJS route does not render the template
I have two controllers and I'm using the AngularJS $routeProvider to load multiple pages. When I click on the link from the first partial to go the second one, the second partial does not render, and ...
0
votes
1answer
159 views
AngularJS: Getting ngRoute working
I'm working on a new Angularjs webapp where I have to use ngRoute. I'm a bit confused first, because routing doesn't work at all in my case – I always end up at index and MainCtrl.
in index.html I've ...
0
votes
1answer
70 views
AngularJS Routing and ng-view issue
Hey everyone I am trying to work through a tutorial for Angularjs, and am stuck on some routing issues.
It seams like the route is actually working but no content is showing up in my section.
here ...
0
votes
2answers
143 views
Problems with AngularJS $location.path
I am having fun and games with a troublesome AngularJS route, so lets see if I can explain this as well as I can.
APP.JS:
app = angular.module("index", []);
app.config(['$routeProvider',
...
0
votes
1answer
31 views
Routing resolve does not work if resource returns error code 400
In my app.js i have:
resolve : {
resetCodeCheckData : function(resource) {
return resource.get().$promise;
}
}
But if ...
0
votes
4answers
64 views
AngualrJS routeProvider routing to the wrong template
I've the following 2 routes in my app.js file, for some reason I don't know when I try to navigate to /clients/new-invoice I see the /clients/:clientID route and template. The only way I can go to the ...
0
votes
1answer
76 views
AngularJS routes not working in Chrome extension
I have an AngularJS app that works fine in the browser when served by 'grunt serve'. However, trying to run the app as a Chrome extensions fails. The initial page (the '/' route) displays, but when I ...
2
votes
3answers
64 views
angularjs using variables in templateUrl
Im trying to use $scope in my templateUrl like this:
app.config(['$routeProvider',
function ($routeProvider) {
$routeProvider.
when('/blog', {
templateUrl: 'themes/{{ ...
0
votes
0answers
90 views
angularjs ui router directive after ui.view loaded
I've got a mixed menu I mean
there is my animation + ui-router animation
html
<ul class="nav navbar-nav">
<li data-ng-class="{ active: $state.includes('index') }"><a ...
0
votes
1answer
36 views
When Arriving at AngularJS-driven site, routed to / instead of actual link
I have a site built with AngularJS. I use $routeProvider to define a bunch of routes. They all work fine when I am in the site already. Let's take the following:
rooturl.com#/services/myservicename
...