Hi,
If I understand correctly, I'm doing something similar here.
I have created a json file as below:
{
"ssl_ok_count": "<!--#SslOkCount-->",
"ssl_err_count": "<!--#SslErrCount-->",
"ssl_log": "<!--#SslLog-->"
}
Then in the _javascript_ you have to do something like this:
/* this is from the XMLHttpRequest */
obj = JSON.parse(stripAwayComments(this.responseText));
document.getElementById("id_ssl_ok_count").innerHTML = obj.ssl_ok_count;
document.getElementById("id_ssl_err_count").innerHTML = obj.ssl_err_count;
document.getElementById("id_ssl_log").innerHTML = obj.ssl_log;
This is the related function, called above
function stripAwayComments(str) {
return str.replace(/<\!--.*?-->/g, "");
}
This is because I was not aware of LWIP_HTTPD_SSI_INCLUDE_TAG, see the related comments in httpd.h and httpd_opts.h.
With LWIP_HTTPD_SSI_INCLUDE_TAG set at 0, you can change the line above to
obj = JSON.parse(this.responseText);
I think that I'm facing the same problem you have because my "char log_memory[10240]" array should be appended to my SslLog tag. So, I don't think that setting LWIP_HTTPD_MAX_TAG_INSERT_LEN to 10240 is the correct approach :-)
Hope this helps
Marco