visits added to site page
This commit is contained in:
@ -2,14 +2,14 @@ var con = require('./db');
|
||||
|
||||
sql = "INSERT INTO visits (date, img, site_id) VALUES ?";
|
||||
val = [
|
||||
['10-15-2019','https://seanland.ca', '1'],
|
||||
['10-17-2019','https://seanland.ca', '1'],
|
||||
['01-17-2020','https://seanland.ca', '134'],
|
||||
['11-23-2019','https://seanland.ca', '15']
|
||||
['10-15-2019','https://seanland.ca', '203'],
|
||||
['10-17-2019','https://seanland.ca', '169'],
|
||||
['01-17-2020','https://seanland.ca', '520'],
|
||||
['11-23-2019','https://seanland.ca', '520']
|
||||
];
|
||||
|
||||
con.query(sql, [val], function(err, res){
|
||||
if (err) throw err;
|
||||
console.log("visits" + ": records inserted: " + res.affectedRows);
|
||||
console.log("visit records inserted: " + res.affectedRows);
|
||||
process.exit();
|
||||
});
|
||||
|
Reference in New Issue
Block a user