G
G
gnatchuk_igor2019-01-02 11:46:06
PHP
gnatchuk_igor, 2019-01-02 11:46:06

How to run a node.js script from php?

I need to run a Node,js script in the Laravel task queue and pass parameters to it.
I don't know how to implement it. The question is how to do it with exec?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Ukolov, 2019-01-02
@alexey-m-ukolov

exec('node /path/to/scipt.js with params --or-options', $output, $return_var);

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question