This file contains hidden or 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
brew install mysql | |
env ARCHFLAGS="-arch x86_64" gem install mysql2 -- --with-mysql-dir=/usr/local/Cellar/mysql/5.5.19 --with-mysql-lib=/usr/local/Cellar/mysql/5.5.19/lib --with-mysql-include=/usr/local/Cellar/mysql/5.5.19/include --with-mysql-config=/usr/local/Cellar/mysql/5.5.19/bin/mysql_config |
This file contains hidden or 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> | |
<title></title> | |
<!-- Android | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no;" /> | |
<meta charset="utf-8">--> | |
<!-- iPad/iPhone specific css below, add after your main css > |
This file contains hidden or 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
$(document).ready(function() { | |
// Support for AJAX loaded modal window. | |
// Focuses on first input textbox after it loads the window. | |
$('[data-toggle="modal"]').click(function(e) { | |
e.preventDefault(); | |
var url = $(this).attr('href'); | |
if (url.indexOf('#') == 0) { | |
$(url).modal('open'); | |
} else { |
This file contains hidden or 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 | |
// Resizer and Image Manipulation | |
// Based on: http://forums.laravel.com/viewtopic.php?id=2648 | |
public function post_edit_logo($id) | |
{ | |
$rules = array( | |
'image' => 'image', | |
); |
This file contains hidden or 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 PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> | |
<title>Insert title here</title> | |
<script type="text/javascript" src="lib/android/cordova-1.7.0.js"></script> | |
<script type="text/javascript"> | |
window.appRootDirName = "download_test"; | |
document.addEventListener("deviceready", onDeviceReady, false); |
This file contains hidden or 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
$.extend $.fn.datepicker.defaults, | |
format: 'yyyy-mm-dd' | |
weekStart: 1 | |
### | |
<input type="text" id="from" class="datepicker" data-dependent="to" data-diff="7" /> | |
<input type="text" id="to" class="datepicker" /> | |
### | |
$("input.date").each -> |
This file contains hidden or 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
// Workaround for buggy footer fixed position when virtual keyboard is on/off | |
$(document).on('touchstart focus','input, textarea', function (e) { | |
$('footer, .float-buttons').css('display', 'none'); | |
}) | |
.on('blur','input, textarea', function (e) { | |
$('footer, .float-buttons').css('display', 'block'); | |
}); |
This file contains hidden or 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 | |
/** | |
* An helper file for Laravel 4, to provide autocomplete information to your IDE | |
* Generated with https://github.com/barryvdh/laravel-ide-helper | |
* Updated for Laravel 4.1.8 (2013-12-13) | |
* | |
* @author Barry vd. Heuvel <barryvdh@gmail.com> | |
*/ | |
exit('Only to be used as an helper for your IDE'); |
This file contains hidden or 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 MatchesControllerTest extends TestCase | |
{ | |
protected $user; | |
protected $profile; | |
public function setUp() | |
{ | |
parent::setUp(); | |
DB::beginTransaction(); |
This file contains hidden or 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
try { | |
DB::connection()->getPdo()->beginTransaction(); | |
// database queries here | |
DB::connection()->getPdo()->commit(); | |
} catch (\PDOException $e) { | |
// Woopsy | |
DB::connection()->getPdo()->rollBack(); | |
} |
OlderNewer