Skip to main content
Participant
April 19, 2019
Question

Socket hang up error with nodejs in indesign2015

  • April 19, 2019
  • 1 reply
  • 3164 views

Hi,

I want to upload file and download files from server with adobe cep indesign extension.. i have done by using nodejs..

nodejs request.get() and request.post() works fine in indesign 2017 and above..

but in indesign cc 2015 returns "socket hang up" error..

how to fix it?

and any other configuration for use nodejs in indesign cc2015

this is my sample code,

var FormData = require('form-data');

var request = require('request');

options = {

        url:uploadUrl,

        formData: formData,

        headers:headers,

strictSSL: false,

rejectUnauthorized: false,

    }

    request.post(options, function(err, httpResponse, body) {

    if (err) {            

       showDlg('Upload failed');

    }

    else {

                showDlg("Upload successfully");               

                 }

             }

    });     

Pls help

This topic has been closed for replies.

1 reply

erinferinferinf
Adobe Employee
Adobe Employee
April 19, 2019

Hi Aysnandhini!

This is a compatibility problem. Please refer to these two charts. InDesign 2015 uses CEP 6, which is only compatible with Node IO.js 1.2.0.

Unfortunately, I don't know enough about Node to solve your problem, but hopefully this will point you in the right direction. You might also want to check out our article on running a Node server in a panel.

Best of luck!

Participant
April 29, 2019

Hi,

I have checked Node IO.js 1.2.0​ doc link.. i have used request module for upload a file but there is no explanation about request module in 1.2.0 doc link i think request module does not support in that nodejs version.. but https.request support by cc2015.. do you have any idea for upload a file/files using https.request?

Thank you

erinferinferinf
Adobe Employee
Adobe Employee
May 3, 2019

Hi there,

So... I asked around and perhaps there is nothing particularly special about htts.requests in CC 2015. Have you had any luck following basic HTTPS file upload guides like this one?

Let us know if you've made progress!