Tagged Questions
0
votes
1answer
24 views
Value not updating automatically in angularJS with socket.io
Following is my angularJS code with socket.io which is only fetching value when I switch from a view, though I was expecting it to update the value automatically. Let me know what I am doing wrong ...
1
vote
0answers
28 views
Using angularjs to get GET and POST result
If I'm using angularjs and wanted to alter the page based on whether there's a GET request or a POST request, how would i do it?
For example:
//index.html
...
<p>{{ message }}</p>
...
1
vote
1answer
8 views
$resource.query() parameters fail to arrive at server
Trying to implement a RESTful API using Node.js and Angular.
On the client side, I define a resource called songResource with the $resource function in Angular.
I then call the API with this ...
0
votes
1answer
12 views
MongoDB only one item, post or put?
POST to create a new item, PUT to update an item.. but what if there's only one item in the database?
Do I code: 'if item already exists, find it and PUT' else 'POST'
or am I missing something very ...
-2
votes
0answers
19 views
In a REST Api how do I know that my client is already logged in with Facebook or any other provider?
I'm using the MEAN Stack (Mongo, Express, Angular, Node) and I have always used the jwt library to generate my authentications token, and be able to validate if a client (web or mobile) is or is not ...
0
votes
1answer
21 views
Express JS not sending JSON in response to post request
I'm writing a little AngularJS app that's communicating with an ExpressJS backend for JSON. My server.js file looks like:
var express = require('express'),
app = express();
//Express 4
...
0
votes
0answers
10 views
Socket vs interval http request
I've the following environment:
Server: node.js
Client: ionic mobile app
The user can subscribe to a service by leaving email. So in the app there are 3 status:
User not subscribed
User ...
0
votes
0answers
21 views
Sorting data AngularJS / NodeJS / MongoDB
I have more than 25000 data in a collection so I have to optimize for the front-end.
First with node JS, I did a pagination for the rest API:
app.get('/api', function(req, res, next) {
...
0
votes
0answers
9 views
Yeoman Full-Stack Generator and Nodejitsu deployment
I used Daftmonk's Yeoman Full-stack generator as scaffolding for an app I'm making. I'd like to run it using Nodejitsu's nodejs service. But when I deploy, I get a cascading series of errors, and even ...
0
votes
0answers
23 views
SPA Athentication AngulaJS -> PassportJS -> MongoDB
I am trying for days to setup Passport on SPA page. On Client Side i am using AngularJS $http and generaly it's working.
angular.module('Factory', []).factory('MainFactory', ['$http',function($http) ...
1
vote
0answers
37 views
Minification of JS file
I am working on minification of 3(one.js,two.js,three.js) JS files using require.js. The 3 js files have 3 alert messages. These 3 js files is being called using main.js file.
One.js:
define([], ...
-3
votes
0answers
29 views
JavaScript resources [on hold]
I am a software developer with Java experience, I have done web applications using the usual frameworks (JSF, Spring, Hibernate, Struts) but I want to get into JavaScript a lot more. I know the basics ...
2
votes
1answer
24 views
AngularJS + HTML: ng-include not working (404 - Page not found error)
I am new to AngularJS. I am trying to use ng-include to include an external HTML page in my main HTML page. But the problem is I am not able to include it and getting 404. Following is the folder ...
0
votes
0answers
7 views
How many types of video files stored on cloud for live streaming
I would like to know how many types of video files are we can store on a cloud. I want to store live streaming video file on a cloud so that I can retrieve this file using http or web socket access.
...
-2
votes
0answers
15 views
Simple auth with password hashing and validation in Node
Today I've started to learn apps fully in JS using Node, Express, Mongoose and Angular (for now only the first three). So here is my problem, I want to use Passport as auth module/plugin(?), but I ...
1
vote
2answers
28 views
Angularjs post request error No 'Access-Control-Allow-Origin'
I've index.html that sends post request to localhost:3000/SetUser but I always get the error XMLHttpRequest cannot load https://localhost:3000/SetUser. No 'Access-Control-Allow-Origin' header is ...
1
vote
0answers
33 views
Sending ajax request between https
I'm using angular to send ajax request to nodejs file, and I'm having this error,
XMLHttpRequest cannot load https://localhost:3000/SetUser. No 'Access-Control-Allow-Origin' header is present on the ...
0
votes
0answers
15 views
Sending Email with Node Mailer and Sendgrid in Angular MEAN stack using angular-fullstack from Yeoman
I am trying to understand where to locate the logic to send an email via a contact form in my Angular App (using angular-fullstack MEAN stack from Yeoman).
I can add the logic to send an email in the ...
0
votes
1answer
10 views
Empty objects using app.post and AngularJS + mongoose on node.js
My REST API is posting empty objects.
I am getting the value from req.body.name
If I log it console.log(req.body.name); I get the value on my console.
POST:
{ name: 'typing any name', status: null ...
2
votes
1answer
44 views
How to organize frontend and backend project structure in node.js? [on hold]
In my project I want to use coffeescript for both backend and frontend to develop it all in one programming language. Below is a list of modules I'm going to use:
Backend
coffeescript
node.js
...
0
votes
0answers
12 views
Can the socket.io client emit events locally?
Is it possible to use socket.io to dispatch events to the client and not send them to the server? Something like:
socket.emitLocally('some event', data, callback);
Here is why I'm asking:
At the ...
0
votes
0answers
26 views
Passport.js on API server, overseen by AngularJS frontend in an SPA
I feel like I must be missing something, and I'm sure this has been asked and answered before, but I just can't find a unified explanation about how to achieve what I need.
Validate this: Abstract of ...
0
votes
2answers
30 views
Mongoose schema for Multi-User application
I need to make schema for a multi user application I need to develop using MongoDB, Express, AngularJS and NodeJS. I have 4 types of users in that application, GUEST, REGISTERED_USER, SUBSCRIBER, ...
0
votes
0answers
28 views
jsonp GET request 404 Error
I'm using Nodejs, Socket.io, and Angular to build a web app taking advantage of the Instagram Real-Time API. I'm running into an issue when I fire off GET requests to the Instagram API.
I get this ...
0
votes
2answers
34 views
Angular.js html5mode(true) and normal anchor href links?
Okay so the problem is this:
I want to have an URL like this http://www.domain.com/bla not http://www.domain.com/#/bla
And I solved that using html5mode(true). Great for me!
But now when user goes ...
0
votes
1answer
33 views
Is using Firebase as the intermediary between AngularJS and NodeJS a 'bad' idea?
I'm looking for feedback on how to architect a system I'm building.
I have a few Node.JS scripts updating a Firebase DB.
I then have a few front-end AngularJS apps reading the data from the Firebase ...
4
votes
1answer
56 views
AngularJS - Best Way to Handle State on Manually Entered URLs
I currently have a set-up based on the meanjs stack boilerplate where I can have users logged in this state of being 'logged-in' stays as I navigate the URLs of the site. This is due to holding the ...
0
votes
3answers
24 views
$state.go method not switching to other state - angularjs
In my controller, I have $state.go('purchase'); which is not working .
When I click purchase button I get the below error.
Error: Could not resolve 'purchase' from state ''.
But initially, I ...
0
votes
0answers
11 views
Handling Nodejs streams with AngularJS
I am using nodejs streams to fetch data from my level database (using leveldb). Here is a snippet of the code I use:
app.get('/my/route', function (req, res, next) {
...
0
votes
0answers
10 views
Sails.js + MongoDB - Recommendations for storing users's multiple social account IDs
I'm currently developping a webapp with Sails.js + MongoDB.
I'm pretty new to Node.js and NoSQL world so I would like some recommendations.
Basically, an authenticated user will have the possibility ...
0
votes
0answers
26 views
Display image from Mongodb with NodeJS
I have a collection "image" and "image_ids "in my mongoDB:
image:
{
"_id" : ObjectId("542e65368a1cec1227ae2bac"),
"reference" : "5424991"
}
images_ids:
{
"_id" : ...
0
votes
2answers
20 views
Unexpected token 'Indent' using jade and Eclipse
I'm trying to learn node, angular, javascript, express and jade. Its all very new to me coming from a strictly .net based code environment.
So I've found a tutorial, but already at step 2 I run into ...
0
votes
1answer
22 views
Bower Install fails due to module_not_found
Trying to use Angular-Fullstack, created a new website, but when bower install executes it just silently exits with a single message:
bower MODULE_NOT_FOUND Cannot find module ...
0
votes
2answers
29 views
Node js - app.get method with query params - internal server error
Controller.js
function _loadMoreItems() {
console.log("load more items");
var paginate = {
page : $scope.page,
...
0
votes
0answers
7 views
Get all in MongoDB collection using SocialCMS with Breeze
I'm using SocialCMS Database middleware https://github.com/dai-shi/social-cms-backend with BreezeJS support.
I'm able to save changes to a MongoDB collection fine using manager.saveChanges() and ...
0
votes
1answer
33 views
Asynchronous Flow Charts. How to visually represent asynchronous logic
Yes, it's a bit of an oxymoron.
Is there a visual language for representing asynchronous logic? Something as simple as a flow chart?
I'd like to model UI "screens", and the logic behind them.
...
1
vote
1answer
42 views
How to receive updates from Server without requesting every nth seconds
I am building a mobile application that receives data from server whenever the server has a new data available. I am using cordova and ionic framework for my mobile application and a PHP/MySQL/Apache ...
0
votes
1answer
10 views
'ENOENT, open' when using connect-multiparty param 'uploadDir' (Express 4)
I am using connect-multiparty with Express4/Node/Angular. Running it locally, on a file upload, I get a 'ENOENT open' error when I specify an 'uploadDir', but it works with the default multipart().
...
0
votes
1answer
25 views
notification and messages system [on hold]
I want to know that the next scheme are correct to apply in my web site. the system is like facebook. You can make new friends, send invitations and send messages. You have a icon that notified all ...
0
votes
1answer
13 views
MEAN.js not showing in iframe
I have to display a MEAN.JS app within an iframe, so I started with a simple html file:
<iframe style="height: 100%; width: 100%;" src="http://localhost:3000/#!/workouts"></iframe>
But ...
0
votes
0answers
14 views
Rewrite URLs with GULP and Node
I am building an AngularJS app and am having difficulty getting it to run in HTML5 mode. When I refresh a page or link to a url without adding a '#' to it, I get a 404. The general consensus online ...
0
votes
0answers
21 views
NodeJS Express CSRF Error
I am receiving the following stack trace error from my Node server. My app runs on Angular and uses Node to interact with the API.
Error: Forbidden
at Object.exports.error ...
0
votes
1answer
29 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
1answer
17 views
Populate nested object with MongoosJS, NodeJS and AngularJS
I have a problem with getting nested objects in a model.
I have a model restaurant, where i am referencing an article. This is just an demo for me to test how this is working, but i am not getting ...
0
votes
1answer
12 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 ...
-3
votes
0answers
29 views
sample application using node.js,angular.js and mongodb
I am new to these technologies and i am trying to develop a simple application using these technologies to learn how to insert data and images into dtabase,how to retrieve those values and page ...
0
votes
1answer
15 views
How to make frisby.js scripts “pause” during chained executions of apis
I want to test a session timeout using Frisby.js. So I want to call our login API and call an API to demonstrate the user is logged in.
Then I want frisby.js to wait 20 minutes for the session to ...
0
votes
0answers
13 views
Workflow for API-based app built on node.js
I am building a reporting app on node.js and Angular.
I am using the Quickbooks Online API to pull in reports information.
I have to add custom fields to the reports I pull in and save this ...
0
votes
1answer
58 views
AngularJS + Bootstrap Pagination
I have all my data in multiple JSON:
http://localhost:3000/images?page=1
http://localhost:3000/images?page=2
http://localhost:3000/images?page=3
...
So with AngularJS I would like a pagination ...
0
votes
0answers
38 views
How are different DB modules maintaining connection in Nodejs
I am using yeoman's angular-fullstack generator as reference
I want to know how does MongoDB maintain connection as the connection to the DB is done in the main app.js file and after that there is no ...