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 | |
/* | |
* This file is part of the MODSlim package. | |
* | |
* Copyright (c) Jason Coward <[email protected]> | |
* | |
* For the full copyright and license information, please view the LICENSE | |
* file that was distributed with this source 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
<?php | |
$config_options = array ( | |
'callback_excludes' => array( | |
'modSession', | |
'modManagerLog', | |
'modActiveUser', | |
'modDbRegisterQueue', | |
'modDbRegisterTopic', | |
'modDbRegisterMessage', | |
'modUser', |
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
# Place this file in /etc/logrotate.d/gitlab | |
/home/gitlab/gitlab/log/*.log { | |
daily | |
rotate 52 | |
missingok | |
delaycompress | |
compress | |
copytruncate | |
} |
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
#!/bin/bash | |
# | |
# Steam installer for Debian wheezy (32- and 64-bit) | |
# | |
# Place into empty directory and run. | |
# | |
download() { | |
local url="$1" | |
local filename="$(basename "$url")" |
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
// 02/06/12 - Gildas - [email protected] | |
// - assets/components/batcher/js/widgets/resource.grid.js patch to Add "Refresh Cache" Option | |
// 05/11/12 - Gildas - [email protected] | |
// - Add custom log | |
// - Force timeout to 30s for each request | |
Batcher.grid.Resources = function(config) { | |
config = config || {}; | |
this.sm = new Ext.grid.CheckboxSelectionModel(); | |
Ext.applyIf(config,{ |
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 | |
/* runFn Snippet | |
* by [email protected] | |
* | |
* Pass the snippet a php function name and pipe delimited list of parameters. | |
* | |
* Example: Format a large number with number_format() | |
* See: www.php.net/manual/en/function.number-format.php | |
* | |
* [[!runFn? &fn=`number_format` &args=`123456789||2||,||.`]] |
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 | |
/* LangRouter | |
* ========== | |
* | |
* This plugin is meant to be used with Babel extra for MODX Revolution. It | |
* takes care of switching contexts, which hold translations, depending on URL | |
* requested by client. LangRouter works with so called subfolder based setup, | |
* in which many languages are served under a single domain but are | |
* differentiated by a virtual subfolder indicating the language, eg. | |
* mydomain.com/pl/. |
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 | |
$translitClassPath = $this->xpdo->getOption( | |
'friendly_alias_translit_class_path', | |
$options, | |
$this->xpdo->getOption('core_path', $options, MODX_CORE_PATH) . 'components/' | |
); | |
if ($this->xpdo->getService('translit', $translitClass, $translitClassPath, $options)) { | |
$alias = $this->xpdo->translit->translate($stringToApplyTransliterationTo, $translitTableName); | |
} |
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 | |
/** | |
* plugin fragment for setting width of MODX Manager left panel | |
*/ | |
if($modx->event->name == 'OnBeforeManagerPageInit') { | |
// update layout manager state | |
$state = $modx->controller->getDefaultState(); | |
$state['modx-leftbar-tabs']['width'] = 525; | |
$response = $modx->runProcessor('system/registry/register/send',array( | |
'register' => 'state', |
NewerOlder