Questions tagged [httpserver]

An HTTP Server is any application which receives requests via the HTTP protocol and sends back the corresponding response to fulfill the request.

An HTTP Server is any application which receives requests via the HTTP protocol and sends back the corresponding response to fulfill the request. This is the main method used by websites to handle HTML pages, Stylesheets, Scripts, Images, and other various types of files and requests which a web page may request from the server. HTTP Servers also handle other attributes of such a request, such as Query Strings and Cookies.

1287 questions
0
votes
1 answer

to pass a command in a file?

I want to run a executable file from my php script and the command used in the command line is where, profit is the executable file and profit.in is the input file. I wrote the following php script for running The same program when ran in the…
Pari.
  • 27
  • 1
  • 7
0
votes
1 answer

mongoose http server fails to get post data sometimes

when I use mongoose to process some http requests, it fails to get post data sometimes. Has anyone met the some problem? I am not sure whether the mongoose is stable enough. Can anyone give some ideas? Thanks in advance. I use the restClient to…
cici
  • 11
  • 2
0
votes
1 answer

Parsing multi-form request (iframe)

I have a httpservice on my android device. So I send a single file via XMLHttpRequest, if possible, or iframe in every other case. If I use Google Chrome it works fine and I have no questions, because it uses XMLHttpRequest to send file. But when I…
Nolesh
  • 6,848
  • 12
  • 75
  • 112
-1
votes
1 answer

Why can't my web client accept an image from my web server?

I this is my java HTTP server: public class WebServer implements Runnable { public static final int PORT = 80; @Override public void run() { HttpServer $server; try { $server = HttpServer.create(new…
-1
votes
3 answers

Calling nodeJS HTTP server from Javascript

I am trying to setup a very simple nodeJS HTTP server. When I call it from the browser, like this http://localhost:8081, it works fine, but when I call is using a JS fetch() method, I get a 404 error: GET…
Bill Ferster
  • 347
  • 1
  • 5
  • 17
-1
votes
1 answer

Raw HTTPS GET Over Java With No Reply

I am trying to do a quick HTTP GET over SSL Socket in Java without using external libraries or the HttpURLConnection class and noticed that the results are varying depending on the type of HTTP Server in use. Here's the main Java code: private…
thotheolh
  • 7,040
  • 7
  • 33
  • 49
-1
votes
1 answer

Running html on a local host gives strange error message

I am trying to get my index.html file to run using the live server extension on vs code. I got this very strange error "ReferenceError: hlIcons is not defined", but I don't ever use the phrase 'h1Icons' in my code. I tried to look up what h1Icons…
-1
votes
1 answer

How do I connect to my raspberry pi in a different network?

Let me explain what I want to happen. I have an http server program that displays a website every time I connect to my raspberry pi's ip address on port 8080. But this only works on my current network. I want to be able to access this raspberry pi…
Nick M
  • 73
  • 1
  • 8
-1
votes
1 answer

http-server cannot serve my angular application

I built the angular application and tried to run it with http-server. The terminal will then be flooded with never ending garbage text and the application will not run. Any idea what caused it? Application is working fine with ng serve and the dist…
Think Tank
  • 43
  • 8
-1
votes
1 answer

Port 80 still blocked after uninstalling IIS windows server 2019

I've recently removed IIS from my windows server, because it was to complex for my needs. Then I created a small flask app, to see if everything still works. Unfortunately not, regardless if I test it using local network or internet domain I get the…
Vivent
  • 35
  • 2
  • 6
-1
votes
1 answer

Python flask app which returns list of files

I have a basic flask app which is used to get logs from pods. I want to use send_from_directory when the query is not complete. I do not want to create a zip file and list it rather I would like to list the logs files that are generated with the…
Vini
  • 1,978
  • 8
  • 40
  • 82
-1
votes
2 answers

how to close database connection without terminating the server connection in golang

Is there any way to close the database connection without terminating the HTTP server? my code: func thisone(w http.ResponseWriter,r *http.Request){ /*connect the db*/ defer database.Close() /*query the database*/ } func main(){ …
THE CODER
  • 1
  • 1
-1
votes
1 answer

Angular 9 (HttpClient) How to fix CORS error?

I have POST request: getLagTimestamp() { const headers = new HttpHeaders({ 'Access-Control-Allow-Origin': '*', 'Authorization': 'Basic YWRtaW46cGFzc3dvcmQ=' }); this.response = this.http.post(this.url,…
-1
votes
1 answer

Sh script : run npm / http-server

I am writing a shell script that builds an angular app (ng build) and then runs a web server on the dist folder where angular bundles the app. The web server is run using the http-server command. (http-server just like npm needs to be installed…
Helix112
  • 305
  • 3
  • 12