Most of programs will not accept an email using just @localhost as domain.
So, edit /etc/hosts
file to make the domain localhost.com point to your machine, including this content to the file:
127.0.0.1 localhost.com
/* | |
var net = require('net'); | |
var http = require('http'); | |
var listeners = []; | |
var Meta = {}; | |
var streamer = http.createServer(function(req,res){ | |
res.write('ICY 200 OK\r\nicy-notice1:<BR>FUCK OFF <BR>icy-notice2:SHOUTcast Distributed Network Audio Server/posix v1.2.3<BR>icy-name:'+Meta.name+'\r\nicy-genre:'+Meta.genre+'\r\nicy-url:'+Meta.url+'\r\nContent-Type:audio/mpeg\r\nicy-pub:1\r\nicy-br:'+Meta.br+'\r\nicy-metaint:8192\r\n\r\n'); | |
listeners.push(res); | |
}); |
#!/bin/bash | |
# | |
# Display usage info | |
vhost-usage() { | |
cat <<"USAGE" | |
Usage: vhost [OPTIONS] <name> | |
-h|--help this screen | |
-pub to create the webhost root in ~/www/name/public/ | |
-url to specify a local address, default is http://name.local |
Most of programs will not accept an email using just @localhost as domain.
So, edit /etc/hosts
file to make the domain localhost.com point to your machine, including this content to the file:
127.0.0.1 localhost.com
/* Objective: Loop over an array of Drupal user objects and build a string of email addresses for the $to variable. | |
* At first there was an issue because the variable $to_email_array was not being accessible to the anonymous function | |
* and then I saw answer2 to a similar question: | |
* > http://stackoverflow.com/questions/11420520/php-variables-in-anonymous-functions | |
*/ | |
$to_email_array = array(); | |
array_walk($users_group, function(&$user, &$uid) use (&$to_email_array) { | |
$to_email_array[] = $user->mail; | |
}); |
A lot of important government documents are created and saved in Microsoft Word (*.docx). But Microsoft Word is a proprietary format, and it's not really useful for presenting documents on the web. So, I wanted to find a way to convert a .docx file into markdown.
As it turns out, there are several open-source tools that allow for conversion between file types. Pandoc is one of them, and it's powerful. In fact, pandoc's website says "If you need to convert files from one markup format into another, pandoc is your swiss-army knife." But, although pandoc can convert from markdown into .docx, it doesn't work in the other direction.
Install Package Control for easy package management.
Ctrl+`
/* | |
-------------------------------- | |
imgur Upload | |
-------------------------------- | |
+ https://github.com/pinceladasdaweb/imgur-upload | |
+ version 1.1 | |
+ Copyright 2014 Pedro Rogerio | |
+ Licensed under the MIT license | |
+ Documentation: https://github.com/pinceladasdaweb/imgur-upload |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title></title> | |
<meta charset="utf-8" /> | |
<script src="templating.js" type="text/javascript" charset="utf-8"></script> | |
</head> | |
<body> | |
<template id=t> |