You are here

function nodejs_get_url in Node.js integration 6

Same name and namespace in other branches
  1. 8 nodejs.module \nodejs_get_url()
  2. 7 nodejs.module \nodejs_get_url()

Get the URL of a Node.js callback.

Parameters

array $config: The result of nodejs_get_config().

string $callback: The path to call on Node.js server (without leading /).

Return value

string

1 call to nodejs_get_url()
Nodejs::initConfig in ./nodejs.module

File

./nodejs.module, line 524

Code

function nodejs_get_url($config, $callback = '') {
  return $config['scheme'] . '://' . $config['host'] . ':' . $config['port'] . '/' . $callback;
}