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
rm -f ./app/tmp/cache/models/cake_model_* | |
rm -f ./app/tmp/cache/persistent/cake_core_* |
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
border: 1px solid black; | |
background-image: -webkit-gradient(linear, center top, center bottom, from(#fcfcfc), to(#bfbfbf), color-stop(3%, #f7f7f7), color-stop(12%, #f2f2f2), color-stop(90%, #d9d9d9)); | |
background-image: -webkit-linear-gradient(top, #fcfcfc, #f7f7f7 3%, #f2f2f2 12%, #d9d9d9 90%, #bfbfbf); | |
background-image: -moz-linear-gradient(top, #fcfcfc, #f7f7f7 3%, #f2f2f2 12%, #d9d9d9 90%, #bfbfbf); | |
background-image: -o-linear-gradient(top, #fcfcfc, #f7f7f7 3%, #f2f2f2 12%, #d9d9d9 90%, #bfbfbf); | |
background-image: -ms-linear-gradient(top, #fcfcfc, #f7f7f7 3%, #f2f2f2 12%, #d9d9d9 90%, #bfbfbf); |
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
-webkit-box-shadow: 0px 7px 3px 3px #b0b0b0; | |
box-shadow: 0px 7px 3px 3px #b0b0b0; |
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 | |
if (!isset($modules)) { | |
$modulus = 11; | |
} | |
if (!isset($model)) { | |
$models = ClassRegistry::keys(); | |
$model = Inflector::camelize(current($models)); | |
} | |
?> | |
<div class="pagination"> |
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 BootstrapFormHelper extends AppHelper { | |
public $helpers = array('Html', 'Form'); | |
public function input($name, $options = array()) { | |
$default = array( | |
'type' => null, | |
'label' => null, | |
'before' => null, // to convert .input-prepend |
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 | |
App::uses('FormHelper', 'View/Helper'); | |
/** | |
* BootstrapFormHelper. | |
* | |
* Applies styling-rules for Bootstrap 3 | |
* | |
* To use it, just save this file in /app/View/Helper/BootstrapFormHelper.php | |
* and add the following code to your AppController: |
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
<!-- Note: You'll have to use Modernizr to detect 3d transform support --> | |
<!--- HTML ---> | |
<div class="books"> | |
<div id="book1" class="book"> | |
<img src="book4.jpg" /> | |
</div> | |
<div id="book2" class="book"> | |
<img src="book2.jpg" /> | |
</div> |
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
$config = { | |
"application" => "DOMAIN.TLD", | |
"repository" => "git@GITHOST:USERNAME/REPOSITORYNAME.git", | |
"remoteusername" => "REMOTEUSERNAME", | |
"cake_folder" => "/PATH/TO/CAKE", | |
"cake_version" => "cakephp1.3", | |
"plugin_dir" => "plugins", | |
"servers" => { | |
"prod" => { | |
"server" => "APPLICATION.TLD", |
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 csvQuoteCell(cell, quotechar, sepchar) { | |
// quote cells containing sepchar and double quote chars | |
// this is an excel dialect | |
var quoted = cell; | |
if (cell.indexOf(sepchar)!==-1) { | |
if (cell.indexOf(quotechar)!==-1) { | |
quoted = quoted.replace(quotechar, quotechar+quotechar); | |
} | |
quoted = quotechar+quoted+quotechar; | |
} |
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
testCSV = function(){ | |
var csvData = ""; | |
db.transaction(function(tx){ | |
tx.executeSql('SELECT * FROM grocery', [], function (tx, results){ | |
var len = results.rows.length, i; | |
for (i = 1; i < len; i++) { | |
csvData += results.rows.item(i).itemno + "," + results.rows.item(i).quantity + "\n"; | |
} | |
window.location='data:application/webcsv;charset=utf8,' + encodeURIComponent(csvData); |
OlderNewer