<type>(scope): <subject>
<BLANK LINE>
<body>
<BLANK LINE>
<footer>
```
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
TERM_CHILD=1 COUNT=5 QUEUES=* bundle exec rake resque:workers |
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 | |
/** | |
* Get a distinct multi dimensional array | |
* | |
* @param array $array | |
* array to distinct | |
* @param string $keySearch | |
* string key to search double array | |
* @param boolean $overwrite = false | |
* boolean to allow values to be overwritten |
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> | |
<!--[if IE 7]> <html class="no-js ie7 oldie" lang="lang"> <![endif]--> | |
<!--[if IE 8]> <html class="no-js ie8 oldie" lang="lang"> <![endif]--> | |
<!--[if gt IE 8]><!--> <html class="no-js" lang="${1:fr}"> <!--<![endif]--> | |
<head> | |
<meta charset="utf-8" /> | |
<meta name="description" content="" /> | |
<meta name="keywords" content="" /> | |
<!-- Geo position --> |
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
private function twoDigits($number) | |
{ | |
if($number <= 9) | |
return '0' . $number; | |
else | |
return $number; | |
} |
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
function generateRandomKey(size) | |
{ | |
var keyset = 'abcdefghijklmnopqrstuvwxyz0123456789'; | |
var randomKey = ''; | |
for (var i = 0; i < size; i++) | |
{ | |
var rnum = Math.floor(Math.random() * keyset.length); | |
randomKey += keyset.substring(rnum,rnum + 1); | |
} |
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
public class GoogleCalendar { | |
private Context _context; | |
private GoogleCalendarCallback _callback; | |
public GoogleCalendar(Context c, GoogleCalendarCallback cb) { | |
_context = c; | |
_callback = cb; | |
} | |
public void add(final String title, final Long dateStart, final Long dateEnd, |
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 | |
/** | |
* | |
*/ | |
class sfValidatorBIC extends sfValidatorBase | |
{ | |
protected $validator; | |
protected $errors; | |
protected function configure($options = array(), $messages = array()) |
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
private int _twoDigitsYear(int year) { | |
if (year > 0) | |
year = year % 100; | |
return year; | |
} |
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
## CONSOLE | |
# Routes for a controller | |
rake routes CONTROLLER=products | |
## CONTROLLER | |
# Redirect to referrer | |
redirect_to :back # raise RedirectBackError if no referer | |
# Before filter and after filter in a same method |
OlderNewer