简体   繁体   中英

Apache SSI includes and node

I have apache running and it is configured to serve some SSI includes, it all works fine if the application is deployed through Apache, however I would like to deploy a node test server and at the same time Apache to understand the SSI includes. Is that even possible?

I have a work around by loading the SSI includes as an JSON object on the front end but would like the SSI includes to be processed at the server level.

I ended up using node-request

https://www.npmjs.com/package/request

var request = require('request');
request('http://www.google.com', function (error, response, body) {
  console.log('error:', error); // Print the error if one occurred 
  console.log('statusCode:', response && response.statusCode); // Print the response status code if a response was received 
  console.log('body:', body); // Print the HTML for the Google homepage. 
});

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM