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 HomepagePresenter extends BasePresenter | |
{ | |
/** @var EntriesModel */ | |
protected $entriesModel; | |
/** | |
* Lazy getter for EntriesModel | |
* @return EntriesModel |
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://www.foo.bar/search?utf8=✓&query=test |
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
SET foreign_key_checks = 0; | |
TRUNCATE database_table; | |
DROP database_table; | |
SET foreign_key_checks = 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
; user_name can be same like database_name | |
CREATE DATABASE `database_name`; | |
CREATE USER 'user_name'@'%'; | |
GRANT ALL PRIVILEGES ON `user_name`.* TO 'database_name'@‘%'; | |
SET PASSWORD FOR 'user_name'@'%' = PASSWORD('user_password'); |
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 | |
/**#@+ Timeline {@link Twitter::load()} */ | |
const ME = 1; | |
const ME_AND_FRIENDS = 2; | |
const REPLIES = 3; | |
const ALL = 4; | |
/**#@-*/ | |
/**#@+ Output format {@link Twitter::load()} */ |
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 Acme\Site; | |
use Event; | |
use Illuminate\Support\Facades\App; | |
use System\Classes\PluginBase; | |
/** | |
* Site Plugin Information File | |
*/ | |
class Plugin extends PluginBase |
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 | |
include_once('vendor/autoload.php'); | |
// debugger | |
use Tracy\Debugger; | |
Debugger::enable(Debugger::DEVELOPMENT, __DIR__ . '/log'); | |
// load file | |
$content = file_get_contents(__DIR__ . '/data/data.xml'); |
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
# Fix for: Fatal error: Cannot read property 'contents' of undefined | |
# Run at /node_modules/grunt-contrib-imagemin this command: | |
npm install --save [email protected] |
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 | |
return [ | |
/* | |
|-------------------------------------------------------------------------- | |
| Application Debug Mode | |
|-------------------------------------------------------------------------- | |
| | |
| When your application is in debug mode, detailed error messages with |
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 Acme\Plugin\Models; | |
use Acme\Plugin\Validators\ExtendedValidator; | |
use Model as BaseModel; | |
use Illuminate\Support\Facades\Validator; | |
// registrate own validator | |
Validator::resolver(function($translator, $data, $rules, $messages) { |
OlderNewer