Tagged Questions
AngularJS (a.k.a. AngularJS 1) is an open-source JavaScript framework. Its goal is to augment browser-based applications with Model–View–Whatever (MV*) capability and reduce the amount of JavaScript needed to make web applications functional. These types of applications are also frequently known as ...
0
votes
0answers
6 views
How to Open Native Sms default inbox from Cordova Application
I want to open Native SMS default inbox from Cordova application.For ex if I click on a button in my cordova app then it redirects to my phone's default native SMS App inbox .Thanks in Advance
0
votes
2answers
12 views
Browser level caching probelm
I am developing product in language HTML CSS and AngularJS and Api are written in JAVA.Whenever their is update in any functionality i need to clear cache then only changes are reflected,clearing ...
0
votes
1answer
11 views
Not allow two or more zero's regex at the start for custom angular directive
I'm writing an angular directive which only allows user to enter numbers in input field within range.
html code
<input non-negative-number range-min="1" range-max="5000" ng-model="number1">
...
0
votes
2answers
15 views
Dynamic ng-model with checkbox in ng-repeat
I have a JSON object like as below with name $scope.permissions
{
admission:{create:false,delete:false,read:false,update:false},
student:{create:false,delete:false,read:false,update:false},
...
0
votes
1answer
12 views
add/remove class on >li> click in angularjs
I have html like
one
two
tree
now on ng-click of every 'li' element I want to add class 'active' and remove from other 'li' elements. Also, if the same 'li' is clicked again ...
0
votes
1answer
14 views
Not linking another page by path in AngularJS
I use $location.path() to add there data @object and by submitting a form there is:url.com/@object, but when reloading the page - page is not found: i need not open another page, i just need to reload ...
0
votes
2answers
27 views
Angularjs - Page goes Blank when working with ng-show for two different links
Link1 : Profile
Link2 : Update
view : common.html
This two link is part of home.html
So, in my application Both profile and Update will redirect to common.html.With the help of ng-show I m showing ...
0
votes
0answers
12 views
How to prevent state change in AngularJS 1.6 with ui-router 1.0?
How can we use $transitions to cancel a state change to prompt the user for saving? Previous ui-router versions used to have an event in the callback, and could be stopped with event.preventDefault(), ...
0
votes
1answer
16 views
Accessing ng-click when rendered via $sce.trustAsHtml
How do i get access to the ng-click function (updateRating) in the below?
https://jsfiddle.net/by2jax5v/171/
I'm using $sce.trustAsHtml to render $scope.content
$scope.bindHTML = $sce.trustAsHtml($...
0
votes
0answers
25 views
Angular unit testing - module is not a function
I am using ES6, angular 1.5.8, webpack(babel-loader).
I'm new in angular and karma and tried to make some unit tests. Karma throws an error:
Chrome 55.0.2883 (Windows 10 0.0.0) LOG: 'WARNING: ...
0
votes
0answers
7 views
Accessing component controller from transcluded HTML
Plunker, because the snippet editor isn't liking me today.
Quick Info
I'm working on using .component() in place of .directive() when using Angular 1.6 to get myself more into the type of design ...
1
vote
0answers
9 views
css transition animation doesn't work for decreasing size of image
.shrink-add, .shrink-remove{
-webkit-transition:all ease 2.5s;
-moz-transition:all ease 2.5s;
-o-transition:all ease 2.5s;
transition:all ease 2.5s;
}
.shrink,
.shrink-add.shrink-add-active{...
-1
votes
1answer
15 views
Ionic2 & Angular2 $http POST request
I'm currently trying to post some data to an external PHP file.
Issue:
Recieving Log Error: SyntaxError: Unexpected token < in JSON at position 0
Data Parameters not posting as headers.
What I'...
0
votes
0answers
23 views
Avoiding multiple angular GET request when ng-repeating scope *Resolved*
I load my pages and menu from the angular scope witch is in turn requesting data to the Node server connected to the DB.
So my controller looks like this;
mid.controller('pageCtrl', function($scope, ...
1
vote
1answer
13 views
Angular 2 move component to back (Change z position)
I am trying to make a responsive web app with a side menu that hide and shows via a button when the screen is small. However, I am finding that when the menu shows, it shows "behind" my main component ...
0
votes
1answer
14 views
Angular ngDialog : Issues with setDefaults
I'm using ngDialog which works completly fine without adding any setDefault properties, once in the app.config if I set any properties, it does not render.
I want to prevent dialog box from closing ...
2
votes
2answers
17 views
How to keep service data the same on multiple controllers without using $watch?
There's an older answer I saw here on S.O, which states:
"This JavaScript works as we are passing an object back from the
service rather than a value. When a JavaScript object is returned from
...
0
votes
1answer
9 views
How to show ionic popup using ng-click inside ng-repeat
here's my html code.
<div class='list' ng-repeat='worker in categories' >
<br><a class="item item-thumbnail-left" ng-click="showConfirm(worker.$id)">
<img src="img/...
0
votes
2answers
12 views
Ionic angular service only return data after controller call
I have a service that do two $http.get to get data from two source and concat into an array and return it to controller.
angular.module('starter.controllers').factory('GetDataList', function ($http) ...
0
votes
1answer
10 views
Synchronize multiple $http response in angularjs
Simply i need call an API to get response of user addresses and corresponding to each address i have to call google API to get the longitude and latitude.
I have tried too much and about all methods ...
1
vote
1answer
20 views
Angular Routing 1.6 assistance
When building this site I took a pure JS approach for the interaction. But now I am trying implement Angular as well, particularly for the routing.
However I am a novice with angular and am ...
0
votes
0answers
21 views
How do I keep a user updated across routes and controllers?
I am making a web application where a user adds items to his or her cart. This cart is referenced by several controllers across my app. I can not seem to be able to keep the user in sync so that ...
0
votes
0answers
15 views
Gulp plugin installation
When I try to run the following command :
npm install jshint gulp-jshint jshint-stylish gulp-imagemin gulp-concat gulp-uglify gulp-minify-css gulp-usemin gulp-cache gulp-changed gulp-rev gulp-rename ...
0
votes
3answers
16 views
AngularJS: Directive not working properly
I am writing an angularJS app, and find myself writing the same "search" UI on every module. So I've decided to create my first directive, which I understand injects code as a module so that I can re-...
0
votes
1answer
8 views
Angular default select option being overwritten
My drop down box defaults to "No Preference" which is what I want, but it keeps getting overwritten by the other options when they load in the page. How do I keep "No Preference" as the default.
...
2
votes
1answer
10 views
Angular Routing; exlamation mark beside hashtag in url
I trying to do routing but i can't.
Related codes in app.js;
var app = angular.module("app",['ngRoute']);
app.config(["$routeProvider",function($routeProvider){
$routeProvider.
when('/...
0
votes
0answers
9 views
Angular - Material md-auto complete search suggestions invisible
I have taken the example angular gives on their website and directly put it into my express js app to play around with it and adapt it to what I need. However, for some reason the search suggestions ...
0
votes
0answers
9 views
angular 2 dynamic template created from user-defined templates
Is it possible to have user-defined templates say based on user-defined parameters from the server - and then have a component take them in as its template?
These templates are user-specific and not ...
0
votes
0answers
28 views
Highly strange error in Angular application
I have a SQL Server database and an Asp.net web api for my web service.
I have below UI for adding a category
I have below UI for adding a expense in that category
After I login into the ...
-1
votes
0answers
18 views
Collapsable rows inside a table
I found this AngularJS tutorial on collapsable rows inside a table but I would like an example for ng2(Angular 2) and I can't find an example online for ng2. All of them are for either jquery or ...
0
votes
1answer
30 views
How to use Angular to activate CSS Animation on button click?
I want to use an Angular function to activate a Css animation. I have searched for ways to do this but Im really confused on how to do it in my case. I wish to have the div "slide1" to slide ...
2
votes
0answers
11 views
Angular not loading after Wiselinks page load in Rails 4
The issue I'm having is that when loading pages via Wiselinks that have Angular set to display on them, I am seeing the actual Angular variables instead of the correct values (e.g. {{ song.name }} ...
0
votes
2answers
25 views
Two Way Data Binding - Angular 2
Im trying to make two way data binding with ngModel and it not working.
FormsModule is included.
here the code:
app.module.ts:
import { BrowserModule } from '@angular/platform-browser';
import { ...
0
votes
0answers
17 views
ng-model bind only $scope variable [duplicate]
I have a service that returns dict. In my controller i set it to $scope variable:
.controller('viewCtrl', function($scope, myService) {
$scope.mydict = myService.mydict;
}
But then when i change ...
0
votes
1answer
30 views
how to turn border color red if input is not valid only when clicked outside of the input field but not at the time of filling the textbox.?
i am trying to do like this but border color turns red even i type a single letter into the input field and not getting normal till the input is valid.
i am wishing to turn the border color red on ...
1
vote
0answers
8 views
How to send xml data using http post in angularjs and receive html
$scope.PostCall = function(data,d) {
console.log(data);
$http({
url :"https://localhost:9443/root/p/testPost2",
...
0
votes
0answers
9 views
how to navigate in angular master-detail-layout via buttons
I have implemented the starter app in the Angular Material-Start (ES6) tutorial (https://github.com/angular/material-start).
Now I would like to navigate in the master-detail-layout not only by ...
0
votes
0answers
9 views
Ionic menu based on condition
i want right inside side (right or left) depend on value of rtl in controller
rtl value (true or false) in controller
<ion-nav-buttons side="rtl ? 'right' : 'left'">
<button class="...
0
votes
0answers
13 views
angularjs html5mode refresh 404 + Web api
As i am creating SPA using angular js, with api. As we know we get # in the URL, in order to remove the # from URL this tutorial mentioned in linke,
http://www.advancesharp.com/blog/1191/angularjs-...
0
votes
1answer
14 views
How to Jasmine test value of Object.constructor and reduce repition in it statements - AngularJS
I defined an object model in my AngularJS application... it looks like so:
.factory('Watermark', function () {
// Constructor, with class name
// Assumption: that backend gives us a topic or ...
0
votes
0answers
17 views
angular js: Embed the templates or call each when needed, which way is better?
I am building a one-page application with Angular JS (1). And I ended with 20 html templates for 20 views/routes.
Now, I am wondering if it's a good idea to simply include all of these templates in ...
1
vote
1answer
18 views
No 'Access-Control-Allow-Origin' header is present on the requested resource. NodeJS and AngularJS App
I have read all the above links but it still doesn't solve my issue.
Node code
app.all('*', (req, res, next) => {
let allowedOrigins = ['http://localhost:8080', 'http://127.0.0.1:8080'];
...
0
votes
2answers
27 views
How to select multiple options in Select2 dropdown on load?
I'm trying to load an array of selected items into an existing select2 dropdown, so that there are pre-selected items on load, but i'm struggling to get my syntax correct.
Give the following json ...
0
votes
0answers
14 views
How do I configure Java EE running on GAE to work with Angular UI Router in html5Mode?
I am attempting to set the UI Router location provider html5Mode to true for my Angular application: locationProvider.html5Mode(true). While this works client side (appropriately redirects) I am ...
0
votes
0answers
15 views
Best process to make a state of ui-router from a page
I have created a working web page page.html, which loads page.css and page.js in the header:
<script src="page.js"></script>
<link href="page.css" rel="stylesheet" type="text/css" />...
0
votes
1answer
11 views
How can I retrive the data in ngStorage?
I want to use the data in $sessionStorage of ngStorage module directly in view, how can I make it?
such as
<div>{{sessionStorage.userData.userName}}</div>
Currently, I can only do by ...
0
votes
1answer
19 views
Reorder the selected items in AngularJS ui-select multiple
Is it possible to automatically reorder the selected items in AngularJS ui-select of type multiple?
Here is a code sample, there are more on ui-select github
<ui-select multiple ng-model="ctrl....
0
votes
0answers
18 views
Routing on the single-page app (AngularJS)
I have a single page application. For example, the URL is url.com, but there is a lot of objects with it's own pages, loading by
url.com/@objectname
On the url.com there is a form with input for ...
0
votes
1answer
15 views
Edit and storing json after fetching ionic 2
I fetching a json this way:
this.http.get('http://someaddress.json')
.map(res => res.json())
.subscribe(
data => { ... }
);
Now I would like to change some of the data and store it locally ...
0
votes
1answer
12 views
ng-click within ionic tag not working without interpolation
I am trying to pass a value to the function on ng-click, it is working outside ionic tag without interpolation but why do I need to interpolate it withing ionic tag. I am not getting it, sample code ...