Tagged Questions
0
votes
0answers
2 views
Cordova / AngularJS / Ionic: Check if online and domain reachable
I'm developing an app where I want to download content (JSON) dynamically from my server. Before the download gets started I want to check if the device is online and my server is reachable.
Using ...
0
votes
0answers
10 views
Angular JS no-repeat with background images not working
I'm new to Angular.js (more of a CSS/jQuery guy) and I can't work out why my ng-repeat isn't working; I've done all the video tutorials on CodeSchool and thought I had the basics behind Angular -down- ...
0
votes
1answer
20 views
How to append in Json String in AngularJS
So this is my Json String
{
"method_name": "WSP.CC.GET.CARRIER.INFO",
"calling_class": "com.fwdco.webservice.ScorpeoWebService",
"error_code": "0",
"contact_info": [
...
0
votes
1answer
12 views
Is there a dynamic module loader for AngularJS that uses convention over configuration?
Most dynamic modules that I can find are not really dynamic and are actually lazy loaders, as they mostly require you to register what you want loaded in config files and registers.
I am looking for ...
0
votes
1answer
21 views
Angular routing for front end app
I know this is a very basic question, but can't seem to get everything hooked up right - I'm trying to get a handle on front end routing, using an Angular/Sinatra app. My app isn't hitting the right ...
0
votes
1answer
17 views
angular Orderby Date not sorting correctly
I have some json data I get from my server that has a date field formatted like "StartDateTime":"2014-09-04T18:14:26Z"
i create a table as follows:
<table class="table table-condensed ...
1
vote
2answers
16 views
ng hide, how to conditionally show something in angular with url extension
I am testing and app and would like to do something very simple. I would like to hide a div and only show it in the browser when an extension is added to the url. For example:
<div ng-hide="true" ...
-2
votes
2answers
22 views
“Object doesn't support property or method 'push'” [duplicate]
I'm trying to add new value into existing JSON object in AngularJS but I'm getting this error message:
"Object doesn't support property or method 'push'"
Here is my code:
$scope.addStatus = ...
0
votes
1answer
15 views
Turn off (Ignore) placeholder attribute in html text/search elements
I would like to be able to turn on/off the placeholder from my search boxes if possible.
<input type="text" placeholder="Enter name" />
<input type="search" placeholder="Type to search" ...
0
votes
0answers
9 views
setting forms in ngrepeat pristine
I have a a set of forms generated using ng-repeat, and I need to have a single button that sets them all to pristine. The quintessential example of the $setPristine() is here: ...
0
votes
0answers
8 views
Angular computed observable on child object
Im trying to make a small test with angular but got some problems I cant get it to work
How do I make an observable in a child object in angular?
The problem with this code is that when I load a saved ...
0
votes
4answers
29 views
How can I push a null value into the start of an array?
I have this code that fetches data and puts it into an array:
this.$httpGetTest(this.test.testId)
.success(function (data: ITestQuestion[]) {
self.test.qs = data;
});
...
0
votes
1answer
21 views
variables not hoisting as expected in angularjs
I've been following John Papa and his angular style guide recommendations. I like the idea of putting all of your variables and methods available to the view up at the top of the controller and rely ...
0
votes
0answers
8 views
How to get rid of blocks nested too deeply while using jshint with grunt?
Some one please help me to fix a warning in grunt.
I am using fallowing condition in my project and i am getting a warning,
Blocks are nested too deeply<5>.
var chartGuideLines = function() {
...
0
votes
1answer
11 views
AngularJs filter:$viewValue is not handling html escaping
If you type A in the box, you'll see:
Alabama is missing the text in the bracket
Alaska is fine
Arizona displays fine but once selected shows as < and
>
Any idea on how to prevent ...
0
votes
3answers
24 views
AngularJS, $routeProvider
I'm trying to learn how routes work in AngularJS to make a little application that allows users to login and write comments in a live feed. However the whole concept of routes is a bit blurry for me ...
0
votes
1answer
27 views
Elegantly hiding the navbar in a single page MEAN app.
I have an app that has a navbar on everypage, so I factored it out into index.jade that inherits from my layout.jade file. This is fine for 99% of my app.
The only place it runs into issues is on ...
0
votes
2answers
25 views
AngularJS text input with ng-model but needs default value not working with value= or ng-init=
I have an account form with many inputs. One of them below:
<input class="form-control " placeholder="First Name" type="text" ng-model="account.first_name" ...
-1
votes
1answer
13 views
ng pattern which allows alphnumeric but without spaces for input tag in angular js
am using the patterns like "/[a-zA-Z0-9][^\s]/" and "/\s/" but no one is working. can you give any solution for this "ng pattern for input tag and which allows oly alphanumeric but it does not allow ...
3
votes
3answers
51 views
How should I reference services in my controller functions without using scope?
After reading several articles on avoiding scope soup and referencing the Google Guidelines for building controllers I have been left with one burning question. How should I reference my injected
...
0
votes
3answers
31 views
Set Width of HTML element at runtime in AngularJS
I need to set the width of an HTML element at runtime from my controller in AngularJS. My controller is defined within my directive. I know that I need to set the width of the first ul element within ...
0
votes
1answer
13 views
Angular: Nested Callback with HTTP Query
I have such a problem (structured english)
GET HTTP Resource
FOR every data item received do
GET another HTTP Resource
Alter the original data from the outer loop with data from the ...
0
votes
0answers
13 views
How to Interpolate expression with async data in angular.js
I try to implement a basic search feature and i wonder how to fill an interpolated expression with async data. In my case i want to show the amount of total items right next to the tab text.
As my ...
0
votes
1answer
31 views
AngularJS - make the dropdown option with selected attribute the default
I have a select like:
<select ng-model="formData.num" id="num" name="num">
<option value="1">1</option>
<option value="2" selected="selected">2</option>
...
0
votes
0answers
23 views
Is There a better way to optimize my directive?
my code is working, but i'm wondering if there is a better way to improve it.
I have a modal dialog in AngularJS, that i select multiple users.
Openig the modal:
$scope.openModal = function () {
...
0
votes
0answers
16 views
Data not rendering
I have a website that displays data in a list that is filterable. When a filter is applied I'd like it to be appended to the URL as a parameter. I have written a service for this:
...
1
vote
1answer
24 views
pure javascript method to set x scroll position in a div with overflow-x
How to set the x-position of scroll of a div with horizontal/overflow-x with pure javascript or angularjs ? Important: I'm not looking for jquery solutions - using angularjs,jquery wont work ...
1
vote
1answer
20 views
attribute directive on title tag in IE8 does not run
See below the super-simple directive that's attached to the <title> tag. In modern browsers this activates and changes the title to "Title C" but in IE8 the link function is never called and the ...
0
votes
0answers
10 views
Multiple, multi-level selection of active list elements in Angular
This is an interesting puzzle and I'm hoping to get some clever responses from the community :-)
My goal is to develop a simple mechanism that would allow me to select multiple list elements in a ...
0
votes
1answer
18 views
How do I implement `$locationProvider.html5Mode(true);
From what I understand doesn't $locationProvider.html5Mode(true); remove the hash from your URL?
While it does that for me only the home page seems to be ok when you refresh the page.
Isn't that what ...
0
votes
1answer
12 views
angular-datatables payload format does not change upon subsequent calls to reloadData()
After the initial load of data into the table using angular-datatables (Homepage), I intend to change the time span for which to reload and display data. The span is selected using two datetime input ...
0
votes
2answers
20 views
AngularJS throws unknown error
My code is like this
<body>
<div>
<table ng-app='myApp'>
<thead>
</thead>
<tbody ng-controller="MainCtrl">
<tr ...
0
votes
1answer
34 views
list of bullets after fetching data with php and angularJs
i want to display data from mysql with angularJs and php . here is my code :
php
$host = "localhost";
$user = "angular";
$pass = "angular";
$database = "angular";
$con = ...
0
votes
1answer
11 views
nodejs events is being called multiple times
I have been working on an CMS on nodejs hosted at https://github.com/techunits/mopublish/tree/develop. Here I have added few event hooks e.g.
mpObj.emit('MP:FOOTER', '<center>MPTEST Plugin ...
1
vote
1answer
11 views
AngularJs - Use filter with ng-bind in directive
I have a simple directive like that one :
Directive js :
.directive('pageHeader', function() {
return {
restrict: 'E',
scope: {
title: '=',
subtitle : ...
0
votes
0answers
8 views
How to add infinite scroller extension to angularjs.datatable
I am trying to implement a grid using the angularjs datatable(http://l-lin.github.io/angular-datatables/#/gettingStarted).
I want to implement the scroller plugin available with jquery datatables. Is ...
0
votes
1answer
29 views
Requirejs dependency not working
I am trying to use angular-ladda directive in my app. Here is my main.js which is the requirejs manifesto file:
requirejs.config({
paths: {
underscore: 'lib/underscore/underscore',
...
0
votes
1answer
36 views
How to use Promise to return value from assync Angular function into calling method?
I have list which is filled in for cycle where I calling assync function by thos way:
In For cycle I'm calling
row.SUCCES_RATE_SINCE = $scope.computeSuccessRateSinceStart(row);
Called function
...
0
votes
1answer
23 views
What is the best way to store and retrieve datas after clicking the previous Button Browser
I want to know what is the best way to store and retrieve datas only after clicking the back button Browser ?
In my case, you have a list of items (different for each categories I have on my website) ...
0
votes
1answer
19 views
Two angular app on same page - only one works at a time
I have two angular app blocks in a page. each one works individually , but when i try to run both only first one works.
<body>
<div ng-app='myApp' class="Freight">
<div ...
0
votes
0answers
10 views
Google Map with AngularJS: Cannot read property 'Pool.<InfoWindowView>' of undefined
I have the following div element where I am trying to show a Google Map with a lat and lng value.
<div id="map" g-map class="gmaps margin-bottom-40" style="height:400px;"></div>
I've ...
0
votes
1answer
18 views
Angularjs - Broadcast event is double fired
I have this simple code:
<modal ng-controler="Contacts">
//add new contact stuffs
</modal>
<div ng-controller="Contacts">
// show the new contact when added
</div>
...
0
votes
1answer
22 views
Custom directive scope in same element as controller
So I have encountered this issue while trying to migrate some working 1.2.16 code to 1.3.0. I've read the release notes, but haven't been able to find out exactly what is causing the issue
What it ...
0
votes
1answer
18 views
AngularJS directive for text input: focus on next input on Enter
I would like to implement such a directive for AngularJS: if used in input[text], on hitting enter the focus would move to next input. What would be the best way to accomplish this?
I have a very ...
2
votes
3answers
29 views
How to addClass in ng-repeat
Here is my Html code :
<div ng-controller="MainController">
<ul class="list-holder">
<li ng-repeat="check in checks" ng-class="{active : isSelected(check)}">
...
1
vote
1answer
23 views
Write initialization function for directive in angularjs?
I am developing one directive for my grid control, and i need to get some common resource data from server before i build the grid control.
How i can write initialization function for the directive? ...
0
votes
0answers
6 views
How do i force download Video in AngularJs from Amazon S3?
I have written code to download a video uploaded to amazon s3 using aws javascript sdk. Everything works fine but for some videos open up in the browser and start playing. Here is the code below:
...
0
votes
1answer
28 views
How to assign value in $scope inside ng-repeat angularJS
I have a problem now regarding the ng-repeat in angularJS on how to assign value in $scope inside ng-repeat..
This is my scenorio:
I have a json file that content all the data. It shows like this..
...
0
votes
2answers
23 views
JSON AngularJS multiple objects
I'm just curious as in how to access any field in this JSON call as it has multiple objects and is very confusing as it is my first time dealing with this. Here is the link to the JSON:
...
0
votes
0answers
12 views
Views pages isn't shown while working with routeProvider in angularJs for eclipse
I went over the AngularJs for eclipse https://github.com/angelozerr/angularjs-eclipse/wiki/Getting-Started and every example i made worked just fine as with controllers and other cool stuff, until i ...