windres -O coff icon.rc icon.res
gcc icon.res startemacs.c -o startemacs
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
*.pyc | |
*.png | |
*.svg |
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
<?php | |
namespace Sundown\Render; | |
class Colorful extends HTML { | |
public function blockCode($code, $lang) { | |
if($lang) { | |
return self::renderCode($code, $lang); | |
} | |
return parent::blockCode($code, $lang); | |
} |
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
/** | |
* display: box, box-flex - Learning CSS3 | |
*/ | |
/* | |
* The box-flex property specifies whether the child elements of a box is flexible or inflexible in size. | |
* Elements that are flexible can shrink or grow as the box shrinks and grows. Whenever there is extra space in a box, flexible elements are expanded to fill that space. | |
*/ | |
.panel { border: solid 1px #ccc; display: box; } | |
#p1 { border: solid 1px #f90; box-flex: 3; } |
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
using System; | |
using System.Text; | |
using System.Net; | |
using System.Text.RegularExpressions; | |
using System.IO; | |
class Program | |
{ | |
static void Main() | |
{ |
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
var parser = document.createElement('a'); | |
parser.href = "http://example.com:3000/pathname/?search=test#hash"; | |
parser.protocol; // => "http:" | |
parser.hostname; // => "example.com" | |
parser.port; // => "3000" | |
parser.pathname; // => "/pathname/" | |
parser.search; // => "?search=test" | |
parser.hash; // => "#hash" | |
parser.host; // => "example.com:3000" |
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
<!-- tested on chrome & ie9 --> | |
<input type="text" pattern="\d+" onkeypress="return keyFilter()" /> | |
<input type="text" pattern="\d{11}" maxlength="11" onkeypress="return keyFilter('\\d')" /> | |
<script> | |
/** | |
* 限制input的可输入字符类型(不包含长度) | |
*/ | |
function keyFilter(opt_pat) { | |
var e = arguments.callee.caller.arguments[0] || window.event, | |
pattern = opt_pat || (e.target || e.srcElement).getAttribute("pattern"); |
- php: http://php.net/manual/en/function.date.php
- .net: http://msdn.microsoft.com/en-us/library/8kb3ddd4.aspx
- bash: http://ss64.com/bash/date.html
- emacs: format-time-string
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
<?xml version="1.0" encoding="UTF-8"?> | |
<configuration> | |
<system.webServer> | |
<rewrite> | |
<!-- | |
http://www.iis.net/download/ApplicationRequestRouting | |
http://blogs.msdn.com/b/carlosag/archive/2010/04/02/setting-up-a-reverse-proxy-using-iis-url-rewrite-and-arr.aspx | |
http://learn.iis.net/page.aspx/686/setting-http-request-headers-and-iis-server-variables/ | |
--> | |
<rules> |
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
# http://httpd.apache.org/docs/current/mod/core.html | |
# http://httpd.apache.org/docs/current/mod/mod_proxy.html | |
# enable proxy modules | |
# sudo ln -s /etc/apache2/mods-available/proxy.load /etc/apache2/mods-enabled | |
# sudo ln -s /etc/apache2/mods-available/proxy_http.load /etc/apache2/mods-enabled | |
# sudo service apache2 force-reload | |
# or | |
# LoadModule proxy_module modules/mod_proxy.so | |
# LoadModule proxy_http_module modules/mod_proxy_http.so |