$connection = new AMQPStreamConnection(
$_ENV['RABBIT_IP'],
$_ENV['RABBIT_PORT'],
$_ENV['RABBIT_USER'],
$_ENV['RABBIT_PASSWORD'],
'/',
false,
'AMQPLAIN',
null,
'en_US',
30, //Connection Timeout
30, // Read/Write Timeout
null,
false,
60
);
$channel = $connection->channel();
$channel->queue_declare('RequestLog', false, false, false, false);
$msg = new AMQPMessage($request->getContent());
$channel->basic_publish($msg, 'clickhouse-exchange', 'RequestLog');
$channel->close();
$connection->close();
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>title</title>
<link rel="stylesheet" href="./css/styles.css">
<link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
</head>
<body>
<div class="container-fluid">
<div id="app">
</div>
</div>
<script src="./js/vue.js"></script>
<script src="./js/jquery.min.js"></script>
<script src="./js/bootstrap.min.js"></script>
</body>
</html>
<script>
var pjson = require('./package.json');
const puppeteer = require('puppeteer');
const Datastore = require('nedb');
var gui = require('nw.gui');
let path = require("path");
let hddserial = require('hddserial');
var request = require('request');
let app = new Vue({
el: '#app',
...
});
</script>
<script src="./js/script.js"></script>
mysql_query()
$query = "UPDATE catch SET hide = 1 WHERE id = {$id}");
$res = mysql_query($query) or die (mysql_error());