Webserver SSI and JQuery

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Not applicable

I've implemented a webserver using the hexagon application kit. As described in other posts, I've enable SSI's by defining LWIP_HTTPD_SSI 1.
I've created a HTML file and saved it to my SD card as index.ssi. I can get data from my browser using the cgi handlers and write data to it using the SSI's. All works well.

The HTML code includes some JQuery. If I save the html code as .HTML, when I open the html file from the the SD card directly, the JQuery code runs. When the File is saved as .ssi and run from the webserver, Jquery does not run, I get just the basic HTML page or I get the browser showing me the html code.

What I want to do is have the microcontroller serve my HTML page, with my SSI's using JQuery? any help would be appreciated.

1 Reply
Not applicable
You could try to activate dynamic headers in "httpd_structs.h" of the HTTPServer.

/** Set this to 1 if you want to include code that creates HTTP headers
* at runtime. Default is off: HTTP headers are then created statically
* by the makefsdata tool. Static headers mean smaller code size, but
* the (readonly) fsdata will grow a bit as every file includes the HTTP
* header. */

If it works, please let us know!