This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Server.js | |
* @author : DiganmeGiovanni | https://twitter.com/DiganmeGiovanni | |
* @Created on: 25 Oct, 2014 | |
* Updated on: 29 March, 2015 | |
*/ | |
/* Librerias necesarias para la aplicación */ | |
var express = require('express'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Data Access Object (DAO) para 'messages' | |
* Debe ser construido con un objeto conectado a la | |
* base de datos | |
* | |
* @Created on: 29 March, 2015 | |
*/ | |
function MessageDAO(db) { | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
socket.on('latest messages', function () { | |
messagesDAO.getLatest(50, function (err, messages) { | |
if (err) console.log('Error getting messages from history'); | |
socket.emit('latest messages', messages); | |
}); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** css and js static routes */ | |
app.get('/css/foundation.min.css', function (req, res) { | |
res.sendFile(__dirname + '/views/css/foundation.min.css'); | |
}); | |
app.get('/css/normalize.css', function (req, res) { | |
res.sendFile(__dirname + '/views/css/normalize.css'); | |
}); | |
app.get('/css/chat.css', function (req, res) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Server.js | |
* @author : DiganmeGiovanni | https://twitter.com/DiganmeGiovanni | |
* @Created on: 25 Oct, 2014 | |
* Updated on: 15 Aug, 2015 | |
*/ | |
// ====================================================== // | |
// == MODULOS REQUERIDOS PARA LA APLICACIÓN |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Chat SS Styles | |
* | |
* @author : DiganmeGiovanni | https://twitter.com/DiganmeGiovanni | |
* @Updated at: Aug 16, 2015; | |
*/ | |
@import url(http://fonts.googleapis.com/css?family=Roboto:400,700); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<title>Chat room</title> | |
<link rel="stylesheet" href="css/normalize.css"> | |
<link rel="stylesheet" href="css/foundation.min.css"> | |
<link rel="stylesheet" href="css/chat.css"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Simple server to download files over network | |
* | |
* @author: Giovanni Aguirre | twitter: @DiganmeGiovanni | |
* @Created on: Aug 16, 2015 | |
*/ | |
// Importa y configura los modulos necesarios |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Create table ESTACIONAMIENTO | |
CREATE TABLE ESTACIONAMIENTO( | |
ID INT AUTO_INCREMENT PRIMARY_KEY, | |
NOMBRE VARCHAR(150), | |
COSTO_HORA INT NOT NULL, | |
COSTO_FRACCION INT NOT NULL | |
); | |
CREATE TABLE CAJON( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Giovanni Color Scheme for Cmus player ... | |
# | |
# This theme is designed to be 1) Very readable on high-resolution or blurry | |
# displays (dying CRTs and TVs, for example). 2) Be more accessable to color- | |
# blind people, by removing chroma cues in favor of brightness and color | |
# inversion. 3) Show how to incorperate named and numbered colors into a | |
# single theme. 4) Provide a stating point for creating other mono-chromatic | |
# themes. | |
# | |
# Questions, comments (just a heads-up that you use/like this, especially), |