All Questions
126
questions
0
votes
0
answers
94
views
Set header on a formData Angular
I have a problem when I try to send a file via http with FormData () in Angular. The headers that I get to the java code are not correct, how can I go about correcting this?
When I send request with ...
0
votes
1
answer
283
views
Add object to request body from angular to nodejs
I have a yaml file of this format:
Layouts:
-
Name: Default Layout
LayoutId : 1
ConfiguredSegments:
LiveA :
Height : 100
...
0
votes
1
answer
413
views
Why is my POST method not working in Angular
When I send data in postman , I've got 200 status - success [
But when I try to send POST request to the same URL through Angular CLI , Ive got 400 error, which says MALFORMED_JSON
const testData = {
...
0
votes
1
answer
55
views
How can I run my async function in a for loop
I'm trying to run an async function that send post request to the server and logs the response in the console. Whenever I run a for loop nothing is happening. I have checked a different similar ...
1
vote
1
answer
40
views
How the default template is created when the url of directory hosted on web is hit?
i have a angularjs module for some common component, services etc with their separate folders, say root/component/, root/services/ and so on. When i hit url "root/component/" in browser, i get a ...
0
votes
0
answers
4k
views
How to send parsed .csv file as a byte array or ArrayBuffer data from Node.js backend to AngularJS frontend?
I'm working on AngularJS app.
Module I'm currently working on should be able to either show a preview of a spreadsheet file or allow to download it.
The steps:
When clicked on "Preview File" it ...
0
votes
0
answers
60
views
fetch json data using angular.js
Simple node HTTP server is hosting JSON data on localhost/6666.
Another HTTP server is setup to serve very basic angular.js application made of single index.html file and module which purpose is to ...
1
vote
1
answer
125
views
Serve angular.min.js using Node's http module [duplicate]
Is it possible to serve angular.js by using only http module from node, without any other frameworks? Will I have all the functionality that is needed for a simple web app?
This is what I've tried:
...
0
votes
1
answer
21
views
Is it possible to host web page with angular.min.js functionality using nodes http module
Is it possible to host web page with angular.min.js functionality using nodes http module?
I'm making a really simple web project that is going to fetch some data and I decided to use angular.js to ...
0
votes
1
answer
735
views
How to fake error 504 in node-express server
I want to check a code that I wrote, which retry a request when error 504 occurs (only one more time). Can someone help me how to fake an error to check it?
(The server is Node express, the client ...
1
vote
1
answer
31
views
How to pass an object param with $http POST and access in Nodejs service
I have created a POST request where i am sending a param to server and in the server side i am getting the error is like the data not found.
Client js
var postData= JSON.stringify({name:"Alex",age:"...
1
vote
1
answer
460
views
How to avoid catching the HTTP OPTIONS request in the express.js auth middleware
Okay I have a backend API built in express.js that responds to a SPA built in AngularJS. I am using token authentication to verify the access of clients to fetch certain resources.
The way I check on ...
0
votes
2
answers
65
views
i can't inject data from Json into html with angularjs using node js
I can't manage to inject data from a Json file into my html.
I get a good response, I can log it into chrome console.log of my response
but i can't inject it in my html.
here is my angularJs code :
...
0
votes
0
answers
95
views
Pug not working in express when requesting from angular
I have a webapp which I am currently working on.
Actually, I am sending a request from my AngularJS front-end like..
$http({
method:"GET",
url:'/verifyEmail'
}).then(function (data) {
}, ...
0
votes
1
answer
97
views
Script in my html page not working when i serve it through the 'http' server in Node.js
I am handling my '/' route in the 'http' server and i'm serving the index.html file in this way-
if(parsedUrl.pathname === '/') {
fs.readFile('./index.html', 'utf-8', function(err, ...