// jQuery
$(document).ready(function() {
// code
})
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
/** | |
* Git create empty branch | |
*/ | |
git checkout --orphan <branchname> # branch without parents | |
git rm --cached -r . # clear the working directory | |
/** | |
* rename git branch locally and remotely | |
* @from https://gist.github.com/lttlrck/9628955 |
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 ProcessWire; | |
/** | |
* An Inputfield for handling relational Page inputs | |
* | |
* Delegates the actual input control to a user-defined Inputfield derived from InputfieldSelect | |
* | |
* @method PageArray getSelectablePages(Page $page) | |
* @method PageArray findPagesCode(Page $page) | |
* |
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
// Override limit based on user input | |
if($userLimit = (int) $input->get->limit) { | |
$remeberLimit = "?limit=$userLimit"; | |
$limit = $userLimit; | |
$input->whitelist('limit', $limit); | |
} | |
// Get year filter | |
if($userYear = (int) $sanitizer->selectorValue($input->get->year)) { | |
$year = $userYear; |
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 | |
/** | |
* Roskis | |
* | |
* Adds custom trash view that can be also accessed by defined roles | |
* Pages in trash can be searched, sorted and restored. | |
* | |
* | |
* Copyright 2013 by Antti Peisa |
NewerOlder